From 32df3e681607ceaf7b405a0f02c6e94fa95620aa Mon Sep 17 00:00:00 2001 From: "Infineon\\StieberD" Date: Wed, 9 Apr 2025 16:31:54 -0700 Subject: [PATCH] updated react servs form to fill available intrusive maintenance flows based on data instead of a form list --- LSL2/OIWIN/REACT_SERVS.json | 14 +------------- LSL2/STPROC/COMM_REACT_SERVS.txt | 12 +++++++----- LSL2/STPROC/NICA_ORDERS_SERVICES.txt | 22 ++++++++++++++++++++++ 3 files changed, 30 insertions(+), 18 deletions(-) diff --git a/LSL2/OIWIN/REACT_SERVS.json b/LSL2/OIWIN/REACT_SERVS.json index 12d9b8d..c17f901 100644 --- a/LSL2/OIWIN/REACT_SERVS.json +++ b/LSL2/OIWIN/REACT_SERVS.json @@ -1053,19 +1053,7 @@ "<4,32>": "", "<4,33>": "", "<4,34>": "", - "<4,35>": { - "<4,35,1>": "", - "<4,35,2>": "A", - "<4,35,3>": "B", - "<4,35,4>": "C", - "<4,35,5>": "D", - "<4,35,6>": "E", - "<4,35,7>": "F", - "<4,35,8>": "G", - "<4,35,9>": "H", - "<4,35,10>": "I", - "<4,35,11>": "J" - }, + "<4,35>": "", "<4,36>": "", "<4,37>": "", "<4,38>": "", diff --git a/LSL2/STPROC/COMM_REACT_SERVS.txt b/LSL2/STPROC/COMM_REACT_SERVS.txt index 71bb965..750f73b 100644 --- a/LSL2/STPROC/COMM_REACT_SERVS.txt +++ b/LSL2/STPROC/COMM_REACT_SERVS.txt @@ -13,6 +13,7 @@ DECLARE SUBROUTINE React_Servs_Services, React_Servs_Events DECLARE FUNCTION Get_Property, Get_Status, Dialog_Box, Utility, Center_Window, Popup, Collect.Ixvals DECLARE FUNCTION Send_Message, Msg, Security_Check, RowExists, NextKey, End_Window, React_Servs_Services +DECLARE FUNCTION Nica_Orders_Services $INSERT MSG_EQUATES $INSERT APPCOLORS @@ -64,7 +65,7 @@ RETURN Result * * * * * * * Create: * * * * * * * - + IF NOT(Security_Check('React Servs',Read$)) THEN Security_Err_Msg('React Servs',Read$) void = End_Window( @WINDOW, '' ) @@ -80,6 +81,11 @@ Create: obj_Appwindow('Create',@WINDOW) + AvailFlowIds = Nica_Orders_Services('GetAvailableFlowIds', 'INTRUSIVE_MAINT') + Convert @VM to @FM in AvailFlowIds + AvailFlowIds = '':@FM:AvailFlowIds + Set_Property(@Window:'.CBO_INTR_MAINT_FLOW', 'LIST', AvailFlowIds) + GOSUB Refresh RETURN @@ -96,9 +102,6 @@ Clear: Set_Property(@WINDOW,'@READONLY',0) ;* Clear flag on window END -* GOSUB EnableFlowCode -* React_Servs_Events(@Window, 'READ') - * * * * * * * Refresh: @@ -141,7 +144,6 @@ Refresh: NEXT I GOSUB EnableFlowCode -* React_Servs_Events(@Window, 'READ') RETURN diff --git a/LSL2/STPROC/NICA_ORDERS_SERVICES.txt b/LSL2/STPROC/NICA_ORDERS_SERVICES.txt index 5255c25..4c292c4 100644 --- a/LSL2/STPROC/NICA_ORDERS_SERVICES.txt +++ b/LSL2/STPROC/NICA_ORDERS_SERVICES.txt @@ -879,7 +879,29 @@ Service GetFlowChecklistIds(NicaOrderFlowIds, NicaOrderFlowType=ORDER_TYPES, Rea end service + +Service GetAvailableFlowIds(NicaOrderType=ORDER_TYPES) + + If NicaOrderType NE '' then + ChecklistIds = '' + Extract_SI_Keys('NICA_CHECKLISTS', 'NICA_ORDER_FLOW_TYPE', NicaOrderType, ChecklistIds) + If ChecklistIds NE '' then + FlowIds = Xlate('NICA_CHECKLISTS', ChecklistIds, 'NICA_ORDER_FLOW_IDS', 'X') + If FlowIds NE '' then + FlowIds = SRP_Array('Clean', FlowIds, 'TrimAndMakeUnique', @VM) + FlowIds = SRP_Array('SortSimpleList', FlowIds, 'AscendingText', @VM) + Response = FlowIds + end + end + end else + ErrorMsg = 'Error in ':Service:' service. Null NicaOrderType passed in.' + Error_Services('Add', ErrorMsg) + end + +end service + //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Internal GoSubs //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +