source: FOIAVistA/trunk/r/INTEGRATED_BILLING-IB-PRQ--IBD--IBQ--PRQS/IB20P398.m@ 635

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

initial load of FOIAVistA 6/30/08 version

File size: 1.9 KB
Line 
1IB20P398 ;MNT/RRA - DSS CLINIC STOP CODES IB*2.0*398 POST-INIT ; 3/13/07 12:55pm
2 ;;2.0;INTEGRATED BILLING;**398**;21-MAR-94;Build 3
3 ;;Per VHA Directive 2004-038, this routine should not be modified.
4 ;
5EN ;
6 N IBEFFDT,U
7 S U="^"
8 D START,UPDATE,FINISH
9 Q
10 ;
11START D BMES^XPDUTL("DSS Clinic Stop Codes, Post-Install Starting")
12 Q
13 ;
14FINISH D BMES^XPDUTL("DSS Clinic Stop Codes, Post-Install Complete")
15 Q
16 ;
17 ;
18UPDATE ;update an old code
19 N Y,IB1,IBC,IBT,IBX,IBCODE,IBMSG,IBTYPE,IBDES,IBOVER,IBLSTDT,IBY
20 S (IBC,IBMSG(1),IBMSG(2),IBMSG(3))=0
21 D BMES^XPDUTL(" Updating Stop Code entries in file 352.5")
22 F IBX=1:1 S IBT=$P($T(OCODE+IBX),";",3) Q:'$L(IBT) D
23 . S IBCODE=+$P(IBT,U)
24 . S IBY=$P(IBT,U,5)
25 . I $D(^IBE(352.5,"AEFFDT",IBCODE,-IBY)) D Q
26 . . D BMES^XPDUTL(" Duplication of stop code "_IBCODE)
27 . S IBLSTDT=$O(^IBE(352.5,"AEFFDT",IBCODE,-9999999))
28 . I +IBLSTDT=0 D Q
29 . . D BMES^XPDUTL(" Code "_IBCODE_" not found in file 352.5")
30 . S IB1=$O(^IBE(352.5,"AEFFDT",IBCODE,IBLSTDT,0))
31 . S IB1=$G(^IBE(352.5,IB1,0))
32 . S IBTYPE=$S($P(IBT,U,2)'="":$P(IBT,U,2),1:$P(IB1,U,3))
33 . S IBDES=$S($P(IBT,U,3)'="":$E($P(IBT,U,3),1,30),1:$P(IB1,U,4))
34 . S IBOVER=$S($P(IBT,U,4)'="":$P(IBT,U,4),1:$P(IB1,U,5))
35 . S Y=+$$ADD3525(IBCODE,IBY,IBTYPE,IBDES,IBOVER) S:Y>0 IBC=IBC+1
36 D BMES^XPDUTL(" "_IBC_$S(IBC<2:" update",1:" updates")_" added to file 352.5")
37 Q
38 ;
39ADD3525(IBCODE,IBEFFDT,IBTYPE,IBDES,IBOVER) ;
40 ;add a new entry
41 D BMES^XPDUTL(" "_IBCODE_" "_IBDES)
42 N IBIENS,IBFDA,IBER,IBRET
43 S IBRET=""
44 S IBIENS="+1,"
45 S IBFDA(352.5,IBIENS,.01)=IBCODE
46 S IBFDA(352.5,IBIENS,.02)=IBEFFDT
47 S IBFDA(352.5,IBIENS,.03)=IBTYPE
48 S IBFDA(352.5,IBIENS,.04)=IBDES
49 S:IBOVER IBFDA(352.5,IBIENS,.05)=1
50 D UPDATE^DIE("","IBFDA","IBRET","IBER")
51 I $D(IBER) D BMES^XPDUTL(IBER("DIERR",1,"TEXT",1))
52 Q $G(IBRET(1))
53 ;
54 ;codes update
55OCODE ;;code^billable type^description^override flag
56 ;;372^0^^1^3080616
57 ;;373^0^^1^3080616
58 ;
Note: See TracBrowser for help on using the repository browser.