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


PHP CPatient::applyModeIdentitoVigilance方法代码示例

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


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

示例1: getXPN

 /**
  * Get XPN : extended composite name & ID for organizations
  *
  * @param CMbObject        $object   Object
  * @param CInteropReceiver $receiver Receiver
  *
  * @return array
  */
 function getXPN(CMbObject $object, CInteropReceiver $receiver = null)
 {
     $names = array();
     if ($object instanceof CPatient) {
         $anonyme = is_numeric($object->nom);
         $mode_identito_vigilance = "light";
         if ($receiver) {
             $mode_identito_vigilance = $receiver->_configs["mode_identito_vigilance"];
         }
         $nom = CPatient::applyModeIdentitoVigilance($object->nom, false, $mode_identito_vigilance, $anonyme);
         $prenom = CPatient::applyModeIdentitoVigilance($object->prenom, true, $mode_identito_vigilance, $anonyme);
         $prenom_2 = CPatient::applyModeIdentitoVigilance($object->prenom_2, true, $mode_identito_vigilance, $anonyme);
         $prenom_3 = CPatient::applyModeIdentitoVigilance($object->prenom_3, true, $mode_identito_vigilance, $anonyme);
         $prenom_4 = CPatient::applyModeIdentitoVigilance($object->prenom_4, true, $mode_identito_vigilance, $anonyme);
         $prenoms = array($prenom_2, $prenom_3, $prenom_4);
         CMbArray::removeValue("", $prenoms);
         // Nom usuel
         $patient_usualname = array($nom, $prenom, implode(",", $prenoms), null, $object->civilite, null, is_numeric($nom) ? "S" : "L", "A");
         $patient_birthname = array();
         // Cas nom de naissance
         if ($object->nom_jeune_fille) {
             $nom_jeune_fille = CPatient::applyModeIdentitoVigilance($object->nom_jeune_fille, true, $mode_identito_vigilance, $anonyme);
             $patient_birthname = $patient_usualname;
             $patient_birthname[0] = $nom_jeune_fille;
             // Legal Name devient Display Name
             $patient_usualname[6] = "D";
         }
         $names[] = $patient_usualname;
         if ($object->nom_jeune_fille && $receiver && $receiver->_configs["build_PID_6"] == "none") {
             $names[] = $patient_birthname;
         }
     }
     if ($object instanceof CCorrespondantPatient) {
         $names[] = array($object->nom, $object->prenom, null, null, null, null, is_numeric($object->nom) ? "S" : "L", "A");
     }
     return $names;
 }
开发者ID:OpenXtrem,项目名称:mediboard_save,代码行数:45,代码来源:CHL7v2Segment.class.php

示例2: build

 /**
  * Build PID segement
  *
  * @param CHL7v2Event $event Event
  *
  * @return null
  */
 function build(CHL7v2Event $event)
 {
     parent::build($event);
     $message = $event->message;
     $receiver = $event->_receiver;
     $group = $receiver->loadRefGroup();
     $patient = $this->patient;
     $mother = null;
     $sejour_maman = null;
     $naissance = null;
     if ($patient->_naissance_id) {
         $naissance = new CNaissance();
         $naissance->load($patient->_naissance_id);
         $sejour_maman = $naissance->loadRefSejourMaman();
         $sejour_maman->loadNDA($group->_id);
         $sejour_maman->loadRefPatient()->loadIPP($group->_id);
         $mother = $sejour_maman->_ref_patient;
     }
     $data = array();
     // PID-1: Set ID - PID (SI) (optional)
     $data[] = $this->set_id;
     // PID-2: Patient ID (CX) (optional)
     $data[] = null;
     // PID-3: Patient Identifier List (CX) (repeating)
     $data[] = $this->getPersonIdentifiers($patient, $group, $receiver);
     // PID-4: Alternate Patient ID - PID (CX) (optional repeating)
     $data[] = null;
     // PID-5: Patient Name (XPN) (repeating)
     $data[] = $this->getXPN($patient, $receiver);
     // PID-6: Mother's Maiden Name (XPN) (optional repeating)
     if ($patient->nom_jeune_fille && $receiver->_configs["build_PID_6"] == "nom_naissance") {
         $anonyme = is_numeric($patient->nom);
         $mode_identito_vigilance = $receiver->_configs["mode_identito_vigilance"];
         $prenom = CPatient::applyModeIdentitoVigilance($patient->prenom, true, $mode_identito_vigilance, $anonyme);
         $nom_jf = CPatient::applyModeIdentitoVigilance($patient->nom_jeune_fille, true, $mode_identito_vigilance, $anonyme);
         $data[] = array(array($nom_jf, $prenom, null, null, null, null, null, "L"));
     } else {
         // Dans le cas d'une naissance on va mettre l'identité de la mère
         $data[] = $mother ? $this->getXPN($mother, $receiver) : null;
     }
     // PID-7: Date/Time of Birth (TS) (optional)
     if ($patient->_naissance_id) {
         $data[] = $naissance->date_time;
     } else {
         if ($patient->naissance) {
             $data[] = CMbDT::isLunarDate($patient->naissance) ? null : $patient->naissance;
         } else {
             $data[] = null;
         }
     }
     // PID-8: Administrative Sex (IS) (optional)
     // Table - 0001
     // F - Female
     // M - Male
     // O - Other
     // U - Unknown
     // A - Ambiguous
     // N - Not applicable
     $sexe = CHL7v2TableEntry::mapTo("1", $patient->sexe);
     $data[] = $sexe ?: "U";
     // PID-9: Patient Alias (XPN) (optional repeating)
     $data[] = null;
     // PID-10: Race (CE) (optional repeating)
     $data[] = null;
     // PID-11: Patient Address (XAD) (optional repeating)
     $address = array();
     if ($patient->adresse || $patient->ville || $patient->cp) {
         $linesAdress = explode("\n", $patient->adresse, 2);
         $address[] = array(CValue::read($linesAdress, 0), str_replace("\n", $message->componentSeparator, CValue::read($linesAdress, 1)), $patient->ville, null, $patient->cp, CPaysInsee::getAlpha3($patient->pays_insee), "H");
     }
     if ($receiver->_configs["build_PID_11"] == "simple") {
         $address = array(reset($address));
     } else {
         if ($patient->lieu_naissance || $patient->cp_naissance || $patient->pays_naissance_insee) {
             $address[] = array(null, null, $patient->lieu_naissance, null, $patient->cp_naissance, CPaysInsee::getAlpha3($patient->pays_naissance_insee), "BDL");
         }
     }
     $data[] = $address;
     // PID-12: County Code (IS) (optional)
     $data[] = null;
     // PID-13: Phone Number - Home (XTN) (optional repeating)
     // Table - 0201
     // ASN - Answering Service Number
     // BPN - Beeper Number
     // EMR - Emergency Number
     // NET - Network (email) Address
     // ORN - Other Residence Number
     // PRN - Primary Residence Number
     // VHN - Vacation Home Number
     // WPN - Work Number
     // Table - 0202
     // BP       - Beeper
     // CP       - Cellular Phone
//.........这里部分代码省略.........
开发者ID:OpenXtrem,项目名称:mediboard-test,代码行数:101,代码来源:CHL7v2SegmentPID.class.php

示例3: build

 /**
  * Build IN1 segement
  *
  * @param CHL7v2Event $event Event
  *
  * @return null
  */
 function build(CHL7v2Event $event)
 {
     parent::build($event);
     $message = $event->message;
     $receiver = $event->_receiver;
     $group = $receiver->loadRefGroup();
     /** @var CPatient $patient */
     $patient = $this->patient;
     $data = array();
     // IN1-1: Insured's Employee ID
     $data[] = $this->set_id;
     // IN1-2: Insured's Social Security Number
     $data[] = $this->getIN12($patient);
     // IN1-3: Insurance Company ID (CX) (repeating)
     $data[] = array($patient->code_regime . $patient->caisse_gest . $patient->centre_gest);
     // IN1-4: Insurance Company Name (XON) (optional repeating)
     $data[] = null;
     // IN1-5: Insurance Company Address (XAD) (optional repeating)
     $data[] = null;
     // IN1-6: Insurance Co Contact Person (XPN) (optional repeating)
     $data[] = null;
     // IN1-7: Insurance Co Phone Number (XTN) (optional repeating)
     $data[] = null;
     // IN1-8: Group Number (ST) (optional)
     $data[] = null;
     // IN1-9: Group Name (XON) (optional repeating)
     $data[] = null;
     // IN1-10: Insured's Group Emp ID (CX) (optional repeating)
     $data[] = null;
     // IN1-11: Insured's Group Emp Name (XON) (optional repeating)
     $data[] = null;
     // IN1-12: Plan Effective Date (DT) (optional)
     $data[] = $patient->deb_amo;
     // IN1-13: Plan Expiration Date (DT) (optional)
     $data[] = $patient->fin_amo;
     // IN1-14: Authorization Information (AUI) (optional)
     $data[] = null;
     // IN1-15: Plan Type (IS) (optional)
     $data[] = null;
     // IN1-16: Name Of Insured (XPN) (optional repeating)
     $names = array();
     $mode_identito_vigilance = "light";
     if ($receiver) {
         $mode_identito_vigilance = $receiver->_configs["mode_identito_vigilance"];
     }
     $anonyme = is_numeric($patient->assure_nom);
     $nom = CPatient::applyModeIdentitoVigilance($patient->assure_nom, false, $mode_identito_vigilance);
     $prenom = CPatient::applyModeIdentitoVigilance($patient->assure_prenom, true, $mode_identito_vigilance, $anonyme);
     $prenom_2 = CPatient::applyModeIdentitoVigilance($patient->assure_prenom_2, true, $mode_identito_vigilance, $anonyme);
     $prenom_3 = CPatient::applyModeIdentitoVigilance($patient->assure_prenom_3, true, $mode_identito_vigilance, $anonyme);
     $prenom_4 = CPatient::applyModeIdentitoVigilance($patient->assure_prenom_4, true, $mode_identito_vigilance, $anonyme);
     $prenoms = array($prenom_2, $prenom_3, $prenom_4);
     CMbArray::removeValue("", $prenoms);
     // Nom usuel
     $assure_usualname = array($nom, $prenom, implode(",", $prenoms), null, $patient->assure_civilite, null, is_numeric($nom) ? "S" : "L", "A");
     $assure_birthname = array();
     // Cas nom de naissance
     if ($patient->assure_nom_jeune_fille) {
         $nom_jeune_fille = CPatient::applyModeIdentitoVigilance($patient->assure_nom_jeune_fille, true, $mode_identito_vigilance, $anonyme);
         $assure_birthname = $assure_usualname;
         $assure_birthname[0] = $nom_jeune_fille;
         // Legal Name devient Display Name
         $assure_usualname[6] = "D";
     }
     $names[] = $assure_usualname;
     if ($patient->assure_nom_jeune_fille && $receiver && $receiver->_configs["build_PID_6"] == "none") {
         $names[] = $assure_birthname;
     }
     $data[] = $names;
     // IN1-17: Insured's Relationship To Patient (CE) (optional)
     $data[] = $patient->qual_beneficiaire;
     // IN1-18: Insured's Date Of Birth (TS) (optional)
     $data[] = $patient->assure_naissance;
     // IN1-19: Insured's Address (XAD) (optional repeating)
     $address = array();
     $linesAdress = explode("\n", $patient->assure_adresse, 2);
     $address[] = array(CValue::read($linesAdress, 0), str_replace("\n", $message->componentSeparator, CValue::read($linesAdress, 1)), $patient->assure_ville, null, $patient->assure_cp, CPaysInsee::getAlpha3($patient->assure_pays_insee), "H");
     $data[] = $address;
     // IN1-20: Assignment Of Benefits (IS) (optional)
     $data[] = null;
     // IN1-21: Coordination Of Benefits (IS) (optional)
     $data[] = null;
     // IN1-22: Coord Of Ben. Priority (ST) (optional)
     $data[] = null;
     // IN1-23: Notice Of Admission Flag (ID) (optional)
     $data[] = null;
     // IN1-24: Notice Of Admission Date (DT) (optional)
     $data[] = null;
     // IN1-25: Report Of Eligibility Flag (ID) (optional)
     $data[] = null;
     // IN1-26: Report Of Eligibility Date (DT) (optional)
     $data[] = null;
     // IN1-27: Release Information Code (IS) (optional)
//.........这里部分代码省略.........
开发者ID:fbone,项目名称:mediboard4,代码行数:101,代码来源:CHL7v2SegmentIN1.class.php


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