ORY109 ; slc/dcm - Patch 109 Post/Pre-init ;06/19/01 16:09 [9/6/01 3:49pm]
;;3.0;ORDER ENTRY/RESULTS REPORTING;**109**;Dec 17, 1997
PRE ; pre-install calls
N VER,ORI
S VER=+$P($T(VERSION^ORY109),";",3)
I $P($G(^ORD(101.24,3,0)),"^",1)="ORRP ANATOMIC PATHOLOGY" D
. S DA=3,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,3,0)="ORRP AP MENU",^ORD(101.24,"B","ORRP AP MENU",3)=""
I $P($G(^ORD(101.24,3,0)),"^",1)="ORRP AP MENU" D
. S DA=3,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,3,0)="ORRP AP MENU",^ORD(101.24,"B","ORRP AP MENU",3)=""
I $P($G(^ORD(101.24,2,0)),"^",1)="ORRP BLOOD BANK" D
. S DA=2,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,2,0)="ORRP BLOOD BANK",^ORD(101.24,"B","ORRP BLOOD BANK",2)=""
I $P($G(^ORD(101.24,6,0)),"^",1)="ORRP IMAGING" D
. S DA=6,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,6,0)="ORRP IMAGING",^ORD(101.24,"B","ORRP IMAGING",6)=""
I $P($G(^ORD(101.24,8,0)),"^",1)="ORRP NUTRITIONAL ASSESS" D
. S DA=8,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,8,0)="ORRP NUTRITIONAL ASSESS",^ORD(101.24,"B","ORRP NUTRITIONAL ASSESS",8)=""
I $P($G(^ORD(101.24,9,0)),"^",1)="ORRP PROCEDURES" D
. S DA=9,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,9,0)="ORRP PROCEDURES",^ORD(101.24,"B","ORRP PROCEDURES",9)=""
I $P($G(^ORD(101.24,12,0)),"^",1)="ORRP CHART COPY SUMMARY" D
. S DA=12,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,12,0)="ORRP CHART COPY SUMMARY",^ORD(101.24,"B","ORRP CHART COPY SUMMARY",12)=""
I $P($G(^ORD(101.24,17,0)),"^",1)="ORRP CUSTOM ORDER SUMMARY" D
. S DA=17,DIK="^ORD(101.24," D ^DIK
. S ^ORD(101.24,17,0)="ORRP CUSTOM ORDER SUMMARY",^ORD(101.24,"B","ORRP CUSTOM ORDER SUMMARY",17)=""
F ORI=1,4,5,7,8,10,11,13,42,43,44 I $D(^ORD(101.24,ORI,2)) S $P(^(2),"^",3,4)="^"
S ORI=999
F S ORI=$O(^ORD(101.24,ORI)) Q:'ORI S DA=ORI,DIK="^ORD(101.24," D ^DIK
Q
POST ; post-install calls
N VER
S VER=$P($T(VERSION^ORY109),";",3)
D SETSURG
D SETVAL
D DORINDV
D MAIL
Q
MAIL ; send bulletin of installation time
N COUNT,DIFROM,I,START,TEXT,XMDUZ,XMSUB,XMTEXT,XMY
S COUNT=0
S XMSUB="Version "_$P($T(VERSION),";;",2)_" Installed"
S XMDUZ="CPRS PACKAGE"
F I="G.CPRS GUI INSTALL@ISC-SLC.DOMAIN.EXT",DUZ S XMY(I)=""
S XMTEXT="TEXT("
;
S X=$P($T(VERSION),";;",2)
D LINE("Version "_X_" has been installed.")
D LINE(" ")
D LINE("Install complete: "_$$FMTE^XLFDT($$NOW^XLFDT()))
;
D ^XMD
Q
LINE(DATA) ; set text into array
S COUNT=COUNT+1
S TEXT(COUNT)=DATA
Q
SENDPAR(ANAME) ; Return true if the current parameter should be sent
I ANAME="ORWRP TIME/OCC LIMITS ALL" Q 1
I ANAME="ORWRP TIME/OCC LIMITS INDV" Q 1
I ANAME="ORCH CONTEXT SURGERY" Q 1
I ANAME="ORWOR SHOW SURGERY TAB" Q 1
I ANAME="ORWCH COLUMNS REPORTS" Q 1
I ANAME="ORWRP ADHOC LOOKUP" Q 1
I ANAME="ORWOR REQUIRE CURRENT CLIENT" Q 1
I $E(ANAME,1,6)="ORWCOM" Q 1
Q 0
;
SETVAL ;Set Package level parameter values
N ORP,ORT,ORI,X0
S ORP="ORWRP TIME/OCC LIMITS ALL",ORT="T-7;T;10"
D PUT^XPAR("PKG",ORP,1,ORT)
S ORP="ORWRP REPORT LIST",ORT=$O(^ORD(101.24,"B","ORRPW REPORT CATEGORIES",0))
I ORT D PUT^XPAR("PKG",ORP,2,ORT)
Q
DORINDV ;Delete ORWRP TIME/OCC LIMITS INDV's Div/Sys/Pkg level setting
D NDEL^XPAR("DIV","ORWRP TIME/OCC LIMITS INDV","")
D NDEL^XPAR("SYS","ORWRP TIME/OCC LIMITS INDV","")
D NDEL^XPAR("PKG","ORWRP TIME/OCC LIMITS INDV","")
Q
SETSURG ; Should surgery tab be displayed?
N TMP,PKG,VAL
S VAL=$$PATCH^XPDUTL("SR*3.0*100")
S PKG=$O(^DIC(9.4,"B","ORDER ENTRY/RESULTS REPORTING",0))
S TMP=$$GET^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1)
I TMP'="" D Q
. D CHG^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1,VAL)
D ADD^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1,VAL)
Q
;
VERSION ;;16.11
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORY109 3766 printed Dec 13, 2024@02:38:17 Page 2
ORY109 ; slc/dcm - Patch 109 Post/Pre-init ;06/19/01 16:09 [9/6/01 3:49pm]
+1 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**109**;Dec 17, 1997
PRE ; pre-install calls
+1 NEW VER,ORI
+2 SET VER=+$PIECE($TEXT(VERSION^ORY109),";",3)
+3 IF $PIECE($GET(^ORD(101.24,3,0)),"^",1)="ORRP ANATOMIC PATHOLOGY"
Begin DoDot:1
+4 SET DA=3
SET DIK="^ORD(101.24,"
DO ^DIK
+5 SET ^ORD(101.24,3,0)="ORRP AP MENU"
SET ^ORD(101.24,"B","ORRP AP MENU",3)=""
End DoDot:1
+6 IF $PIECE($GET(^ORD(101.24,3,0)),"^",1)="ORRP AP MENU"
Begin DoDot:1
+7 SET DA=3
SET DIK="^ORD(101.24,"
DO ^DIK
+8 SET ^ORD(101.24,3,0)="ORRP AP MENU"
SET ^ORD(101.24,"B","ORRP AP MENU",3)=""
End DoDot:1
+9 IF $PIECE($GET(^ORD(101.24,2,0)),"^",1)="ORRP BLOOD BANK"
Begin DoDot:1
+10 SET DA=2
SET DIK="^ORD(101.24,"
DO ^DIK
+11 SET ^ORD(101.24,2,0)="ORRP BLOOD BANK"
SET ^ORD(101.24,"B","ORRP BLOOD BANK",2)=""
End DoDot:1
+12 IF $PIECE($GET(^ORD(101.24,6,0)),"^",1)="ORRP IMAGING"
Begin DoDot:1
+13 SET DA=6
SET DIK="^ORD(101.24,"
DO ^DIK
+14 SET ^ORD(101.24,6,0)="ORRP IMAGING"
SET ^ORD(101.24,"B","ORRP IMAGING",6)=""
End DoDot:1
+15 IF $PIECE($GET(^ORD(101.24,8,0)),"^",1)="ORRP NUTRITIONAL ASSESS"
Begin DoDot:1
+16 SET DA=8
SET DIK="^ORD(101.24,"
DO ^DIK
+17 SET ^ORD(101.24,8,0)="ORRP NUTRITIONAL ASSESS"
SET ^ORD(101.24,"B","ORRP NUTRITIONAL ASSESS",8)=""
End DoDot:1
+18 IF $PIECE($GET(^ORD(101.24,9,0)),"^",1)="ORRP PROCEDURES"
Begin DoDot:1
+19 SET DA=9
SET DIK="^ORD(101.24,"
DO ^DIK
+20 SET ^ORD(101.24,9,0)="ORRP PROCEDURES"
SET ^ORD(101.24,"B","ORRP PROCEDURES",9)=""
End DoDot:1
+21 IF $PIECE($GET(^ORD(101.24,12,0)),"^",1)="ORRP CHART COPY SUMMARY"
Begin DoDot:1
+22 SET DA=12
SET DIK="^ORD(101.24,"
DO ^DIK
+23 SET ^ORD(101.24,12,0)="ORRP CHART COPY SUMMARY"
SET ^ORD(101.24,"B","ORRP CHART COPY SUMMARY",12)=""
End DoDot:1
+24 IF $PIECE($GET(^ORD(101.24,17,0)),"^",1)="ORRP CUSTOM ORDER SUMMARY"
Begin DoDot:1
+25 SET DA=17
SET DIK="^ORD(101.24,"
DO ^DIK
+26 SET ^ORD(101.24,17,0)="ORRP CUSTOM ORDER SUMMARY"
SET ^ORD(101.24,"B","ORRP CUSTOM ORDER SUMMARY",17)=""
End DoDot:1
+27 FOR ORI=1,4,5,7,8,10,11,13,42,43,44
IF $DATA(^ORD(101.24,ORI,2))
SET $PIECE(^(2),"^",3,4)="^"
+28 SET ORI=999
+29 FOR
SET ORI=$ORDER(^ORD(101.24,ORI))
if 'ORI
QUIT
SET DA=ORI
SET DIK="^ORD(101.24,"
DO ^DIK
+30 QUIT
POST ; post-install calls
+1 NEW VER
+2 SET VER=$PIECE($TEXT(VERSION^ORY109),";",3)
+3 DO SETSURG
+4 DO SETVAL
+5 DO DORINDV
+6 DO MAIL
+7 QUIT
MAIL ; send bulletin of installation time
+1 NEW COUNT,DIFROM,I,START,TEXT,XMDUZ,XMSUB,XMTEXT,XMY
+2 SET COUNT=0
+3 SET XMSUB="Version "_$PIECE($TEXT(VERSION),";;",2)_" Installed"
+4 SET XMDUZ="CPRS PACKAGE"
+5 FOR I="G.CPRS GUI INSTALL@ISC-SLC.DOMAIN.EXT",DUZ
SET XMY(I)=""
+6 SET XMTEXT="TEXT("
+7 ;
+8 SET X=$PIECE($TEXT(VERSION),";;",2)
+9 DO LINE("Version "_X_" has been installed.")
+10 DO LINE(" ")
+11 DO LINE("Install complete: "_$$FMTE^XLFDT($$NOW^XLFDT()))
+12 ;
+13 DO ^XMD
+14 QUIT
LINE(DATA) ; set text into array
+1 SET COUNT=COUNT+1
+2 SET TEXT(COUNT)=DATA
+3 QUIT
SENDPAR(ANAME) ; Return true if the current parameter should be sent
+1 IF ANAME="ORWRP TIME/OCC LIMITS ALL"
QUIT 1
+2 IF ANAME="ORWRP TIME/OCC LIMITS INDV"
QUIT 1
+3 IF ANAME="ORCH CONTEXT SURGERY"
QUIT 1
+4 IF ANAME="ORWOR SHOW SURGERY TAB"
QUIT 1
+5 IF ANAME="ORWCH COLUMNS REPORTS"
QUIT 1
+6 IF ANAME="ORWRP ADHOC LOOKUP"
QUIT 1
+7 IF ANAME="ORWOR REQUIRE CURRENT CLIENT"
QUIT 1
+8 IF $EXTRACT(ANAME,1,6)="ORWCOM"
QUIT 1
+9 QUIT 0
+10 ;
SETVAL ;Set Package level parameter values
+1 NEW ORP,ORT,ORI,X0
+2 SET ORP="ORWRP TIME/OCC LIMITS ALL"
SET ORT="T-7;T;10"
+3 DO PUT^XPAR("PKG",ORP,1,ORT)
+4 SET ORP="ORWRP REPORT LIST"
SET ORT=$ORDER(^ORD(101.24,"B","ORRPW REPORT CATEGORIES",0))
+5 IF ORT
DO PUT^XPAR("PKG",ORP,2,ORT)
+6 QUIT
DORINDV ;Delete ORWRP TIME/OCC LIMITS INDV's Div/Sys/Pkg level setting
+1 DO NDEL^XPAR("DIV","ORWRP TIME/OCC LIMITS INDV","")
+2 DO NDEL^XPAR("SYS","ORWRP TIME/OCC LIMITS INDV","")
+3 DO NDEL^XPAR("PKG","ORWRP TIME/OCC LIMITS INDV","")
+4 QUIT
SETSURG ; Should surgery tab be displayed?
+1 NEW TMP,PKG,VAL
+2 SET VAL=$$PATCH^XPDUTL("SR*3.0*100")
+3 SET PKG=$ORDER(^DIC(9.4,"B","ORDER ENTRY/RESULTS REPORTING",0))
+4 SET TMP=$$GET^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1)
+5 IF TMP'=""
Begin DoDot:1
+6 DO CHG^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1,VAL)
End DoDot:1
QUIT
+7 DO ADD^XPAR(PKG_";DIC(9.4,","ORWOR SHOW SURGERY TAB",1,VAL)
+8 QUIT
+9 ;
VERSION ;;16.11