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


PHP CPatient::loadRefLatestConstantes方法代码示例

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


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

示例1: CPatient

 *
 * @package    Mediboard
 * @subpackage soins
 * @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
 */
$patient_id = CValue::get('patient_id', 0);
$sejour_id = CValue::get('sejour_id');
$patient = new CPatient();
$patient->load($patient_id);
$sejour = new CSejour();
$sejour->load($sejour_id);
if ($patient->_id) {
    $constantes = $patient->loadRefLatestConstantes(null, array('poids', 'taille'));
    $poids = '&mdash;';
    $taille = '&mdash;';
    $imc = '&mdash;';
    $unit_poids = CConstantesMedicales::$list_constantes['poids']['unit'];
    $unit_taille = CConstantesMedicales::$list_constantes['taille']['unit'];
    if ($constantes[0]->poids) {
        $date = CMbDT::format($constantes[1]['poids'], CAppUI::conf('datetime'));
        $poids = "<span title='{$date}'>{$constantes[0]->poids} {$unit_poids}</span>";
        if ($sejour && $sejour->_id) {
            if ($constantes[1]['poids'] < $sejour->entree || $constantes[1]['poids'] > $sejour->sortie) {
                // Weight outdated
                $msg = utf8_encode(CAppUI::tr('CPatient-msg-Entry is outdated'));
                $date = CMbDT::format($constantes[1]['poids'], CAppUI::conf('datetime'));
                $poids = "<span title='{$msg} : {$date}' style='color: firebrick;'><strong>{$constantes[0]->poids} {$unit_poids}</strong></span>";
            }
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:ajax_update_infos_patient.php

示例2: CConsultAnesth

 * $Id$
 *  
 * @category Cabinet
 * @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
 */
$consult_id = CValue::get("consult_id");
$patient_id = CValue::get("patient_id");
$consult_anesth = new CConsultAnesth();
$consult_anesth->load($consult_id);
$patient = new CPatient();
$patient->load($patient_id);
$constantes = reset($patient->loadRefLatestConstantes(null, array("poids", "taille")));
$auto_55 = false;
$auto_imc26 = false;
if ($patient->_annees) {
    $consult_anesth->plus_de_55_ans = $patient->_annees > 55 ? 1 : 0;
    $auto_55 = 1;
}
if ($constantes->_imc) {
    $consult_anesth->imc_sup_26 = $constantes->_imc > 26 ? 1 : 0;
    $auto_imc26 = 1;
}
$smarty = new CSmartyDP();
$smarty->assign("consult_anesth", $consult_anesth);
$smarty->assign("plus_de_55_ans", $auto_55);
$smarty->assign("imc_sup_26", $auto_imc26);
$smarty->display("inc_guess_ventilation.tpl");
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:ajax_guess_ventilation.php

示例3: implode

            $where[] = implode(" OR ", $whereOr);
        } else {
            $where["context_class"] = " = '{$context->_class}'";
            $where["context_id"] = " = '{$context->_id}'";
        }
    } else {
        $where["context_class"] = " = '{$context->_class}'";
        $where["context_id"] = " = '{$context->_id}'";
    }
    // Needed to know if we are in the right context
    $constantes->context_class = $context->_class;
    $constantes->context_id = $context->_id;
    $constantes->loadRefContext();
}
//CConstantesMedicales::$_latest_values = array();
$latest_constantes = $patient->loadRefLatestConstantes(CMbDT::dateTime(), array(), $context, false);
// On récupère dans tous les cas le poids et la taille du patient
$patient->loadRefLatestConstantes(null, array("poids", "taille"), null, false);
$constantes->updateFormFields();
// Pour forcer le chargement des unités lors de la saisie d'une nouvelle constante
$whereOr = array();
foreach ($constants_to_draw as $_cat => $_ranks) {
    foreach ($_ranks as $rank => $_constants) {
        foreach ($_constants as $name) {
            if ($name[0] === "_") {
                continue;
            }
            $whereOr[] = "{$name} IS NOT NULL ";
        }
    }
}
开发者ID:fbone,项目名称:mediboard4,代码行数:31,代码来源:httpreq_vw_constantes_medicales.php


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