コード例 #1
1
ファイル: start.php プロジェクト: sparrow41/training
<?php

include_once 'manager.php';
$citizen = new Citizen();
$citizen->checkNumber(31077654720);
// metoda w manager.php
$citizen->checkNumber(786234987);
コード例 #2
1
ファイル: edit.php プロジェクト: bitweaver/citizen
 *
 * Copyright (c) 2006 bitweaver.org
 * All Rights Reserved. See below for details and a complete list of authors.
 * Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See http://www.gnu.org/copyleft/lesser.html for details
 *
 * @package citizen
 * @subpackage functions
 */
/**
 * required setup
 */
require_once '../kernel/setup_inc.php';
$gBitSystem->verifyPackage('citizen');
$gBitSystem->verifyPermission('p_citizen_update');
include_once CITIZEN_PKG_PATH . 'Citizen.php';
$gContent = new Citizen();
if (!empty($_REQUEST['content_id'])) {
    $gContent->load($_REQUEST['content_id']);
}
// Get plugins with descriptions
global $gLibertySystem;
if (!empty($gContent->mInfo)) {
    $formInfo = $gContent->mInfo;
    $formInfo['edit'] = !empty($gContent->mInfo['data']) ? $gContent->mInfo['data'] : '';
}
$cat_type = BITPAGE_CONTENT_TYPE_GUID;
if (isset($_REQUEST["preview"])) {
    // get files from all packages that process this data further
    foreach ($gBitSystem->getPackageIntegrationFiles('form_processor_inc.php', TRUE) as $package => $file) {
        if ($gBitSystem->isPackageActive($package)) {
            include_once $file;
コード例 #3
0
ファイル: load_golden.php プロジェクト: bitweaver/citizen
<?php

/*
 * Created on 5 Jan 2008
 *
 * To change the template for this generated file go to
 * Window - Preferences - PHPeclipse - PHP - Code Templates
 */
// Initialization
require_once '../kernel/setup_inc.php';
require_once CITIZEN_PKG_PATH . 'Citizen.php';
// Is package installed and enabled
$gBitSystem->verifyPackage('citizen');
// Now check permissions to access this page
$gBitSystem->verifyPermission('p_citizen_admin');
$citizens = new Citizen();
set_time_limit(0);
if (empty($_REQUEST["update"])) {
    $citizens->GoldenExpunge();
    $update = 0;
} else {
    $update = $_REQUEST["update"];
}
$row = 0;
$handle = fopen("data/golden.csv", "r");
if ($handle == FALSE) {
    $row = -999;
} else {
    while (($data = fgetcsv($handle, 800, ",")) !== FALSE) {
        if ($row) {
            $citizens->GoldenRecordLoad($data);
コード例 #4
0
ファイル: get_queue.php プロジェクト: bitweaver/tasks
/**
 * @version      $Header$
 *
 * @author       lsces  <*****@*****.**>
 * @package      tasks
 * @copyright    2008 bitweaver
 * @license      LGPL {@link http://www.gnu.org/licenses/lgpl.html}
 **/
/**
 * Setup
 */
require_once '../kernel/setup_inc.php';
$gBitSystem->verifyPackage('tasks');
require_once TASKS_PKG_PATH . 'Tasks.php';
$gTask = new Tasks();
if (!empty($_REQUEST['queue_id'])) {
    $gTask->getNextTask($_REQUEST['queue_id']);
}
if ($gTask->isValid()) {
    $gBitSmarty->assignByRef('taskInfo', $gTask->mInfo);
    require_once CITIZEN_PKG_PATH . 'Citizen.php';
    $gCitizen = new Citizen($this->mCitizenId);
    if ($gCitizen->isValid()) {
        $gBitSmarty->assignByRef('citizenInfo', $gCitizen->mInfo);
    }
    $gBitSystem->setBrowserTitle("Task List Item");
    $gBitSystem->display('bitpackage:tasks/show_task.tpl', NULL, array('display_mode' => 'display'));
} else {
    header("location: " . TASKS_PKG_URL . "view.php");
    die;
}
コード例 #5
0
ファイル: list.php プロジェクト: bitweaver/citizen
 *
 * Copyright (c) 2006 bitweaver.org
 * All Rights Reserved. See below for details and a complete list of authors.
 * Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See http://www.gnu.org/copyleft/lesser.html for details
 *
 * @package citizen
 * @subpackage functions
 */
/**
 * required setup
 */
require_once '../kernel/setup_inc.php';
include_once CITIZEN_PKG_PATH . 'Citizen.php';
$gBitSystem->verifyPackage('citizen');
$gBitSystem->verifyPermission('p_citizen_view');
$gContent = new Citizen();
if (!empty($_REQUEST["find_org"])) {
    $_REQUEST["find_name"] = '';
    $_REQUEST["sort_mode"] = 'organisation_asc';
} else {
    if (empty($_REQUEST["sort_mode"])) {
        $_REQUEST["sort_mode"] = 'surname_asc';
        $_REQUEST["find_name"] = 'a,a';
    }
}
//$citizen_type = $gContent->getCitizensTypeList();
//$gBitSmarty->assign_by_ref('citizen_type', $citizen_type);
$listHash = $_REQUEST;
// Get a list of matching citizen entries
$listcitizens = $gContent->getCitizenList($listHash);
$gBitSmarty->assign_by_ref('listcitizens', $listcitizens);
コード例 #6
0
 public function addCitizen(Citizen $citizen)
 {
     $this->population[$citizen->getUniqueIdentifier()] = $citizen;
 }
コード例 #7
0
ファイル: index.php プロジェクト: bitweaver/tasks
    }
} else {
    if (!empty($_REQUEST['content_id'])) {
        $gTask = new Tasks(null, $_REQUEST['content_id']);
        $gTask->load();
        $gBitUser->storePreference('task_process', $_REQUEST['content_id']);
        $userstate = $_REQUEST['content_id'];
    } else {
        $gTask = new Tasks();
    }
}
if ($gTask->isValid() and $userstate != 0) {
    $gBitSmarty->assignByRef('userstate', $userstate);
    $gBitSmarty->assignByRef('taskInfo', $gTask->mInfo);
    $dept_tree = $gTask->listQueues();
    $gBitSmarty->assignByRef('departments', $dept_tree['depts']);
    $gBitSmarty->assignByRef('tags', $dept_tree['tags']);
    $gBitSmarty->assignByRef('subtags', $dept_tree['subtags']);
    require_once CITIZEN_PKG_PATH . 'Citizen.php';
    $gCitizen = new Citizen(null, $gTask->mCitizenId);
    $gCitizen->load();
    if ($gCitizen->isValid()) {
        $gCitizen->loadXrefList();
        $gBitSmarty->assignByRef('citizenInfo', $gCitizen->mInfo);
    }
    $gBitSystem->setBrowserTitle("Task List Item");
    $gBitSystem->display('bitpackage:tasks/show_task.tpl', NULL, array('display_mode' => 'display'));
} else {
    header("location: " . TASKS_PKG_URL . "view.php");
    die;
}