Пример #1
0
<?php

/**
 * $Id: vw_cellSaver.php 20938 2013-11-13 11:02:47Z aurelie17 $
 *
 * @package    Mediboard
 * @subpackage bloodSalvage
 * @author     SARL OpenXtrem <*****@*****.**>
 * @license    GNU General Public License, see http://www.gnu.org/licenses/gpl.html
 * @version    $Revision: 20938 $
 */
CCanDo::checkRead();
$cell_saver_id = CValue::getOrSession("cell_saver_id");
$cell_saver = new CCellSaver();
$cell_saver_list = $cell_saver->loadList();
if ($cell_saver_id) {
    $cell_saver = new CCellSaver();
    $cell_saver->load($cell_saver_id);
}
$smarty = new CSmartyDP();
$smarty->assign("cell_saver_list", $cell_saver_list);
$smarty->assign("cell_saver", $cell_saver);
$smarty->display("vw_cellSaver.tpl");
    $selOp->loadRefSejour()->loadRefPatient();
    $selOp->_ref_sejour->_ref_patient->loadRefDossierMedical();
    $selOp->_ref_sejour->_ref_patient->loadRefLatestConstantes();
    $blood_salvage = new CBloodSalvage();
    $blood_salvage->operation_id = $op;
    $blood_salvage->loadMatchingObject();
    $timing["_recuperation_start"] = array();
    $max_add_minutes = CAppUI::conf("dPsalleOp max_add_minutes");
    foreach ($timing as $key => $value) {
        for ($i = -CAppUI::conf("dPsalleOp max_sub_minutes"); $i < $max_add_minutes && $blood_salvage->{$key} !== null; $i++) {
            $timing[$key][] = CMbDT::time("{$i} minutes", $blood_salvage->{$key});
        }
    }
}
/*
 * Liste des cell saver.
 */
$cell_saver = new CCellSaver();
$list_cell_saver = $cell_saver->loadList();
$smarty = new CSmartyDP();
$smarty->assign("blood_salvage", $blood_salvage);
$smarty->assign("salle", $salle);
$smarty->assign("selOp", $selOp);
$smarty->assign("date", $date);
$smarty->assign("modif_operation", $modif_operation);
$smarty->assign("totaltime", "00:00:00");
$smarty->assign("anticoagulant_list", $anticoagulant_list);
$smarty->assign("timing", $timing);
$smarty->assign("list_cell_saver", $list_cell_saver);
$smarty->assign("inLivretTherapeutique", $inLivretTherapeutique);
$smarty->display("inc_bloodSalvage.tpl");
Пример #3
0
CCanDo::checkRead();
$mean_fields = array("age", "wash_volume", "saved_volume", "transfused_volume", "hgb_pocket", "hgb_patient");
$possible_filters = array_merge(array('chir_id', 'anesth_id', 'codes_ccam', 'code_asa', 'cell_saver_id'), $mean_fields);
$filters = CValue::getOrSession('filters', array());
$months_count = CValue::getOrSession('months_count', 12);
$months_relative = CValue::getOrSession('months_relative', 0);
$comparison = CValue::getOrSession('comparison', $possible_filters);
$comparison_left = CValue::getOrSession('comparison_left');
$comparison_right = CValue::getOrSession('comparison_right');
$mode = CValue::get('mode');
foreach ($possible_filters as $n) {
    if (!isset($filters[$n])) {
        $filters[$n] = null;
    }
}
$cell_saver = new CCellSaver();
$cell_savers = $cell_saver->loadList(null, "marque, modele");
$user = new CMediusers();
$user->load(CAppUI::$instance->user_id);
$mediuser = new CMediusers();
$fields = array("anesth_id" => $mediuser->loadListFromType(array('Anesthésiste')), "chir_id" => $mediuser->loadListFromType(array('Chirurgien'), $user->isAnesth() ? null : PERM_READ), "codes_asa" => range(1, 5), "cell_saver_id" => $cell_savers);
$smarty = new CSmartyDP();
// Filter
$smarty->assign('filters', $filters);
$smarty->assign('months_relative', $months_relative);
$smarty->assign('months_count', $months_count);
$smarty->assign('mode', $mode);
// Lists
$smarty->assign('fields', $fields);
$smarty->assign('mean_fields', $mean_fields);
$smarty->display('vw_stats.tpl');