当前位置: 首页>>代码示例>>PHP>>正文


PHP CValue::post方法代码示例

本文整理汇总了PHP中CValue::post方法的典型用法代码示例。如果您正苦于以下问题:PHP CValue::post方法的具体用法?PHP CValue::post怎么用?PHP CValue::post使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CValue的用法示例。


在下文中一共展示了CValue::post方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: doDelete

 function doDelete()
 {
     parent::doDelete();
     $dialog = CValue::post("dialog");
     if ($dialog) {
         $this->redirectDelete .= "&name=" . $this->_obj->nom . "&firstName=" . $this->_obj->prenom . "&id=0";
     }
 }
开发者ID:fbone,项目名称:mediboard4,代码行数:8,代码来源:do_patients_aed.php

示例2: doStore

 /**
  * @see parent::doStore()
  */
 function doStore()
 {
     if (isset($_FILES['attachment'])) {
         $mail_id = CValue::post('mail_id');
         $mail = new CUserMail();
         $mail->load($mail_id);
         $files = array();
         foreach ($_FILES['attachment']['error'] as $key => $file_error) {
             if (isset($_FILES['attachment']['name'][$key])) {
                 $files[] = array('name' => $_FILES['attachment']['name'][$key], 'tmp_name' => $_FILES['attachment']['tmp_name'][$key], 'error' => $_FILES['attachment']['error'][$key], 'size' => $_FILES['attachment']['size'][$key]);
             }
         }
         foreach ($files as $_key => $_file) {
             if ($_file['error'] == UPLOAD_ERR_NO_FILE) {
                 continue;
             }
             if ($_file['error'] != 0) {
                 CAppUI::setMsg(CAppUI::tr("CFile-msg-upload-error-" . $_file["error"]), UI_MSG_ERROR);
                 continue;
             }
             $attachment = new CMailAttachments();
             $attachment->name = $_file['name'];
             $content_type = mime_content_type($_file['tmp_name']);
             $attachment->type = $attachment->getTypeInt($content_type);
             $attachment->bytes = $_file['size'];
             $attachment->mail_id = $mail_id;
             $content_type = explode('/', $content_type);
             $attachment->subtype = strtoupper($content_type[1]);
             $attachment->disposition = 'ATTACHMENT';
             $attachment->extension = substr(strrchr($attachment->name, '.'), 1);
             $attachment->part = $mail->countBackRefs('mail_attachments') + 1;
             $attachment->store();
             $file = new CFile();
             $file->setObject($attachment);
             $file->author_id = CAppUI::$user->_id;
             $file->file_name = $attachment->name;
             $file->file_date = CMbDT::dateTime();
             $file->fillFields();
             $file->updateFormFields();
             $file->doc_size = $attachment->bytes;
             $file->file_type = mime_content_type($_file['tmp_name']);
             $file->moveFile($_file, true);
             if ($msg = $file->store()) {
                 CAppUI::setMsg(CAppUI::tr('CMailAttachments-error-upload-file') . ':' . CAppUI::tr($msg), UI_MSG_ERROR);
                 CApp::rip();
             }
             $attachment->file_id = $file->_id;
             if ($msg = $attachment->store()) {
                 CAppUI::setMsg($msg, UI_MSG_ERROR);
                 CApp::rip();
             }
         }
         CAppUI::setMsg('CMailAttachments-msg-added', UI_MSG_OK);
     } else {
         parent::doStore();
     }
 }
开发者ID:fbone,项目名称:mediboard4,代码行数:60,代码来源:CMailAttachmentController.class.php

示例3: redirect

/**
 * Redirect to the last page
 *
 * @return void
 */
function redirect()
{
    if (CValue::post("ajax")) {
        echo CAppUI::getMsg();
        CApp::rip();
    }
    $m = CValue::post("m");
    $tab = CValue::post("tab");
    CAppUI::redirect("m={$m}&tab={$tab}");
}
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:15,代码来源:do_translate_aed.php

示例4: doStore

 function doStore()
 {
     parent::doStore();
     $dialog = CValue::post("dialog");
     $isNew = !CValue::post("patient_id");
     $patient_id = $this->_obj->patient_id;
     if ($isNew) {
         $this->redirectStore .= "&patient_id={$patient_id}&created={$patient_id}";
     } elseif ($dialog) {
         $this->redirectStore .= "&name=" . $this->_obj->nom . "&firstname=" . $this->_obj->prenom;
     }
 }
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:12,代码来源:do_patients_fusion.php

示例5: doBind

 function doBind()
 {
     $this->ajax = CValue::post("ajax");
     $this->suppressHeaders = CValue::post("suppressHeaders");
     $this->callBack = CValue::post("callback");
     unset($_POST["ajax"]);
     unset($_POST["suppressHeaders"]);
     unset($_POST["callback"]);
     // Object binding
     $this->_obj->bind($_POST["suivi"]);
     $this->_old->load($this->_obj->_id);
 }
开发者ID:fbone,项目名称:mediboard4,代码行数:12,代码来源:do_docgedmodele_aed.php

示例6: doBind

 function doBind()
 {
     parent::doBind();
     // recuperation du sejour_id
     $_sejour_id = CValue::post("_sejour_id", null);
     // si pas de sejour_id, redirection
     if (!$_sejour_id) {
         $this->doRedirect();
     }
     // Creation du nouvel antecedent
     unset($_POST["antecedent_id"]);
     $this->_obj = $this->_old;
     $this->_obj->_id = null;
     $this->_obj->antecedent_id = null;
     // Calcul de la valeur de l'id du dossier_medical du sejour
     $this->_obj->dossier_medical_id = CDossierMedical::dossierMedicalId($_sejour_id, "CSejour");
 }
开发者ID:fbone,项目名称:mediboard4,代码行数:17,代码来源:do_copy_antecedent.php

示例7: CMediusers

/**
 * $Id$
 *
 * @package    Mediboard
 * @subpackage SalleOp
 * @author     SARL OpenXtrem <dev@openxtrem.com>
 * @license    GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version    $Revision$
 */
$object_id = CValue::post("object_id");
$object_class = CValue::post("object_class");
$chir_id = CValue::post("chir_id");
$anesth_id = CValue::post("anesth_id");
$password_activite_1 = CValue::post("password_activite_1");
$password_activite_4 = CValue::post("password_activite_4");
/** @var COperation|CSejour $object */
$object = new $object_class();
$object->load($object_id);
if ($password_activite_1) {
    $chir = new CMediusers();
    $chir->load($chir_id);
    if (!CUser::checkPassword($chir->_user_username, $password_activite_1)) {
        CAppUI::setMsg("Mot de passe incorrect", UI_MSG_ERROR);
        echo CAppUI::getMsg();
        CApp::rip();
    }
    $object->cloture_activite_1 = 1;
    if ($msg = $object->store()) {
        CAppUI::setMsg($msg, UI_MSG_ERROR);
    } else {
开发者ID:fbone,项目名称:mediboard4,代码行数:30,代码来源:do_cloture_activite_aed.php

示例8: CPasswordKeeper

<?php

/**
 * $Id$
 *
 * @category Password Keeper
 * @package  Mediboard
 * @author   SARL OpenXtrem <dev@openxtrem.com>
 * @license  GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @link     http://www.mediboard.org */
CPasswordKeeper::checkHTTPS();
CCanDo::checkAdmin();
$password_keeper_id = CValue::postOrSession("password_keeper_id");
$_passphrase = CValue::post("passphrase");
$deletion = CValue::post("deletion");
$user = CMediusers::get();
$keeper = new CPasswordKeeper();
$keeper->load($password_keeper_id);
if ($keeper->_id && $keeper->user_id != $user->_id) {
    $msg = "Vous n'avez pas droit d'accéder à ce trousseau.";
    CAppUI::stepAjax($msg, UI_MSG_ERROR);
}
// Second passage, après avoir saisi la phrase de passe
if ($keeper->_id && $_passphrase) {
    if (!$keeper->testSample($_passphrase)) {
        $msg = "Phrase de passe incorrecte.";
        CAppUI::stepAjax($msg, UI_MSG_ERROR);
    }
    // Ecrit la phrase de passe en session
    CValue::setSessionAbs("passphrase", $_passphrase);
}
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:31,代码来源:ajax_edit_keeper.php

示例9: unset

<?php

/**
 * $Id$
 *
 * @category HL7
 * @package  Mediboard
 * @author   SARL OpenXtrem <dev@openxtrem.com>
 * @license  GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version  $Revision$
 * @link     http://www.mediboard.org
 */
$cn_receiver_guid = CValue::post("cn_receiver_guid");
if ($cn_receiver_guid == "none") {
    unset($_SESSION["cn_receiver_guid"]);
    return;
}
CValue::setSessionAbs("cn_receiver_guid", $cn_receiver_guid);
开发者ID:fbone,项目名称:mediboard4,代码行数:18,代码来源:do_set_session_receiver_aed.php

示例10: CSejour

     }
     break;
 case "A13":
     $sejour_id = CValue::post("sejour_id");
     $sejour = new CSejour();
     $sejour->load($sejour_id);
     $sejour->sortie_reelle = "";
     if ($msg = $sejour->store()) {
         CAppUI::stepAjax($msg, UI_MSG_ERROR);
     }
     break;
 case "INSERT":
     $sejour_id = CValue::post("sejour_id");
     $sejour = new CSejour();
     $sejour->load($sejour_id);
     $sejour->type = CValue::post("type");
     if ($sejour->type == "ambu" || $sejour->type == "urg") {
         $sejour->sortie_prevue = CMbDT::dateTime("+4 HOURS", $sejour->entree);
         if ($sejour->sortie_reelle) {
             $sejour->sortie_reelle = CMbDT::dateTime("+4 HOURS", $sejour->entree);
         }
         /* TODO Supprimer ceci après l'ajout des times picker */
         $sejour->_hour_entree_prevue = null;
         $sejour->_min_entree_prevue = null;
         $sejour->_hour_sortie_prevue = null;
         $sejour->_min_sortie_prevue = null;
     } elseif ($sejour->type == "comp") {
         $sejour->sortie_prevue = CMbDT::dateTime("+72 HOURS", $sejour->entree);
         if ($sejour->sortie_reelle) {
             $sejour->sortie_reelle = CMbDT::dateTime("+72 HOURS", $sejour->entree);
         }
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:do_encounter_event.php

示例11:

        }
        // In case the setup has added some user prefs
        CAppUI::buildPrefs();
        break;
    case "upgrade":
        if ($module->mod_version = $setup->upgrade($module->mod_version)) {
            $module->mod_type = $setup->mod_type;
            $module->store();
            if ($setup->mod_version == $module->mod_version) {
                CAppUI::setMsg("Installation de '%s' à la version %s", UI_MSG_OK, $module->mod_name, $setup->mod_version);
            } else {
                CAppUI::setMsg("Installation de '{$module->mod_name}' à la version {$module->mod_version} sur {$setup->mod_version}", UI_MSG_WARNING, true);
            }
        } else {
            CAppUI::setMsg("Module '%s' non mis à jour", UI_MSG_WARNING, $module->mod_name);
        }
        // In case the setup has added some user prefs
        CAppUI::buildPrefs();
        break;
    default:
        CAppUI::setMsg("Unknown Command", UI_MSG_ERROR);
}
// en cas d'un appel en Ajax (mobile)
if (CValue::get("ajax") || CValue::post("ajax")) {
    echo CAppUI::getMsg();
    CApp::rip();
}
SHM::rem("modules");
if (!$mobile) {
    CAppUI::redirect("m=system&tab=view_modules");
}
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:do_manage_module.php

示例12: CFile

 * @package  Mediboard
 * @author   SARL OpenXtrem <dev@openxtrem.com>
 * @license  GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version  $Revision$
 * @link     http://www.mediboard.org
 */
// post values
$dispo = CValue::post("tab_disposition");
$user_id = CValue::post("user_id");
$cat_id = CValue::post("category_id");
$print = CValue::post("print", 0);
// files
$file_array = CValue::post("file");
$data = $file_array[$dispo];
// context
$object_guid = CValue::post("context_guid");
$context = CMbObject::loadFromGuid($object_guid);
// get data uri
foreach ($data as $_key => &$_data) {
    $file = new CFile();
    $file->load($_data["file_id"]);
    $file->getDataURI();
    $_data["file_uri"] = $file->_data_uri;
}
//user
$user = CMediusers::get($user_id);
// file
$file = new CFile();
$file->setObject($context);
$file->file_name = CAppUI::tr("CFile-create-mozaic") . " de " . CAppUI::tr($context->_class) . " du " . CMbDT::dateToLocale(CMbDT::date()) . ".pdf";
$file->file_type = "application/pdf";
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:do_mozaic_doc.php

示例13: trim

<?php

/**
 * $Id$
 *
 * @category Admin
 * @package  Mediboard
 * @author   SARL OpenXtrem <dev@openxtrem.com>
 * @license  GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version  $Revision$
 * @link     http://www.mediboard.org
 */
$password = trim(CValue::post('password'));
$lock = CValue::post('lock');
if ($lock) {
    $_SESSION['locked'] = true;
    return;
} else {
    if (!$password) {
        CAppUI::setMsg("Auth-failed-nopassword", UI_MSG_ERROR);
    }
    if (!CUser::checkPassword(CUser::get()->user_username, $password)) {
        CAppUI::setMsg("Auth-failed-combination", UI_MSG_ERROR);
    }
    if ($msg = CAppUI::getMsg()) {
        echo $msg;
        return;
    } else {
        CAppUI::callbackAjax('Session.unlock');
        $_SESSION['locked'] = false;
    }
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:31,代码来源:ajax_unlock_session.php

示例14: viewMsg

 */
function viewMsg($msg, $action, $txt = "")
{
    global $m, $tab;
    $action = CAppUI::tr($action);
    if ($msg) {
        CAppUI::setMsg("{$action}: {$msg}", UI_MSG_ERROR);
        CAppUI::redirect("m={$m}&tab={$tab}");
        return;
    }
    CAppUI::setMsg("{$action} {$txt}", UI_MSG_OK);
}
//récupération de l'identifiant du séjour à fusionner
$sejour_id_merge = CValue::post("sejour_id_merge");
// Récupération du rpu
$rpu_id = CValue::post("rpu_id");
$rpu = new CRPU();
$rpu->load($rpu_id);
$sejour = $rpu->loadRefSejour();
$sejour_rpu = $sejour;
$properties_sejour = $sejour->getProperties();
//Cas d'une collision ou d'un rattachement d'un séjour
if ($sejour_id_merge) {
    $sejour_merge = new CSejour();
    $sejour_merge->load($sejour_id_merge);
    $sejour_merge->entree_reelle = $sejour->entree_reelle;
    $sejour_merge->mode_entree_id = $sejour->mode_entree_id;
    $sejour_merge->mode_entree = $sejour->mode_entree;
    $sejour_merge->provenance = $sejour->provenance;
    $msg = $sejour_merge->merge(array($sejour));
    viewMsg($msg, "Fusion");
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:31,代码来源:do_transfert_aed.php

示例15: array

<?php

/**
 * $Id$
 *
 * @package    Mediboard
 * @subpackage dPcabinet
 * @author     SARL OpenXtrem <dev@openxtrem.com>
 * @license    GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version    $Revision$
 */
// Praticien courant pour les prises de rendez-vous suivantes
if ($chir_id = CValue::post("chir_id")) {
    CValue::setSession("chir_id", $chir_id);
}
// Consultation courante dans edit_consulation
if (CValue::post("del")) {
    CValue::setSession("selConsult");
}
// before basic job, do the multiple consultations
CAppUI::requireModuleFile("dPcabinet", "controllers/do_consultation_multiple");
// Cas de l'annulation / rétablissement / supression multiple
if ($consultation_ids = CValue::post("consultation_ids")) {
    $_POST = array("consultation_ids" => CValue::post("consultation_ids"), "motif_annulation" => CValue::post("motif_annulation"), "annule" => CValue::post("annule", 0), "del" => CValue::post("del"), "sejour_id" => CValue::post("sejour_id"), "postRedirect" => CValue::post("postRedirect"));
}
//consult n°1, classic use
$do = new CDoObjectAddEdit("CConsultation");
$do->doIt();
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:28,代码来源:do_consultation_aed.php


注:本文中的CValue::post方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。