PSO707P ;ORLFO/FJF/WC - post install ; Mar 20, 2023@12:57:56
 ;;7.0;OUTPATIENT PHARMACY;**707**;DEC 1997;Build 18
 ;
 ; External calls:
 ;
 ; Description       ICR     Notes
 ; -----------       ------  -------
 ; Reference to NEW PERSON (#200) file (reads) in #10060
 ; Reference to OPTION (#19) file (reads) in #2246
 ; Reference to FIND1^DIC in #2051
 ; Reference to CREATE^XUSAP in #4677
 ; Reference to UPDATE^DIE in #2053
 ; Reference to BMES^XPDUTL in #10141
 ;
 ; Post Install routine for patch PSO*7.0*707
 ;
POST ; Update Proxy user with CRMS secondary menu option context
 ;
 N FDA,ERR,OIEN,IEN,PSOA
 S PSOA=$$CREATE^XUSAP("PSOVCC,APPLICATION PROXY","","PSO WEB CHART")
 ; USER found:
 I +PSOA'<0 D
 . S IEN=$$FIND1^DIC(200,,"M","PSOVCC,APPLICATION PROXY")
 . S OIEN=$$FIND1^DIC(19,,"M","PSO WEB CHART")
 . I $D(^VA(200,IEN,203,"B",OIEN)) Q  ; check for existence, Quit if found
 . S FDA(200.03,"+1,"_IEN_",",.01)=OIEN  ; add if needed
 . D UPDATE^DIE("","FDA",,"ERR")
 . I '$D(ERR) D BMES^XPDUTL("Proxy user updated successfully.") Q
 . I $D(ERR) D
 . . D BMES^XPDUTL("***********************")
 . . D BMES^XPDUTL("Proxy user not updated.")
 . . D BMES^XPDUTL("***********************")
 ; User not found:
 I +PSOA<0 D
 . D BMES^XPDUTL("*************************************")
 . D BMES^XPDUTL("APPLICATION PROXY USER not created.")
 . D BMES^XPDUTL("Please contact the Service Desk.")
 . D BMES^XPDUTL("*************************************")
 Q
 
--- Routine Detail   --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HPSO707P   1498     printed  Sep 23, 2025@19:59:41                                                                                                                                                                                                     Page 2
PSO707P   ;ORLFO/FJF/WC - post install ; Mar 20, 2023@12:57:56
 +1       ;;7.0;OUTPATIENT PHARMACY;**707**;DEC 1997;Build 18
 +2       ;
 +3       ; External calls:
 +4       ;
 +5       ; Description       ICR     Notes
 +6       ; -----------       ------  -------
 +7       ; Reference to NEW PERSON (#200) file (reads) in #10060
 +8       ; Reference to OPTION (#19) file (reads) in #2246
 +9       ; Reference to FIND1^DIC in #2051
 +10      ; Reference to CREATE^XUSAP in #4677
 +11      ; Reference to UPDATE^DIE in #2053
 +12      ; Reference to BMES^XPDUTL in #10141
 +13      ;
 +14      ; Post Install routine for patch PSO*7.0*707
 +15      ;
POST      ; Update Proxy user with CRMS secondary menu option context
 +1       ;
 +2        NEW FDA,ERR,OIEN,IEN,PSOA
 +3        SET PSOA=$$CREATE^XUSAP("PSOVCC,APPLICATION PROXY","","PSO WEB CHART")
 +4       ; USER found:
 +5        IF +PSOA'<0
               Begin DoDot:1
 +6                SET IEN=$$FIND1^DIC(200,,"M","PSOVCC,APPLICATION PROXY")
 +7                SET OIEN=$$FIND1^DIC(19,,"M","PSO WEB CHART")
 +8       ; check for existence, Quit if found
                   IF $DATA(^VA(200,IEN,203,"B",OIEN))
                       QUIT 
 +9       ; add if needed
                   SET FDA(200.03,"+1,"_IEN_",",.01)=OIEN
 +10               DO UPDATE^DIE("","FDA",,"ERR")
 +11               IF '$DATA(ERR)
                       DO BMES^XPDUTL("Proxy user updated successfully.")
                       QUIT 
 +12               IF $DATA(ERR)
                       Begin DoDot:2
 +13                       DO BMES^XPDUTL("***********************")
 +14                       DO BMES^XPDUTL("Proxy user not updated.")
 +15                       DO BMES^XPDUTL("***********************")
                       End DoDot:2
               End DoDot:1
 +16      ; User not found:
 +17       IF +PSOA<0
               Begin DoDot:1
 +18               DO BMES^XPDUTL("*************************************")
 +19               DO BMES^XPDUTL("APPLICATION PROXY USER not created.")
 +20               DO BMES^XPDUTL("Please contact the Service Desk.")
 +21               DO BMES^XPDUTL("*************************************")
               End DoDot:1
 +22       QUIT