本文整理汇总了PHP中CMbObject::loadRefSejour方法的典型用法代码示例。如果您正苦于以下问题:PHP CMbObject::loadRefSejour方法的具体用法?PHP CMbObject::loadRefSejour怎么用?PHP CMbObject::loadRefSejour使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CMbObject
的用法示例。
在下文中一共展示了CMbObject::loadRefSejour方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: addReponses
/**
* Ajout des éléments Reponses
*
* @param string $statut Statut de l'acquittement
* @param array $codes Codes d'erreurs
* @param string $commentaires Commentaire
* @param CMbObject $mbObject Object
* @param array $data Datas
*
* @return void
*/
function addReponses($statut, $codes, $commentaires = null, $mbObject = null, $data = array())
{
$acquittementsServeurActivitePmsi = $this->documentElement;
$mbPatient = $mbSejour = null;
if ($mbObject instanceof CSejour) {
$mbPatient = $mbObject->loadRefPatient();
$mbSejour = $mbObject;
}
if ($mbObject instanceof COperation) {
$mbPatient = $mbObject->loadRefSejour()->loadRefPatient();
$mbSejour = $mbObject->_ref_sejour;
}
// Ajout des réponses
$reponses = $this->addElement($acquittementsServeurActivitePmsi, "reponses");
// Ajout du patient et de la venue
$patient = $this->addElement($reponses, "patient");
if (isset($mbPatient->_id)) {
$this->addPatient($patient, $mbPatient, false, true);
}
$venue = $this->addElement($reponses, "venue");
if (isset($mbSejour->_id)) {
$this->addVenue($venue, $mbSejour, false, true);
}
if (!is_array($codes)) {
if (!isset($mbPatient->_id)) {
$this->addPatientError($reponses, $data);
}
$this->addReponseGeneral($reponses, $statut, $codes, null, $mbObject, $commentaires, $data);
return;
}
// Génération des réponses en fonction du type de l'acquittement
switch (get_class($this)) {
case "CHPrimXMLAcquittementsServeurActes":
if (!$data && !CMbArray::get($data, "CCAM") && !CMbArray::get($data, "NGAP")) {
break;
}
$actesCCAM = $data["CCAM"];
$actesNGAP = $data["NGAP"];
foreach ($actesCCAM as $_acteCCAM) {
$code_ccam = $codes[$_acteCCAM["idSourceActeCCAM"]];
$this->addReponseCCAM($reponses, $_acteCCAM["statut"], $code_ccam["code"], $_acteCCAM, $mbObject, $code_ccam["commentaires"]);
}
foreach ($actesNGAP as $_acteNGAP) {
$code_ngap = $codes[$_acteNGAP["idSourceActeNGAP"]];
$this->addReponseNGAP($reponses, $_acteNGAP["statut"], $code_ngap["code"], $_acteNGAP, $mbObject, $code_ngap["commentaires"]);
}
break;
case "CHPrimXMLAcquittementsServeurIntervention":
$this->addReponseIntervention($reponses, $statut, $codes, null, $mbObject, $commentaires);
break;
}
}
示例2: getMovement
/**
* Get movement
*
* @param CMbObject $object Object
*
* @return void
*/
function getMovement(CMbObject $object)
{
if ($object instanceof CSejour) {
$this->sejour_id = $object->_id;
}
if ($object instanceof CAffectation) {
$sejour = $object->loadRefSejour();
$this->sejour_id = $sejour->_id;
$this->affectation_id = $object->_id;
}
$this->movement_type = $object->getMovementType();
$this->loadMatchingObject();
}