PSO451PI ;BIRM/MFR - PSO*7*451 Post-install routine ;10/26/15
;;7.0;OUTPATIENT PHARMACY;**451**;DEC 1997;Build 114
;
PRE ; Pre-Install Entry Point
; Killing off the old ASAP Definition - New ASAP Definition will be loaded with the Build (Preserving Customizations)
N DIK,DA
S DIK="^PS(58.4," S DA=0 F S DA=$O(^PS(58.4,DA)) Q:'DA D
. I $$GET1^DIQ(58.4,DA,.01)="ASAP RECORD DEFINITION" D ^DIK
. I $$GET1^DIQ(58.4,DA,.01)="STANDARD ASAP DEFINITION" D ^DIK
Q
;
POST ; Post-Install Entry Point
; Enabling all access for all 3 files below
N SECURITY
S SECURITY("RD")=""
S SECURITY("DD")=""
S SECURITY("RD")=""
S SECURITY("WR")=""
S SECURITY("DEL")=""
S SECURITY("LAYGO")=""
S SECURITY("AUDIT")=""
D FILESEC^DDMOD(58.4,.SECURITY)
D FILESEC^DDMOD(58.42,.SECURITY)
;
; Updating the following NEW fields in the SPMP STATE PARAMETERS file (#58.41):
; RENAME FILE AFTER UPLOAD (#17), SFTP SSH KEY FORMAT (#18) & SFTP SSH KEY ENCRYPTION (#19)
N DIE,DA,ENCR,USERNAME,DR
S DIE="^PS(58.41,",DA=0 F S DA=$O(^PS(58.41,DA)) Q:'DA D
. S ENCR="DSA" S:$$DECRYP^XUSRB1($G(^PS(58.41,DA,"PRVKEY",3,0)))["rsa" ENCR="RSA"
. S DR="" I $$GET1^DIQ(58.41,DA,17)="" S DR="17///1;"
. S DR=DR_"18///SSH2;19///"_ENCR
. ; Fix for Appriss Sites that had to tweak the IP ADDRESS and USERNAME parameters to make it work
. I $$UP^XLFSTR($$GET1^DIQ(58.41,DA,7))["PRODPMPSFTP",$$UP^XLFSTR($$GET1^DIQ(58.41,DA,8))["USER=" D
. . S USERNAME=$P($$GET1^DIQ(58.41,DA,8),"=",2)_"@prodpmpsftp"
. . S DR=DR_";7///sftp.pmpclearinghouse.net;8///"_USERNAME
. D ^DIE
;
; Deleting unused field ERRORS (#200) from SPMP EXPORT BATCH file (#58.42)
S DIK="^DD(58.42,",DA=200,DA(1)=58.42 D ^DIK
;
; Change Mail Group PSO SPMP NOTIFICATIONS to PUBLIC
N DIC,X,Y,DA,DIE,DR
S DIC=3.8,X="PSO SPMP NOTIFICATIONS" D ^DIC I '($G(Y)>0) Q
S DIE=3.8,DA=+Y,DR="4///PU" D ^DIE
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HPSO451PI 1897 printed Nov 22, 2024@17:32:56 Page 2
PSO451PI ;BIRM/MFR - PSO*7*451 Post-install routine ;10/26/15
+1 ;;7.0;OUTPATIENT PHARMACY;**451**;DEC 1997;Build 114
+2 ;
PRE ; Pre-Install Entry Point
+1 ; Killing off the old ASAP Definition - New ASAP Definition will be loaded with the Build (Preserving Customizations)
+2 NEW DIK,DA
+3 SET DIK="^PS(58.4,"
SET DA=0
FOR
SET DA=$ORDER(^PS(58.4,DA))
if 'DA
QUIT
Begin DoDot:1
+4 IF $$GET1^DIQ(58.4,DA,.01)="ASAP RECORD DEFINITION"
DO ^DIK
+5 IF $$GET1^DIQ(58.4,DA,.01)="STANDARD ASAP DEFINITION"
DO ^DIK
End DoDot:1
+6 QUIT
+7 ;
POST ; Post-Install Entry Point
+1 ; Enabling all access for all 3 files below
+2 NEW SECURITY
+3 SET SECURITY("RD")=""
+4 SET SECURITY("DD")=""
+5 SET SECURITY("RD")=""
+6 SET SECURITY("WR")=""
+7 SET SECURITY("DEL")=""
+8 SET SECURITY("LAYGO")=""
+9 SET SECURITY("AUDIT")=""
+10 DO FILESEC^DDMOD(58.4,.SECURITY)
+11 DO FILESEC^DDMOD(58.42,.SECURITY)
+12 ;
+13 ; Updating the following NEW fields in the SPMP STATE PARAMETERS file (#58.41):
+14 ; RENAME FILE AFTER UPLOAD (#17), SFTP SSH KEY FORMAT (#18) & SFTP SSH KEY ENCRYPTION (#19)
+15 NEW DIE,DA,ENCR,USERNAME,DR
+16 SET DIE="^PS(58.41,"
SET DA=0
FOR
SET DA=$ORDER(^PS(58.41,DA))
if 'DA
QUIT
Begin DoDot:1
+17 SET ENCR="DSA"
if $$DECRYP^XUSRB1($GET(^PS(58.41,DA,"PRVKEY",3,0)))["rsa"
SET ENCR="RSA"
+18 SET DR=""
IF $$GET1^DIQ(58.41,DA,17)=""
SET DR="17///1;"
+19 SET DR=DR_"18///SSH2;19///"_ENCR
+20 ; Fix for Appriss Sites that had to tweak the IP ADDRESS and USERNAME parameters to make it work
+21 IF $$UP^XLFSTR($$GET1^DIQ(58.41,DA,7))["PRODPMPSFTP"
IF $$UP^XLFSTR($$GET1^DIQ(58.41,DA,8))["USER="
Begin DoDot:2
+22 SET USERNAME=$PIECE($$GET1^DIQ(58.41,DA,8),"=",2)_"@prodpmpsftp"
+23 SET DR=DR_";7///sftp.pmpclearinghouse.net;8///"_USERNAME
End DoDot:2
+24 DO ^DIE
End DoDot:1
+25 ;
+26 ; Deleting unused field ERRORS (#200) from SPMP EXPORT BATCH file (#58.42)
+27 SET DIK="^DD(58.42,"
SET DA=200
SET DA(1)=58.42
DO ^DIK
+28 ;
+29 ; Change Mail Group PSO SPMP NOTIFICATIONS to PUBLIC
+30 NEW DIC,X,Y,DA,DIE,DR
+31 SET DIC=3.8
SET X="PSO SPMP NOTIFICATIONS"
DO ^DIC
IF '($GET(Y)>0)
QUIT
+32 SET DIE=3.8
SET DA=+Y
SET DR="4///PU"
DO ^DIE
+33 QUIT