source: WorldVistAEHR/trunk/r/FEE_BASIS-FB/FBNHEDPA.m@ 1556

Last change on this file since 1556 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 2.4 KB
Line 
1FBNHEDPA ;AISC/GRR-EDIT PAYMENT FOR COMMUNITY NURSING HOME ;7/8/2003
2 ;;3.5;FEE BASIS;**61**;JAN 30, 1995
3 ;;Per VHA Directive 10-93-142, this routine should not be modified.
4EDIT ;ENTRY POINT TO EDIT PAYMENT
5 S IOP=$S($D(ION):ION,1:"HOME") D ^%ZIS K IOP
6BT S DIC="^FBAA(161.7,",DIC(0)="AEQMZ",DIC("S")="I $P(^(0),U,3)=""B9""",DIC("S")=$S($D(^XUSEC("FBAASUPERVISOR",DUZ)):DIC("S"),1:DIC("S")_"&($P(^(0),U,5)=DUZ)") D ^DIC
7 G END:X=""!(X="^"),BT:Y<0 S FBN=+Y,FBN(0)=Y(0)
8 S FBSTAT=^FBAA(161.7,FBN,"ST")
9 I FBSTAT="C"&('$D(^XUSEC("FBAASUPERVISOR",DUZ))) W !!,*7,?3,"You must Reopen the batch prior to editting the invoice.",! G END
10 I FBSTAT="S"!(FBSTAT="P")!(FBSTAT="R")&('$D(^XUSEC("FBAASUPERVISOR",DUZ))) W !!,*7,?3,"You must be a holder of the 'FBAASUPERVISOR' security key",!,?3,"to edit this invoice.",! G END
11 I FBSTAT="T"!(FBSTAT="V") W !!,?3,"Batch has already been sent to Austin for payment.",! G END
12INV W ! S DIC("A")="Select Invoice Number: ",DIC="^FBAAI(",DIC(0)="AEQMZ",DIC("S")="I $P(^(0),U,17)=FBN" D ^DIC K DIC G BT:X=""!(X="^"),INV:Y<0 S FBI=+Y,FBOLD(0)=Y(0)
13 S FBLISTC="",FBHDI=FBI W @IOF D START^FBCHDI S FBI=FBHDI K FBHDI
14 K FBHAP,FBAP
15 S (DIE,DIC)="^FBAAI(",DIC(0)="AEQM",DA=FBI,DR="[FBNH EDIT PAYMENT]",DIE("NO^")=""
16 W !
17 N FBHAC
18 ; get values of FPPS Claim ID and Line Item
19 S FBFPPSC=$P($G(^FBAAI(FBI,3)),U)
20 S FBFPPSL=$P($G(^FBAAI(FBI,3)),U,2)
21 ; load current adjustment data
22 D LOADADJ^FBCHFA(FBI_",",.FBADJ)
23 ; save adjustment data prior to edit session in sorted list
24 S FBADJL(0)=$$ADJL^FBUTL2(.FBADJ) ; sorted list of original adjustments
25 ; load current remittance remark data
26 D LOADRR^FBCHFR(FBI_",",.FBRRMK)
27 ; save remittance remarks prior to edit session in sorted list
28 S FBRRMKL(0)=$$RRL^FBUTL4(.FBRRMK)
29 D ^DIE K DIE("NO^")
30 I $D(DTOUT) S DR="5///^S X="_$P(FBOLD(0),U,6)_";6///^S X="_$P(FBOLD(0),U,7) D ^DIE
31 ; if adjustment data changed then file
32 I $$ADJL^FBUTL2(.FBADJ)'=FBADJL(0) D FILEADJ^FBCHFA(FBI_",",.FBADJ)
33 ; if remit remark data changed then file
34 I $$RRL^FBUTL4(.FBRRMK)'=FBRRMKL(0) D FILERR^FBCHFR(FBI_",",.FBRRMK)
35 I $D(FBHAP),$D(FBAP),FBAP-FBHAP S FBDIF=FBAP-FBHAP,$P(^FBAA(161.7,FBN,0),"^",9)=$P(^FBAA(161.7,FBN,0),"^",9)+FBDIF
36END K DA,DFN,DIC,DIE,DR,FBAAOUT,FBDX,FBI,FBIN,FBLISTC,FBN,FBPROC,FBSTAT,FBVEN,FBVID,J,K,L,POP,Q,VA,VADM,X,Y,FBAC,FBAP,FBBAL,FBHAP,FBDIF
37 K FBADJ,FBADJL,FBRRMK,FBRRMKL,FBFPPSC,FBFPPSL
38 D KILL^FBPAY K FBOLD,FBINODE,FBPAT,FBPRGNAM
39 Q
Note: See TracBrowser for help on using the repository browser.