IB20P671 ;/Albany - IB*2.0*671 POST INSTALL;02/04/20 2:10pm
;;2.0;Integrated Billing;**671**;Mar 20, 1995;Build 13
;Per VA Directive 6402, this routine should not be modified.
Q
;
POSTINIT ;Post Install for IB*2.0*671
D BMES^XPDUTL(" >> Starting the Post-Initialization routine for IB*2.0*671")
D TSKPUSH ; add the nightly task
D TPFUS ; fix Third Party Follow-up summary report
D BMES^XPDUTL(" >> End of the Post-Initialization routine for IB*2.0*671")
Q
;
TSKPUSH ; task the routine as a Night Job using TaskMan.
;
N DIC,DLAYGO,TSTAMP,X,Y
D MES^XPDUTL("Tasking Nightly Copay Synch ... ")
;
I $$FIND1^DIC(19.2,,"B","IBUC MULTI FAC COPAY SYNCH","B") D MES^XPDUTL(" Already scheduled") Q ; don't overwrite existing schedule
S (DLAYGO,DIC)=19.2,DIC(0)="L"
S X="IBUC MULTI FAC COPAY SYNCH"
S TSTAMP=$$FMADD^XLFDT($$NOW^XLFDT(),1),$P(TSTAMP,".",2)="0200"
S DIC("DR")="2////"_TSTAMP_";6////D@2AM"
D ^DIC
Q
; Update the IBSEL parameter
TPFUS ; fix value of input variable for 3rd Party Follow-Up Summary
; ibsel = 5 is for all types
N IBDA,IBDM,IBSEL,IBNM,IBIVA,DA,DIE,DR,X,Y
S IBSEL="5,"
S IBDM="IB DM EXTRACT REPORTS"
S IBNM="THIRD PARTY FOLLOW-UP SUMMARY"
S IBDA=$O(^IBE(351.7,"B",IBNM,0))
I 'IBDA D MES^XPDUTL(" >>> "_IBNM_" of "_IBDM_" not found") Q
S IBIVA=$O(^IBE(351.7,IBDA,1,"B","IBSEL",0))
I 'IBIVA D MES^XPDUTL(" >>> Input variable IBSEL of "_IBNM_" not found") Q
I $P($G(^IBE(351.7,IBDA,1,IBIVA,0)),U,2)=IBSEL D Q
. D MES^XPDUTL(" >>> Value of input variable IBSEL of "_IBNM_" already")
. D MES^XPDUTL(" updated in the "_IBDM_" file (#351.7)")
S DA(1)=IBDA,DA=IBIVA
S DIE="^IBE(351.7,"_DA(1)_",1,",DR=".02////"_IBSEL D ^DIE
D MES^XPDUTL(" >>> Updating value of input variable IBSEL of "_IBNM)
D MES^XPDUTL(" in the "_IBDM_" file (#351.7)")
Q
;
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HIB20P671 1858 printed Dec 13, 2024@02:04:26 Page 2
IB20P671 ;/Albany - IB*2.0*671 POST INSTALL;02/04/20 2:10pm
+1 ;;2.0;Integrated Billing;**671**;Mar 20, 1995;Build 13
+2 ;Per VA Directive 6402, this routine should not be modified.
+3 QUIT
+4 ;
POSTINIT ;Post Install for IB*2.0*671
+1 DO BMES^XPDUTL(" >> Starting the Post-Initialization routine for IB*2.0*671")
+2 ; add the nightly task
DO TSKPUSH
+3 ; fix Third Party Follow-up summary report
DO TPFUS
+4 DO BMES^XPDUTL(" >> End of the Post-Initialization routine for IB*2.0*671")
+5 QUIT
+6 ;
TSKPUSH ; task the routine as a Night Job using TaskMan.
+1 ;
+2 NEW DIC,DLAYGO,TSTAMP,X,Y
+3 DO MES^XPDUTL("Tasking Nightly Copay Synch ... ")
+4 ;
+5 ; don't overwrite existing schedule
IF $$FIND1^DIC(19.2,,"B","IBUC MULTI FAC COPAY SYNCH","B")
DO MES^XPDUTL(" Already scheduled")
QUIT
+6 SET (DLAYGO,DIC)=19.2
SET DIC(0)="L"
+7 SET X="IBUC MULTI FAC COPAY SYNCH"
+8 SET TSTAMP=$$FMADD^XLFDT($$NOW^XLFDT(),1)
SET $PIECE(TSTAMP,".",2)="0200"
+9 SET DIC("DR")="2////"_TSTAMP_";6////D@2AM"
+10 DO ^DIC
+11 QUIT
+12 ; Update the IBSEL parameter
TPFUS ; fix value of input variable for 3rd Party Follow-Up Summary
+1 ; ibsel = 5 is for all types
+2 NEW IBDA,IBDM,IBSEL,IBNM,IBIVA,DA,DIE,DR,X,Y
+3 SET IBSEL="5,"
+4 SET IBDM="IB DM EXTRACT REPORTS"
+5 SET IBNM="THIRD PARTY FOLLOW-UP SUMMARY"
+6 SET IBDA=$ORDER(^IBE(351.7,"B",IBNM,0))
+7 IF 'IBDA
DO MES^XPDUTL(" >>> "_IBNM_" of "_IBDM_" not found")
QUIT
+8 SET IBIVA=$ORDER(^IBE(351.7,IBDA,1,"B","IBSEL",0))
+9 IF 'IBIVA
DO MES^XPDUTL(" >>> Input variable IBSEL of "_IBNM_" not found")
QUIT
+10 IF $PIECE($GET(^IBE(351.7,IBDA,1,IBIVA,0)),U,2)=IBSEL
Begin DoDot:1
+11 DO MES^XPDUTL(" >>> Value of input variable IBSEL of "_IBNM_" already")
+12 DO MES^XPDUTL(" updated in the "_IBDM_" file (#351.7)")
End DoDot:1
QUIT
+13 SET DA(1)=IBDA
SET DA=IBIVA
+14 SET DIE="^IBE(351.7,"_DA(1)_",1,"
SET DR=".02////"_IBSEL
DO ^DIE
+15 DO MES^XPDUTL(" >>> Updating value of input variable IBSEL of "_IBNM)
+16 DO MES^XPDUTL(" in the "_IBDM_" file (#351.7)")
+17 QUIT
+18 ;