maintenance: title: Lab Stool Culture on Order Set Must Order Shiga Toxin 1 and 2;; mlmname: FORM_Set_ED_Respiratory;; arden: version 2;; version: 4.50;; institution: St Clair ED Respiratory;; author: Robert Spence, Eclipsys Corp Ext 7461;; specialist: Lisa Hancher, Eclipsys Corp ext PINT;; date: 2008-03-17;; validation: testing;; library: purpose: When user selects items on an order set, fill in a summary line (special instructions) This field is to be mapped to one on the pager form. This MLM will then fill in the data based on the selected checkboxes, having the interface only need to look at the data within the pager form (not every order in the set) ;; explanation: This MLM is called from the ED Respiratory Order Set (ED_Respiratory) ;; keywords: Called MLMs, Respiratory ORder Sert, ED ;; knowledge: type: data-driven;; data: // This MLM is passed three arguments, of types // communication_type, form_type and client info object respectively. (this_communication, // Communication object this_form, // Form object client_info_obj //Arden ClientInfo object ) := argument; /*******************Make Changes To Spelling And Flags In This Section*******************/ /* Set to true if a decision.log is needed.*/ log_execution_info := FALSE; /***************************************************************************************/ // Initialize error message error_message:=""; // Assigns fields passed in the Form object to the Field object field_list:= this_form.fields; CallingEvent := this_communication.CallingEvent; CallingField := this_communication.CallingFieldName; ClientGuid:=this_communication.ClientGUID; ClientChartGUID:=this_communication.ChartGUID; //Associate Mapped Fields SponAer_fld := last of (field_list where field_list.DataItemName = "Spontaneous Aerosol"); SponAerAtro_fld := last of (field_list where field_list.DataItemName ="Spontaneous Aerosol Atrovent"); SponAerAtr_fld := last of (field_list where field_list.DataItemName = "Spontaneous Aerosol DuoNeb"); SponAerRac_fld := last of (field_list where field_list.DataItemName = "Spontaneous Aerosol Racepinephrine"); Bronch10_Fld := last of (field_list where field_list.DataItemName = "Cont. Bronchodilator Albuterol 10mg/hr"); Bronch15_Fld := last of (field_list where field_list.DataItemName = "Cont. Bronchodilator Albuterol 15mg/hr"); MDI_fld := last of (field_list where field_list.DataItemName = "MDI Instruction"); Incent_fld := last of (field_list where field_list.DataItemName = "Incentive Spirometry Instruction"); //*** Get the Aerosols Values From Grid Aerosols_fld := last of (field_list where field_list.DataItemName = "MultiOrderGrid" and field_List.Control_MultiFieldOccNum = 4); Aerosols_list :=Aerosols_fld.Value; Aerosols_Sel :=Aerosols_list.IsSelected; Albuterol:= Last (First 1 from Aerosols_Sel); Atrovent:= Last (First 2 from Aerosols_Sel); AlbuterolAtrovent:= Last (First 3 from Aerosols_Sel); RacePine:= Last (First 4 from Aerosols_Sel); //*** Get the Bronchodilator Values from Grid Broncho_fld := last of (field_list where field_list.DataItemName = "MultiOrderGrid" and field_List.Control_MultiFieldOccNum = 6); Broncho_list :=Broncho_fld.Value; Broncho_Sel :=Broncho_list.IsSelected; Bron10 := Last (First 1 From Broncho_Sel); Bron15 := Last (First 2 From Broncho_Sel); //*** Get the Education Values from Grid Educate_fld := last of (field_list where field_list.DataItemName = "MultiOrderGrid" and field_List.Control_MultiFieldOccNum = 5); Educate_list :=Educate_fld.Value; Educate_Sel :=Educate_list.IsSelected; EducateMDI := Last (First 1 From Educate_Sel); EducateInc:= Last (First 2 From Educate_Sel); //*** Now set the mapped fields SponAer_fld.Value := Albuterol; SponAerAtro_fld .Value := Atrovent; SponAerAtr_fld.Value := AlbuterolAtrovent; SponAerRac_Fld.Value :=RacePine; Bronch10_Fld.Value := Bron10; Bronch15_Fld.Value := Bron15; MDI_fld.Value := EducateMDI; Incent_fld.Value := EducateInc; /* Debugging Messages this_communication.DisplayForm := "Yes"; this_communication.Message := "Aerosol Selected is " || Aerosols_Sel || "\n" || " Albuterol is set to " || Albuterol || "\n" || " Albuterol Atrovent is set to " || AlbuterolAtrovent || "\n" || " RacePine is set to " || RacePine || "\n" || "\n" || "Broncho Selected is " || Broncho_Sel || "\n" || " Bronch 10 is set to " || Bron10 || "\n" || " Bronch 15 is set to " || Bron15 || "\n" || "\n" || "Educate Selects is " || EDucate_Sel || "\n" || " Educate MDI is set to " || EducateMDI || "\n" || " Educate Incentive is " || EducateINC || "\n" || "\n" || "Mapped Field Values Are " || "\n" || " SponAer is " || SponAer_fld.value || "\n" || " SponAerAtr is " || SponAerAtr_fld.Value || "\n" || " SponAerRac is " || SponAerRac_Fld.Value || "\n" || " Bronch10 is " || Bronch10_Fld.Value || "\n" || " Bronch15 is " || Bronch15_Fld.Value || "\n" || " MDI is " || MDI_fld.Value || "\n" || " Incent is " || Incent_fld.Value; this_communication.MessageType := "Informational"; */ ;; evoke: // No evoke statement ;; logic: conclude true; ;; action: // This MLM returns two parameters, of types communication_type and form_type respectively. return this_communication, this_form; ;; end: