maintenance: title: FORM_LAB_PRIORITY_OPTIONS;; mlmname: FORM_LAB_PRIORITY_OPTIONS;; arden: version 2;; version: 4.50;; institution: St Clair Isolation Set MLM;; author: Eclipsys Corp;; specialist: Shawn Head;; date: 2014-11-24;; validation: testing;; library: purpose: MLM will display either the custom priorities or system priorites and assign the proper schedule to the lab orders. ;; explanation: This MLM can be called from any fields on a form that need to trigger the custom priority fields added to the lab forms. This MLM will display a custom UDDI that has "user fiendly" descriptions. The called MLM SCH_LAB_PRIORITY_OPTIONS_CALLED is the MLM that actually does all the logic. If there are other MLM{{{SINGLE-QUOTE}}}s already attached to form fields on the MLM then their is a section commented out below that can be copied/pasted into other MLM{{{SINGLE-QUOTE}}}s to call the MLM properly. There are configuration pieces that Maria Pest put in place for all this to work properly with the MLM. See the CSR request details for more information. This logic will work on both Order forms and Order Set Forms. Change History 2014.11.24 - STH CSR#: 32765 - Created MLM 2015.03.09 - STH CSR#: 32765 - Issues addressed based on users feed back (showing the time field disabled instead of hidding it,adding section for order set calling, and making sure all fields are working from both order entry and being called from Order Sets). ;; keywords: Called MLMs, Form fields, schedule ;; 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*******************/ /* These variables must containt he same wording as the options in the drop down list */ /***************************************************************************************/ // Initialize error message error_message:=""; call_field := this_communication.CallingFieldName; field_list:= this_form.fields; DisplayNewScheduled := first of (field_list.Value where field_list.DataItemName = "LAB_CB_Alternate Priorities"); if (DisplayNewScheduled) then Call_UserFriendly_Lab_Priorities := mlm {{{SINGLE-QUOTE}}}SCH_LAB_PRIORITY_OPTIONS_CALLED{{{SINGLE-QUOTE}}}; (this_communication,this_form) := call Call_UserFriendly_Lab_Priorities with (this_communication,this_form,client_info_obj); endif; //testmlm := mlm {{{SINGLE-QUOTE}}}SCH_LAB_PRIORITY_OPTIONS_CALLED{{{SINGLE-QUOTE}}}; // (this_communication,this_form) := call testmlm with (this_communication,this_form,client_info_obj); //--------THIS SECTION CAN BE COPIED TO OTHER MLM{{{SINGLE-QUOTE}}}S IF YOU NEED TO CALL THE CUSTOM LAB PRIORITIES MLM /* //-----------BEGIN COPY SECTION------------------- DisplayNewScheduled := first of (field_list.Value where field_list.DataItemName = "LAB_CB_Alternate Priorities"); if (DisplayNewScheduled) then Call_UserFriendly_Lab_Priorities := mlm {{{SINGLE-QUOTE}}}SCH_LAB_PRIORITY_OPTIONS_CALLED{{{SINGLE-QUOTE}}}; (this_communication,this_form) := call Call_UserFriendly_Lab_Priorities with (this_communication,this_form,client_info_obj); endif; //-----------END COPY SECTION------------------- //--------THIS SECTION CAN BE COPIED TO OTHER MLM{{{SINGLE-QUOTE}}}S IF YOU NEED TO CALL THE CUSTOM LAB PRIORITIES MLM*/ ;; 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: