uasort($listSejours, "ccmu_cmp"); } // Chargement des boxes d'urgences $boxes = array(); foreach (CService::loadServicesUHCD() as $service) { foreach ($service->_ref_chambres as $chambre) { foreach ($chambre->_ref_lits as $lit) { $boxes[$lit->_id] = $lit; } } } // Si admin sur le module urgences, alors modification autorisée du diagnostic // infirmier depuis la main courante. $module = new CModule(); $module->mod_name = "dPurgences"; $module->loadMatchingObject(); $admin_urgences = $module->canAdmin(); // Création du template $smarty = new CSmartyDP(); $smarty->assign("boxes", $boxes); $smarty->assign("order_col", $order_col); $smarty->assign("order_way", $order_way); $smarty->assign("listPrats", $listPrats); $smarty->assign("listSejours", $listSejours); $smarty->assign("uhcd_affichage", $uhcd_affichage); $smarty->assign("medicalView", $medicalView); $smarty->assign("date", $date); $smarty->assign("date_before", $date_before); $smarty->assign("today", CMbDT::date()); $smarty->assign("isImedsInstalled", CModule::getActive("dPImeds") && CImeds::getTagCIDC(CGroups::loadCurrent())); $smarty->assign("admin_urgences", $admin_urgences);