IBY721PO ;YMG/EDE - IB*2.0*721 POST INSTALL;JUN 23 2023
;;2.0;Integrated Billing;**721**;21-MAR-94;Build 5
;Per VA Directive 6402, this routine should not be modified.
;
Q
;
EN ; entry point
D BMES^XPDUTL(" >> Starting the Post-Initialization routine for IB*2.0*721")
D NEWATYPE
D BMES^XPDUTL(" >> End of the Post-Initialization routine for IB*2.0*721")
Q
;
NEWATYPE ; add new IB action types to file 350.1
N FDA,FDAIEN,IBATYPE,IBCHRG,IBIEN,IBNAME,IBSRV,IENS,Z
D MES^XPDUTL(" -> Adding new IB action types to file 350.1...")
S IBCHRG=$$FIND1^DIC(430.2,,"X","CC OPT","B")
S IBSRV=$$GET1^DIQ(350.9,1,1.14,"I")
F IBNAME="CC MH (OPT) NEW","CC MH (OPT) UPDATE","CC MH (OPT) CANCEL" D
.D MES^XPDUTL(" Adding "_IBNAME_"...")
.S IBATYPE=+$$FIND1^DIC(350.1,,"X",IBNAME,"B"),IENS=$S(IBATYPE>0:IBATYPE_",",1:"+1,")
.S FDA(350.1,IENS,.01)=IBNAME ; name
.S FDA(350.1,IENS,.02)=$S(IBNAME["UPDATE":"UPD CCMH",IBNAME["CANCEL":"CAN CCMH",1:"N CCMH") ; abbreviation
.S FDA(350.1,IENS,.03)=IBCHRG ; charge category
.S FDA(350.1,IENS,.04)=IBSRV ; service
.S FDA(350.1,IENS,.05)=$S(IBNAME["UPDATE":3,IBNAME["CANCEL":2,1:1) ; sequence #
.I IBNAME["NEW" D
..S FDA(350.1,IENS,.08)="CC MH OPT" ; user lookup name
..S FDA(350.1,IENS,.1)=1 ; place on hold
..S FDA(350.1,IENS,.11)=4 ; billing group
..S FDA(350.1,IENS,20)="S IBDESC=""CC MH OPT COPAY"""
..Q
.S FDA(350.1,IENS,.12)=0 ; inactive?
.I 'IBATYPE D
..D UPDATE^DIE("","FDA","FDAIEN")
..I +$G(FDAIEN(1))>0 S IBIEN($S(IBNAME["UPDATE":"U",IBNAME["CANCEL":"C",1:"N"))=FDAIEN(1)
..K FDAIEN
..Q
.I IBATYPE D
..D FILE^DIE("","FDA")
..S IBIEN($S(IBNAME["UPDATE":"U",IBNAME["CANCEL":"C",1:"N"))=IBATYPE
..Q
.K FDA
.D MES^XPDUTL(" Ok.")
.Q
F Z="U","C","N" D
.S IENS=IBIEN(Z)_","
.S FDA(350.1,IENS,.06)=IBIEN("C") ; cancellation action type
.S FDA(350.1,IENS,.07)=IBIEN("U") ; update action type
.S FDA(350.1,IENS,.09)=IBIEN("N") ; new action type
.D FILE^DIE("","FDA")
.K FDA
.Q
D MES^XPDUTL(" Done.")
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HIBY721PO 2066 printed Dec 13, 2024@02:35:12 Page 2
IBY721PO ;YMG/EDE - IB*2.0*721 POST INSTALL;JUN 23 2023
+1 ;;2.0;Integrated Billing;**721**;21-MAR-94;Build 5
+2 ;Per VA Directive 6402, this routine should not be modified.
+3 ;
+4 QUIT
+5 ;
EN ; entry point
+1 DO BMES^XPDUTL(" >> Starting the Post-Initialization routine for IB*2.0*721")
+2 DO NEWATYPE
+3 DO BMES^XPDUTL(" >> End of the Post-Initialization routine for IB*2.0*721")
+4 QUIT
+5 ;
NEWATYPE ; add new IB action types to file 350.1
+1 NEW FDA,FDAIEN,IBATYPE,IBCHRG,IBIEN,IBNAME,IBSRV,IENS,Z
+2 DO MES^XPDUTL(" -> Adding new IB action types to file 350.1...")
+3 SET IBCHRG=$$FIND1^DIC(430.2,,"X","CC OPT","B")
+4 SET IBSRV=$$GET1^DIQ(350.9,1,1.14,"I")
+5 FOR IBNAME="CC MH (OPT) NEW","CC MH (OPT) UPDATE","CC MH (OPT) CANCEL"
Begin DoDot:1
+6 DO MES^XPDUTL(" Adding "_IBNAME_"...")
+7 SET IBATYPE=+$$FIND1^DIC(350.1,,"X",IBNAME,"B")
SET IENS=$SELECT(IBATYPE>0:IBATYPE_",",1:"+1,")
+8 ; name
SET FDA(350.1,IENS,.01)=IBNAME
+9 ; abbreviation
SET FDA(350.1,IENS,.02)=$SELECT(IBNAME["UPDATE":"UPD CCMH",IBNAME["CANCEL":"CAN CCMH",1:"N CCMH")
+10 ; charge category
SET FDA(350.1,IENS,.03)=IBCHRG
+11 ; service
SET FDA(350.1,IENS,.04)=IBSRV
+12 ; sequence #
SET FDA(350.1,IENS,.05)=$SELECT(IBNAME["UPDATE":3,IBNAME["CANCEL":2,1:1)
+13 IF IBNAME["NEW"
Begin DoDot:2
+14 ; user lookup name
SET FDA(350.1,IENS,.08)="CC MH OPT"
+15 ; place on hold
SET FDA(350.1,IENS,.1)=1
+16 ; billing group
SET FDA(350.1,IENS,.11)=4
+17 SET FDA(350.1,IENS,20)="S IBDESC=""CC MH OPT COPAY"""
+18 QUIT
End DoDot:2
+19 ; inactive?
SET FDA(350.1,IENS,.12)=0
+20 IF 'IBATYPE
Begin DoDot:2
+21 DO UPDATE^DIE("","FDA","FDAIEN")
+22 IF +$GET(FDAIEN(1))>0
SET IBIEN($SELECT(IBNAME["UPDATE":"U",IBNAME["CANCEL":"C",1:"N"))=FDAIEN(1)
+23 KILL FDAIEN
+24 QUIT
End DoDot:2
+25 IF IBATYPE
Begin DoDot:2
+26 DO FILE^DIE("","FDA")
+27 SET IBIEN($SELECT(IBNAME["UPDATE":"U",IBNAME["CANCEL":"C",1:"N"))=IBATYPE
+28 QUIT
End DoDot:2
+29 KILL FDA
+30 DO MES^XPDUTL(" Ok.")
+31 QUIT
End DoDot:1
+32 FOR Z="U","C","N"
Begin DoDot:1
+33 SET IENS=IBIEN(Z)_","
+34 ; cancellation action type
SET FDA(350.1,IENS,.06)=IBIEN("C")
+35 ; update action type
SET FDA(350.1,IENS,.07)=IBIEN("U")
+36 ; new action type
SET FDA(350.1,IENS,.09)=IBIEN("N")
+37 DO FILE^DIE("","FDA")
+38 KILL FDA
+39 QUIT
End DoDot:1
+40 DO MES^XPDUTL(" Done.")
+41 QUIT