Initial Checking with all 820 MLMs
This commit is contained in:
157
MLMStripper/bin/Debug/SCH/SCH_HALOPERIDOL_ORDER_ALERT.mlm
Normal file
157
MLMStripper/bin/Debug/SCH/SCH_HALOPERIDOL_ORDER_ALERT.mlm
Normal file
@@ -0,0 +1,157 @@
|
||||
maintenance:
|
||||
|
||||
title: SCH_HALOPERIDOL_ORDER_ALERT;;
|
||||
mlmname: SCH_HALOPERIDOL_ORDER_ALERT;;
|
||||
arden: version 2.50;;
|
||||
version: 15.1;;
|
||||
institution: St. Clair Hospital;;
|
||||
author: Bryan Berkeybile, Allscripts Corp;;
|
||||
specialist: Bryan Berkeybile;;
|
||||
date: 2016-04-28;;
|
||||
validation: testing;;
|
||||
|
||||
library:
|
||||
purpose:
|
||||
;;
|
||||
explanation: Fire an alert to nurses and unit secretaries (in addition to prescribers
|
||||
and pharmacists) when haloperidol is ordered for a patient with a health issue/diagnosis of
|
||||
Parkinson{{{SINGLE-QUOTE}}}s Disease.
|
||||
|
||||
Change History
|
||||
|
||||
08.02.2016 BB CSR#34186 Created CSR# 34186
|
||||
|
||||
;;
|
||||
keywords:
|
||||
;;
|
||||
knowledge:
|
||||
type: data-driven;;
|
||||
data:
|
||||
//Logging level of execution information
|
||||
log_execution_info:=FALSE;
|
||||
|
||||
// Set the text for this variable to indicate whether to send the message or not.
|
||||
send_alert := "DoNotSend";
|
||||
|
||||
//BB
|
||||
|
||||
soft_message := false;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//Set stop
|
||||
sync_alert_dialog := "Must Comment";
|
||||
hard_stop := false;
|
||||
found_unsubmitted_orders := false;
|
||||
existing_orders := ();
|
||||
alert_priority := "HIGH";
|
||||
include_generic_msg := true;
|
||||
include_trans_msg := false;
|
||||
|
||||
//Destination Object Properties
|
||||
alert_dialog := "Must Acknowledge";
|
||||
alert_message := "";
|
||||
alert_override_msg := "";
|
||||
ok_to_show_aoa := false;
|
||||
|
||||
//BB
|
||||
|
||||
|
||||
(ClientVisitGuid, ChartGuid, ClientGuid) := read last {ClientVisit: GUID, ChartGUID, ClientGUID};
|
||||
(UserGUID ) := read last { UserInfo: GUID };
|
||||
|
||||
|
||||
|
||||
|
||||
HealthIssue := read last
|
||||
{"SELECT cv.ClientGuid " //,cv.IDCode,cv.VisitIDCode "
|
||||
// || " ,chi.Code,hid.ShortName,chi.TypeCode ,hid.TypeCode "
|
||||
|| " FROM CV3ClientVisit cv "
|
||||
|| " JOIN CV3HealthIssueDeclaration hid ON hid.ClientVisitGUID = cv.GUID "
|
||||
|| " left JOIN CV3CodedHealthIssue chi ON hid.CodedHealthIssueGUID = chi.GUID "
|
||||
|| " WHERE hid.ShortName like {{{SINGLE-QUOTE}}}%park%{{{SINGLE-QUOTE}}} AND hid.active=1 "
|
||||
|| " AND cv.clientGuid = " || SQL(ClientGuid)
|
||||
};
|
||||
|
||||
|
||||
//endif;
|
||||
|
||||
If healthissue is null then
|
||||
continue := "no";
|
||||
else
|
||||
continue := "yes";
|
||||
endif;
|
||||
|
||||
if continue = "yes" then
|
||||
|
||||
|
||||
|
||||
// Use String parse
|
||||
// str_parse := mlm {{{SINGLE-QUOTE}}}UTIL_STRING_PARSE{{{SINGLE-QUOTE}}}; ???? BB
|
||||
|
||||
//The evoking event for this MLM is OrderInit
|
||||
evoking_event_order:=EVENT {OrderInit User Order:
|
||||
Where Name Matches Pattern "Haloperidol%" };
|
||||
|
||||
// BB Added 5/2/16 : Used for testing
|
||||
Haloperidol_Order_Event := event{ OrderInit User Order :
|
||||
WHERE Name = "Haloperidol 1mg Tab"};
|
||||
|
||||
|
||||
// BB Added 5/2/16
|
||||
order_alert_dest := destination {alert} with
|
||||
[alert_type := warning,
|
||||
short_message := "Haloperidol Order Conflict",
|
||||
priority := alert_priority,
|
||||
scope := Chart,
|
||||
rule_group := "Haloperidol Order Group",
|
||||
rule_number := 9010,
|
||||
send_with_order := send_alert,
|
||||
// alert_dialog_settings := alert_dialog,
|
||||
alert_dialog_settings := sync_alert_dialog,
|
||||
display_alert := true];
|
||||
|
||||
|
||||
|
||||
//if ((EvokingEvent = Haloperidol_Order_event)) then
|
||||
// existing
|
||||
if ((EvokingEvent = Haloperidol_Order_event)) then
|
||||
soft_message := true;
|
||||
order_name := orderItem;
|
||||
//alert_dialog := "No Override Allowed";
|
||||
endif;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
order_alert_dest.Priority := alert_priority;
|
||||
order_alert_dest.Alert_Dialog_Settings := sync_alert_dialog; //was: alert_dialog;
|
||||
|
||||
|
||||
//if (stop_message) then
|
||||
order_alert_message := "Haloperidol is CONTRAINDICATED in Parkinsons Disease since it may cause a worsening of the patient’s Parkinsons symptoms. Recommend Quetiapine 25mg PO, NOW and QHS";
|
||||
|
||||
|
||||
Endif;
|
||||
;;
|
||||
evoke: evoking_event_order // or Haloperidol_Order_Event
|
||||
|
||||
|
||||
;;
|
||||
logic:
|
||||
if continue = "no"
|
||||
then
|
||||
conclude false;
|
||||
else conclude true ;
|
||||
endif;
|
||||
|
||||
|
||||
;;
|
||||
action:
|
||||
Write order_alert_message at order_alert_dest;
|
||||
;;
|
||||
Urgency: 50;;
|
||||
end:
|
||||
Reference in New Issue
Block a user