Initial Checking with all 820 MLMs

This commit is contained in:
2020-02-02 00:54:01 -05:00
parent c59dc6de2e
commit 840d0432f4
828 changed files with 239162 additions and 0 deletions

View File

@@ -0,0 +1,201 @@
maintenance:
title: FORM_Set_Open_Heart_Anesthesia;;
mlmname: FORM_Set_Open_Heart_Anesthesia;;
arden: version 2.5;;
version: 16.3;;
institution: St Clair Hospital;;
author: Teresa Spicuzza;;
specialist: Michele Palmer;;
date: 2018-11-02;;
validation: testing;;
library:
purpose: Used for Post Open Heart anesthesia Order Set
;;
explanation: This MLM is called from the Post Open Heart Anesthesia Order Set to calculate the Standard Dose Sugammadex (Bridion) at 2mg/kg, rounded to the nearest whole number.
Also only allows for either the standard dosing of a drug or the non standard dosing of a drug to be selected, but not both.
Change History
11.02.2018 TMS CSR 37529 Created to calculate Sugammadex for Standard Dosing Grid at 2mg/kg. Added logic to only allow a drug to be selected in either the Standard dosing grid
or the non standard dosing grid, but not both. This was previously handled by the Generic MLM.
;;
keywords: Called MLMs, Post Open Heart Anesthesia
;;
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;
/***************************************************************************************/
// Use String parse
str_parse := mlm {{{SINGLE-QUOTE}}}UTIL_STRING_PARSE{{{SINGLE-QUOTE}}};
// Initialize error message
error_message:="";
// Assigns fields passed in the Form object to the Field object
field_list:= this_form.fields;
standard_libs := MLM {{{SINGLE-QUOTE}}}std_include_libs{{{SINGLE-QUOTE}}};
include standard_libs;
client_guid := this_communication.ClientGUID;
visit_guid := this_communication.ClientVisitGUID;
chart_guid := this_communication.ChartGuid;
CallingEvent := this_communication.CallingEvent;
CallingField := this_communication.CallingFieldName;
Standard_Dose_Grid := last of (field_list where field_list.DataItemName = "MultiOrderGrid"
and field_List.Control_MultiFieldOccNum = 11);
Standard_Dose_List :=Standard_Dose_Grid.Value;
NonStandard_Dose_Grid := last of (field_list where field_list.DataItemName = "MultiOrderGrid"
and field_List.Control_MultiFieldOccNum = 12);
NonStandard_Dose_List :=NonStandard_Dose_Grid.Value;
Sugammadex := first of (Standard_Dose_List where Standard_Dose_List.Name = "Sugammadex Inj");
Neostigmine := first of (Standard_Dose_List where Standard_Dose_List.Name = "Neostigmine Inj");
Physostigmine := first of (Standard_Dose_List where Standard_Dose_List.Name = "Physostigmine Inj");
Glycopyrrolate := first of (Standard_Dose_List where Standard_Dose_List.Name = "Glycopyrrolate Inj");
Sugammadex_NonStd:= first of (NonStandard_Dose_List where NonStandard_Dose_List.Name = "Sugammadex Inj");
Neostigmine_NonStd := first of (NonStandard_Dose_List where NonStandard_Dose_List.Name = "Neostigmine Inj");
Physostigmine_NonStd := first of (NonStandard_Dose_List where NonStandard_Dose_List.Name = "Physostigmine Inj");
Glycopyrrolate_NonStd := first of (NonStandard_Dose_List where NonStandard_Dose_List.Name = "Glycopyrrolate Inj");
Calc_Dose := first of (field_list where field_list.DataItemName = "DosageLow"
and field_List.Control_MultiFieldOccNum = 1);
Calc_Dose_Value := Calc_Dose.value;
comb_ht_wt_fld := first of (field_list
where field_list.DataItemName = "CombinedMeasurements" and field_List.Control_MultiFieldOccNum = 2);
if exists comb_ht_wt_fld then
comb_ht_wt_val := comb_ht_wt_fld.Value;
wt := comb_ht_wt_val.weight;
ht := comb_ht_wt_val.height;
wt_type := comb_ht_wt_val.weighttype;
bsa := comb_ht_wt_val.bsa;
bmi := comb_ht_wt_val.bmi;
endif;
If CallingEvent = "FormOpen" Then
Calc_Raw_Dose := wt * 2;
round_dose := int((Calc_Raw_Dose + 0.5)/1) * 1;
Calc_Dose.value := round_dose;
endif;
If CallingEvent = "FieldChange" then
If CallingField = "MultiOrderGrid|11" then
If Sugammadex.IsSelected = True then
If wt is null or wt = 0 then
msg1 := call {{{SINGLE-QUOTE}}}MessageBox{{{SINGLE-QUOTE}}}.Show with "\n Sugammadex (Bridion) is calculated at 2mg/kg. \n\n Please enter a weight for this patient." ,"Sunrise Clinical Manager", "OK" as {{{SINGLE-QUOTE}}}MessageBoxButtons{{{SINGLE-QUOTE}}},"Warning" as {{{SINGLE-QUOTE}}}MessageBoxIcon{{{SINGLE-QUOTE}}};
Calc_Dose.value := null;
else
Calc_Raw_Dose := wt * 2;
round_dose := int((Calc_Raw_Dose + 0.5)/1) * 1;
Calc_Dose.value := round_dose;
endif;
Sugammadex_NonStd.IsReadOnly := True;
elseif Sugammadex.IsSelected = False then
Sugammadex_NonStd.IsReadOnly := False;
endif;
If Neostigmine.IsSelected = True then
Neostigmine_NonStd.IsReadOnly := True;
Neostigmine.IsReadOnly := False;
elseif Neostigmine.IsSelected = False then
Neostigmine_NonStd.IsReadOnly := False;
endif;
If Physostigmine.IsSelected = True then
Physostigmine_NonStd.IsReadOnly := True;
elseif Physostigmine.IsSelected = False then
Physostigmine_NonStd.IsReadOnly := False;
endif;
If Glycopyrrolate.IsSelected = True then
Glycopyrrolate_NonStd.IsReadOnly := True;
elseif Glycopyrrolate.IsSelected = False then
Glycopyrrolate_NonStd.IsReadOnly := False;
endif;
endif; //If CallingField = "MultiOrderGrid|11"
If CallingField = "MultiOrderGrid|12" then
If Sugammadex_NonStd.IsSelected = True then
Sugammadex.IsReadOnly := True;
elseif Sugammadex_NonStd.IsSelected = False then
Sugammadex.IsReadOnly := False;
endif;
If Neostigmine_NonStd.IsSelected = True then
Neostigmine.IsReadOnly := True;
elseif Neostigmine_NonStd.IsSelected = False then
Neostigmine.IsReadOnly := False;
endif;
If Physostigmine_NonStd.IsSelected = True then
Physostigmine.IsReadOnly := True;
elseif Physostigmine_NonStd.IsSelected = False then
Physostigmine.IsReadOnly := False;
endif;
If Glycopyrrolate_NonStd.IsSelected = True then
Glycopyrrolate.IsReadOnly := True;
elseif Glycopyrrolate_NonStd.IsSelected = False then
Glycopyrrolate.IsReadOnly := False;
endif;
endif; //If CallingField = "MultiOrderGrid|12"
If CallingField = "CombinedMeasurements|2" then
If wt is null or wt = 0 then
Calc_Dose.value := null;
else
Calc_Raw_Dose := wt * 2;
round_dose := int((Calc_Raw_Dose + 0.5)/1) * 1;
Calc_Dose.value := round_dose;
endif;
endif; //If CallingField = "CombinedMeasurements|2"
endif; //If CallingEvent = "FieldChange"
;;
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: