Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: IB20P128

IB20P128.m

Go to the documentation of this file.
IB20P128 ;ALB/RB - IB*2*128 POST-INIT ; 10-FEB-00
 ;;2.0;INTEGRATED BILLING;**128**;21-MAR-94
 ;
 ; - Change values of input variables IBCANC and IBINRC of INSURANCE
 ;   PAYMENT TREND GRAND TOTALS entry in file #351.7
 S A0=+$O(^IBE(351.7,"B","INSURANCE PAYMENT TREND GRAND ",0))
 S A1=$O(^IBE(351.7,A0,1,"B","IBCANC",0)) I 'A1 G DEL
 S A2=$O(^IBE(351.7,A0,1,"B","IBINRC",0)) I 'A2 G DEL
 I '$P($G(^IBE(351.7,A0,1,A1,0)),U,2) G DEL
 D BMES^XPDUTL("Updating variables IBCANC & IBINRC in file #351.7 entry")
 F X=A1,A2 S $P(^IBE(351.7,A0,1,X,0),U,2)=0
 ;
DEL ; - Delete entries GRAND TOTAL NUMBER OF CANCELLED BILLS and GRAND
 ;   TOTAL AMOUNT OF CANCELLED BILLS from file #351.701 and re-index.
 I '$O(^IBE(351.701,"B","GRAND TOTAL NUMBER OF CANCELLE",0)) G ENQ
 D BMES^XPDUTL("Deleting GRAND TOTAL NUMBER OF CANCELLED BILLS entry")
 D BMES^XPDUTL("Deleting GRAND TOTAL AMOUNT OF CANCELLED BILLS entry")
 S A1=$O(^IBE(351.701,"B","GRAND TOTAL NUMBER OF CANCELLE",0))
 S A2=$O(^IBE(351.701,"B","GRAND TOTAL AMOUNT OF CANCELLE",0))
 F X=A1,A2 K ^IBE(351.701,X,0)
 D BMES^XPDUTL("Re-indexing file #351.701")
 S A1=$O(^IBE(351.701,"B","LESS THAN 30 DAYS OLD/TOTAL",0))
 S A2=$P(^IBE(351.701,0),U,4)
 F X=A1:1:A2 D
 .S ^IBE(351.701,(X-2),0)=$G(^IBE(351.701,X,0)) K ^IBE(351.701,X,0)
 .I X=A2 S A3=A2-2,$P(^IBE(351.701,0),U,3,4)=A3_U_A3
 F X="B","C" K ^IBE(351.701,X)
 S DIK="^IBE(351.701," D IXALL^DIK
 ;
ENQ K DA,DIK,A0,A1,A2,A3,X D BMES^XPDUTL("Post-init finished")
 Q