SDOQMPST ;ALB/SCK - Performance Measure Post-Init ; 7/25/96
;;5.3;SCHEDULING;**47**;AUG 13,1993
;
START ;
I 'XPDQUES("POST001") S XPDABORT=1 Q
;
D BMES^XPDUTL("Beginning Post-Install")
;
I '$$NEWCP^XPDUTL("POST_1","OPT1^SDOQMPST",0) D
. D BMES^XPDUTL("Error creating checkpoint OPT1")
;
I '$$NEWCP^XPDUTL("POST_2","OPT2^SDOQMPST",0) D
. D BMES^XPDUTL("Error creating checkpoint OPT2")
;
I '$$NEWCP^XPDUTL("POST_3","MAIL1^SDOQMPST",0) D
. D BMES^XPDUTL("Error creating checkpoint MAIL1")
;
I '$$NEWCP^XPDUTL("POST_4","NET^SDOQMPST",0) D
. D BMES^XPDUTL("Error creating checkpoint for Domain Name")
QUIT Q
;
OPT1 ;
N SDIEN,SDSIEN,SCERR,MSG,SDFLAG,DIFROM
;
S SDIEN="",SDIEN=$O(^DIC(19,"B","SDOQM PM NIGHTLY JOB",SDIEN))
I SDIEN']"" D Q
. S MSG(1)="Error: the SDOQM PM NIGHTLY JOB option was not loaded during the"
. S MSG(2)="KIDs install. This option will need to be created."
. D MES^XPDUTL(.MSG) K MSG
;
S (SDFLAG,SDSIEN)="",SDSIEN=$O(^DIC(19.2,"B",SDIEN,SDSIEN))
S:SDSIEN']"" SDFLAG="L"
;
I SDSIEN]"",+$P($G(^DIC(19.2,SDSIEN,0)),U,2)>0 S Y=$P(^(0),U,2) D Q
. D DD^%DT
. D BMES^XPDUTL("The SDOQM PM NIGHTLY JOB is already scheduled for "_Y)
;
D RESCH^XUTMOPT("SDOQM PM NIGHTLY JOB","","","1D",SDFLAG)
S SDSIEN="",SDSIEN=$O(^DIC(19.2,"B",SDIEN,SDSIEN))
I SDSIEN']"" D Q
. K MSG
. S MSG(1)="The SDOQM PM NIGHTLY JOB scheduling option was not created."
. S MSG(2)="You will need to create this entry in the OPTION SCHEDULING ile"
. S MSG(3)="manually."
. D MES^XPDUTL(.MSG)
;
Q
;
OPT2 ;
N SDIEN
S SDIEN="",SDIEN=$O(^DIC(19,"B","SDOQM CLINIC NEXT AVAIL REPORT",SDIEN))
I SDIEN']"" D
. D BMES^XPDUTL("Error: the SDOQM CLINIC NEXT AVAIL REPORT option was not loaded")
Q
;
MAIL1 ;
N SDMIEN,DES,MSG,SDMAIL
;
D BMES^XPDUTL("Creating local mail group for PM nightly job...")
;
S SDMAIL="SD PM NOTIFICATION"
S SDMIEN="",SDMIEN=$O(^XMB(3.8,"B",SDMAIL,SDMIEN))
I SDMIEN']"" D Q
. S DES(0)="Mail group for local receipt of Performance Measure access extracts."
. S X=$$MG^XMBGRP(SDMAIL,0,$S(+$G(DUZ)>0:DUZ,1:.5),0,"",.DES,1)
. I 'X D Q
.. D BMES^XPDUTL("There was an error setting up the Mail group.")
. S MSG(0)="The SD PM NOTIFICATION mail group has been created."
. S MSG(1)="After this install is completed, you will need to add"
. S MSG(2)="the appropriate members who need to receive the PM"
. S MSG(3)="confirmation messages from the server."
. D MES^XPDUTL(.MSG)
;
I SDMIEN]"" D
. D BMES^XPDUTL("Mail group already exists, please make sure appropriate members are added.")
;
Q
NET ;
N MSG
;
I '$D(^XMB("NETNAME")) D Q
. S MSG(0)="The Domain Name for this server is not defined. You will not"
. S MSG(1)="be able to receive the PM confirmation messages from the data collection server."
. S MSG(2)="Please contact your IRM staff for assistance."
. D MES^XPDUTL(.MSG)
;
D BMES^XPDUTL("Domain Name OK")
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HSDOQMPST 2973 printed Nov 22, 2024@18:09:12 Page 2
SDOQMPST ;ALB/SCK - Performance Measure Post-Init ; 7/25/96
+1 ;;5.3;SCHEDULING;**47**;AUG 13,1993
+2 ;
START ;
+1 IF 'XPDQUES("POST001")
SET XPDABORT=1
QUIT
+2 ;
+3 DO BMES^XPDUTL("Beginning Post-Install")
+4 ;
+5 IF '$$NEWCP^XPDUTL("POST_1","OPT1^SDOQMPST",0)
Begin DoDot:1
+6 DO BMES^XPDUTL("Error creating checkpoint OPT1")
End DoDot:1
+7 ;
+8 IF '$$NEWCP^XPDUTL("POST_2","OPT2^SDOQMPST",0)
Begin DoDot:1
+9 DO BMES^XPDUTL("Error creating checkpoint OPT2")
End DoDot:1
+10 ;
+11 IF '$$NEWCP^XPDUTL("POST_3","MAIL1^SDOQMPST",0)
Begin DoDot:1
+12 DO BMES^XPDUTL("Error creating checkpoint MAIL1")
End DoDot:1
+13 ;
+14 IF '$$NEWCP^XPDUTL("POST_4","NET^SDOQMPST",0)
Begin DoDot:1
+15 DO BMES^XPDUTL("Error creating checkpoint for Domain Name")
End DoDot:1
QUIT QUIT
+1 ;
OPT1 ;
+1 NEW SDIEN,SDSIEN,SCERR,MSG,SDFLAG,DIFROM
+2 ;
+3 SET SDIEN=""
SET SDIEN=$ORDER(^DIC(19,"B","SDOQM PM NIGHTLY JOB",SDIEN))
+4 IF SDIEN']""
Begin DoDot:1
+5 SET MSG(1)="Error: the SDOQM PM NIGHTLY JOB option was not loaded during the"
+6 SET MSG(2)="KIDs install. This option will need to be created."
+7 DO MES^XPDUTL(.MSG)
KILL MSG
End DoDot:1
QUIT
+8 ;
+9 SET (SDFLAG,SDSIEN)=""
SET SDSIEN=$ORDER(^DIC(19.2,"B",SDIEN,SDSIEN))
+10 if SDSIEN']""
SET SDFLAG="L"
+11 ;
+12 IF SDSIEN]""
IF +$PIECE($GET(^DIC(19.2,SDSIEN,0)),U,2)>0
SET Y=$PIECE(^(0),U,2)
Begin DoDot:1
+13 DO DD^%DT
+14 DO BMES^XPDUTL("The SDOQM PM NIGHTLY JOB is already scheduled for "_Y)
End DoDot:1
QUIT
+15 ;
+16 DO RESCH^XUTMOPT("SDOQM PM NIGHTLY JOB","","","1D",SDFLAG)
+17 SET SDSIEN=""
SET SDSIEN=$ORDER(^DIC(19.2,"B",SDIEN,SDSIEN))
+18 IF SDSIEN']""
Begin DoDot:1
+19 KILL MSG
+20 SET MSG(1)="The SDOQM PM NIGHTLY JOB scheduling option was not created."
+21 SET MSG(2)="You will need to create this entry in the OPTION SCHEDULING ile"
+22 SET MSG(3)="manually."
+23 DO MES^XPDUTL(.MSG)
End DoDot:1
QUIT
+24 ;
+25 QUIT
+26 ;
OPT2 ;
+1 NEW SDIEN
+2 SET SDIEN=""
SET SDIEN=$ORDER(^DIC(19,"B","SDOQM CLINIC NEXT AVAIL REPORT",SDIEN))
+3 IF SDIEN']""
Begin DoDot:1
+4 DO BMES^XPDUTL("Error: the SDOQM CLINIC NEXT AVAIL REPORT option was not loaded")
End DoDot:1
+5 QUIT
+6 ;
MAIL1 ;
+1 NEW SDMIEN,DES,MSG,SDMAIL
+2 ;
+3 DO BMES^XPDUTL("Creating local mail group for PM nightly job...")
+4 ;
+5 SET SDMAIL="SD PM NOTIFICATION"
+6 SET SDMIEN=""
SET SDMIEN=$ORDER(^XMB(3.8,"B",SDMAIL,SDMIEN))
+7 IF SDMIEN']""
Begin DoDot:1
+8 SET DES(0)="Mail group for local receipt of Performance Measure access extracts."
+9 SET X=$$MG^XMBGRP(SDMAIL,0,$SELECT(+$GET(DUZ)>0:DUZ,1:.5),0,"",.DES,1)
+10 IF 'X
Begin DoDot:2
+11 DO BMES^XPDUTL("There was an error setting up the Mail group.")
End DoDot:2
QUIT
+12 SET MSG(0)="The SD PM NOTIFICATION mail group has been created."
+13 SET MSG(1)="After this install is completed, you will need to add"
+14 SET MSG(2)="the appropriate members who need to receive the PM"
+15 SET MSG(3)="confirmation messages from the server."
+16 DO MES^XPDUTL(.MSG)
End DoDot:1
QUIT
+17 ;
+18 IF SDMIEN]""
Begin DoDot:1
+19 DO BMES^XPDUTL("Mail group already exists, please make sure appropriate members are added.")
End DoDot:1
+20 ;
+21 QUIT
NET ;
+1 NEW MSG
+2 ;
+3 IF '$DATA(^XMB("NETNAME"))
Begin DoDot:1
+4 SET MSG(0)="The Domain Name for this server is not defined. You will not"
+5 SET MSG(1)="be able to receive the PM confirmation messages from the data collection server."
+6 SET MSG(2)="Please contact your IRM staff for assistance."
+7 DO MES^XPDUTL(.MSG)
End DoDot:1
QUIT
+8 ;
+9 DO BMES^XPDUTL("Domain Name OK")
+10 QUIT