source: WorldVistAEHR/trunk/r/FEE_BASIS-FB/FBXIP91.m@ 1003

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

initial load of WorldVistAEHR

File size: 1.1 KB
Line 
1FBXIP91 ;WCIOFO/SAB-PATCH INSTALL ROUTINE ;4/28/2005
2 ;;3.5;FEE BASIS;**91**;JAN 30, 1995
3 Q
4 ;
5PS ; post-install entry point
6 ; create KIDS checkpoints with call backs
7 N FBX,Y
8 F FBX="CVT" D
9 . S Y=$$NEWCP^XPDUTL(FBX,FBX_"^FBXIP91")
10 . I 'Y D BMES^XPDUTL("ERROR Creating "_FBX_" Checkpoint.")
11 Q
12 ;
13CVT ; Fix Invalid Data in Field #8.5 within the PRESCRIPTION muliple
14 ; of file 162.1
15 N FBC,FB85I,FBDA,FBDA1,FBFDA,FBTXT,FBX
16 D BMES^XPDUTL(" Fixing data in SubFile 162.11 Field #8.5...")
17 ;
18 S FBC=0 ; init count of corrected values
19 ; loop thru pharmacy invoices
20 S FBDA=0 F S FBDA=$O(^FBAA(162.1,FBDA)) Q:'FBDA D
21 . ; loop thru prescriptions
22 . S FBDA1=0 F S FBDA1=$O(^FBAA(162.1,FBDA,"RX",FBDA1)) Q:'FBDA1 D
23 . . ; obtain internal value of field #8.5
24 . . S FB85I=$P($G(^FBAA(162.1,FBDA,"RX",FBDA1,0)),U,21)
25 . . S FBX=$S(FB85I="Yes":"Y",FB85I="No":"N",1:"")
26 . . Q:FBX="" ; not one of the values that should be converted
27 . . S FBFDA(162.11,FBDA1_","_FBDA_",",8.5)=FBX
28 . . D FILE^DIE("","FBFDA")
29 . . S FBC=FBC+1
30 ;
31 S FBTXT=" "_FBC_" invalid value"_$S(FBC=1:" was",1:"s were")_" found and corrected."
32 D MES^XPDUTL(FBTXT)
33 Q
34 ;
35 ;FBXIP91
Note: See TracBrowser for help on using the repository browser.