PSO441PI ;SLC/TDP - Post-intall for PSO*7*441 ;Dec 09, 2021@13:46
;;7.0;OUTPATIENT PHARMACY;**441**;DEC 1997;Build 208
;
Q
;
POST ; Entry Point for post-install
D MES^XPDUTL(" Starting post-install of PSO*7*441")
N PSORDHM,PSOHA1,XQORM,I
; Remove ^XUTL entry for hidden action menu protocols
; Get the IEN for the PSO HIDDEN ACTIONS
S PSOHA1=$O(^ORD(101,"B","PSO HIDDEN ACTIONS",0))
;
F I=PSOHA1 S XQORM=I_";ORD(101," I $D(^XUTL("XQORM",XQORM)) D
. D BMES^XPDUTL(" Removing cached hidden menu for "_$P(^ORD(101,I,0),U,1))
. K ^XUTL("XQORM",XQORM)
;
D DELDD,SETPKOFF,ENPROT
;
D BMES^XPDUTL(" Finished post-install of PSO*7*441")
Q
;
DELDD ;DELETE FIELD #2009 FROM FILE #59 IN DATA DICTIONARY
I '$D(^DD(59,2009)) Q ;no need to run again
D BMES^XPDUTL(" Deleting Park Function (#2009) field from the Outpatient Site (#59) file")
D MES^XPDUTL(" in Data Dictionary.")
N PSOX
S PSOX=0 F S PSOX=$O(^PS(59,PSOX)) Q:'PSOX I $P($G(^PS(59,PSOX,1)),"^",34)]"" S DR="2009////@",DIE="^PS(59,",DA=PSOX D ^DIE
K DIE,DR
S DIK="^DD(59,",DA=2009,DA(1)=59
D ^DIK
D BMES^XPDUTL(" Deletion from Data Dictionary complete.")
K DA,DIK,DIE,DR
Q
;
SETPKOFF ;Set Default PSO PARK ON parameter to NO
N PSOERR
;S PARAM=$$GET^XPAR("PKG","PSO PARK ON",,"I")
;I PARAM=0 Q
D EN^XPAR("PKG","PSO PARK ON",,"NO",.PSOERR)
I PSOERR=0 D BMES^XPDUTL(" PSO PARK ON parameter set to ""NO"" at the Package level.")
I PSOERR'=0 D
. D BMES^XPDUTL(" Error setting PSO PARK ON parameter to ""NO"" at the Package level.")
. D MES^XPDUTL(" Error: "_$P(PSOERR,U,2))
Q
;
ENPROT ;Enable protocol PSO LM PAT PREG/LACT DISPLAY
D OUT^XPDPROT("PSO LM PAT PREG/LACT DISPLAY","@")
D BMES^XPDUTL(" Enabled the PSO LM PAT PREG/LACT DISPLAY protocol.")
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HPSO441PI 1819 printed Dec 13, 2024@02:22:55 Page 2
PSO441PI ;SLC/TDP - Post-intall for PSO*7*441 ;Dec 09, 2021@13:46
+1 ;;7.0;OUTPATIENT PHARMACY;**441**;DEC 1997;Build 208
+2 ;
+3 QUIT
+4 ;
POST ; Entry Point for post-install
+1 DO MES^XPDUTL(" Starting post-install of PSO*7*441")
+2 NEW PSORDHM,PSOHA1,XQORM,I
+3 ; Remove ^XUTL entry for hidden action menu protocols
+4 ; Get the IEN for the PSO HIDDEN ACTIONS
+5 SET PSOHA1=$ORDER(^ORD(101,"B","PSO HIDDEN ACTIONS",0))
+6 ;
+7 FOR I=PSOHA1
SET XQORM=I_";ORD(101,"
IF $DATA(^XUTL("XQORM",XQORM))
Begin DoDot:1
+8 DO BMES^XPDUTL(" Removing cached hidden menu for "_$PIECE(^ORD(101,I,0),U,1))
+9 KILL ^XUTL("XQORM",XQORM)
End DoDot:1
+10 ;
+11 DO DELDD
DO SETPKOFF
DO ENPROT
+12 ;
+13 DO BMES^XPDUTL(" Finished post-install of PSO*7*441")
+14 QUIT
+15 ;
DELDD ;DELETE FIELD #2009 FROM FILE #59 IN DATA DICTIONARY
+1 ;no need to run again
IF '$DATA(^DD(59,2009))
QUIT
+2 DO BMES^XPDUTL(" Deleting Park Function (#2009) field from the Outpatient Site (#59) file")
+3 DO MES^XPDUTL(" in Data Dictionary.")
+4 NEW PSOX
+5 SET PSOX=0
FOR
SET PSOX=$ORDER(^PS(59,PSOX))
if 'PSOX
QUIT
IF $PIECE($GET(^PS(59,PSOX,1)),"^",34)]""
SET DR="2009////@"
SET DIE="^PS(59,"
SET DA=PSOX
DO ^DIE
+6 KILL DIE,DR
+7 SET DIK="^DD(59,"
SET DA=2009
SET DA(1)=59
+8 DO ^DIK
+9 DO BMES^XPDUTL(" Deletion from Data Dictionary complete.")
+10 KILL DA,DIK,DIE,DR
+11 QUIT
+12 ;
SETPKOFF ;Set Default PSO PARK ON parameter to NO
+1 NEW PSOERR
+2 ;S PARAM=$$GET^XPAR("PKG","PSO PARK ON",,"I")
+3 ;I PARAM=0 Q
+4 DO EN^XPAR("PKG","PSO PARK ON",,"NO",.PSOERR)
+5 IF PSOERR=0
DO BMES^XPDUTL(" PSO PARK ON parameter set to ""NO"" at the Package level.")
+6 IF PSOERR'=0
Begin DoDot:1
+7 DO BMES^XPDUTL(" Error setting PSO PARK ON parameter to ""NO"" at the Package level.")
+8 DO MES^XPDUTL(" Error: "_$PIECE(PSOERR,U,2))
End DoDot:1
+9 QUIT
+10 ;
ENPROT ;Enable protocol PSO LM PAT PREG/LACT DISPLAY
+1 DO OUT^XPDPROT("PSO LM PAT PREG/LACT DISPLAY","@")
+2 DO BMES^XPDUTL(" Enabled the PSO LM PAT PREG/LACT DISPLAY protocol.")
+3 QUIT