IBINI0A6 ; ; 21-MAR-1994
;;Version 2.0 ; INTEGRATED BILLING ;; 21-MAR-94
Q:'DIFQ(399) F I=1:2 S X=$T(Q+I) Q:X="" S Y=$E($T(Q+I+1),4,999),X=$E(X,4,999) S:$A(Y)=126 I=I+1,Y=$E(Y,2,999)_$E($T(Q+I+1),5,99) S:$A(Y)=61 Y=$E(Y,2,999) X NO E S @X=Y
Q Q
;;^DD(399,16,1,0)
;;=^.1
;;^DD(399,16,1,1,0)
;;=^^TRIGGER^399^17
;;^DD(399,16,1,1,1)
;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"S")):^("S"),1:"") S X=$P(Y(1),U,17),X=X S DIU=X K Y S X=DIV S X=DT X ^DD(399,16,1,1,1.4)
;;^DD(399,16,1,1,1.4)
;;=S DIH=$S($D(^DGCR(399,DIV(0),"S")):^("S"),1:""),DIV=X S $P(^("S"),U,17)=DIV,DIH=399,DIG=17 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
;;^DD(399,16,1,1,2)
;;=Q
;;^DD(399,16,1,1,"CREATE VALUE")
;;=TODAY
;;^DD(399,16,1,1,"DELETE VALUE")
;;=NO EFFECT
;;^DD(399,16,1,1,"FIELD")
;;=#17
;;^DD(399,16,1,2,0)
;;=^^TRIGGER^399^18
;;^DD(399,16,1,2,1)
;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"S")):^("S"),1:"") S X=$P(Y(1),U,18),X=X S DIU=X K Y S X=DIV S X=DUZ X ^DD(399,16,1,2,1.4)
;;^DD(399,16,1,2,1.4)
;;=S DIH=$S($D(^DGCR(399,DIV(0),"S")):^("S"),1:""),DIV=X S $P(^("S"),U,18)=DIV,DIH=399,DIG=18 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
;;^DD(399,16,1,2,2)
;;=Q
;;^DD(399,16,1,2,"CREATE VALUE")
;;=S X=DUZ
;;^DD(399,16,1,2,"DELETE VALUE")
;;=NO EFFECT
;;^DD(399,16,1,2,"FIELD")
;;=#18
;;^DD(399,16,2)
;;=S Y(0)=Y S Y=$S(Y:"YES",Y=0:"NO",1:"")
;;^DD(399,16,2.1)
;;=S Y=$S(Y:"YES",Y=0:"NO",1:"")
;;^DD(399,16,3)
;;=Enter 'Yes' or '1' if you want this billing record to be cancelled, 'No' or '0' if you do not want this billing record to be cancelled.
;;^DD(399,16,21,0)
;;=^^1^1^2880831^
;;^DD(399,16,21,1,0)
;;=This allows the user to cancel this bill.
;;^DD(399,16,"DT")
;;=2880608
;;^DD(399,17,0)
;;=DATE BILL CANCELLED^DI^^S;17^S %DT="ETX" D ^%DT S X=Y K:Y<1 X
;;^DD(399,17,1,0)
;;=^.1
;;^DD(399,17,1,1,0)
;;=^^TRIGGER^399^.13
;;^DD(399,17,1,1,1)
;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X I $P(^DGCR(399,DA,"S"),U,16)=1 I X S X=DIV S Y(1)=$S($D(^DGCR(399,D0,0)):^(0),1:"") S X=$P(Y(1),U,13),X=X S DIU=X K Y S X=DIV S X=7 X ^DD(399,17,1,1,1.4)
;;^DD(399,17,1,1,1.4)
;;=S DIH=$S($D(^DGCR(399,DIV(0),0)):^(0),1:""),DIV=X S $P(^(0),U,13)=DIV,DIH=399,DIG=.13 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
;;^DD(399,17,1,1,2)
;;=Q
;;^DD(399,17,1,1,"CREATE CONDITION")
;;=I $P(^DGCR(399,DA,"S"),U,16)=1
;;^DD(399,17,1,1,"CREATE VALUE")
;;=S X=7
;;^DD(399,17,1,1,"DELETE VALUE")
;;=NO EFFECT
;;^DD(399,17,1,1,"FIELD")
;;=STATUS
;;^DD(399,17,3)
;;=Enter date on which this bill was cancelled.
;;^DD(399,17,5,1,0)
;;=399^16^1
;;^DD(399,17,21,0)
;;=^^1^1^2880831^
;;^DD(399,17,21,1,0)
;;=This is the date on which this billing record was cancelled.
;;^DD(399,17,"DT")
;;=2900119
;;^DD(399,18,0)
;;=BILL CANCELLED BY^P200'I^VA(200,^S;18^Q
;;^DD(399,18,3)
;;=Enter user who cancelled this bill.
;;^DD(399,18,5,1,0)
;;=399^16^2
;;^DD(399,18,21,0)
;;=^^1^1^2880831^
;;^DD(399,18,21,1,0)
;;=This is the user who cancelled this bill.
;;^DD(399,18,"DT")
;;=2900921
;;^DD(399,19,0)
;;=REASON CANCELLED^RFX^^S;19^K:$L(X)>100!($L(X)<3)!'(X?1A.ANP) X I '$D(X) X ^DD(399,19,9.3)
;;^DD(399,19,3)
;;=Enter the 3-100 character reason(s) why this bill was cancelled.
;;^DD(399,19,9.3)
;;=W ?5,"Reason for cancellation is mandatory if you wish to cancel this bill.",!,?5,"Bill will not be cancelled if this field is left unanswered.",!
;;^DD(399,19,21,0)
;;=^^3^3^2900417^^^
;;^DD(399,19,21,1,0)
;;=This is the reason(s) why this bill was cancelled. This entry is mandatory
;;^DD(399,19,21,2,0)
;;=when cancelling a bill. Enter 3-100 characters, the first character must
;;^DD(399,19,21,3,0)
;;=be an alphabetic character.
;;^DD(399,19,"DT")
;;=2920121
;;^DD(399,40,0)
;;=CONDITION CODE^399.04SA^^CC;0
;;^DD(399,40,21,0)
;;=^^2^2^2931229^^^
IBINI0A6 ; ; 21-MAR-1994
+1 ;;Version 2.0 ; INTEGRATED BILLING ;; 21-MAR-94
+2 IF 'DIFQ(399)
QUIT
FOR I=1:2
SET X=$TEXT(Q+I)
IF X=""
QUIT
SET Y=$EXTRACT($TEXT(Q+I+1),4,999)
SET X=$EXTRACT(X,4,999)
IF $ASCII(Y)=126
SET I=I+1
SET Y=$EXTRACT(Y,2,999)_$EXTRACT($TEXT(Q+I+1),5,99)
IF $ASCII(Y)=61
SET Y=$EXTRACT(Y,2,999)
XECUTE NO
IF '$TEST
SET @X=Y
Q QUIT
+1 ;;^DD(399,16,1,0)
+2 ;;=^.1
+3 ;;^DD(399,16,1,1,0)
+4 ;;=^^TRIGGER^399^17
+5 ;;^DD(399,16,1,1,1)
+6 ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"S")):^("S"),1:"") S X=$P(Y(1),U,17),X=X S DIU=X K Y S X=DIV S X=DT X ^DD(399,16,1,1,1.4)
+7 ;;^DD(399,16,1,1,1.4)
+8 ;;=S DIH=$S($D(^DGCR(399,DIV(0),"S")):^("S"),1:""),DIV=X S $P(^("S"),U,17)=DIV,DIH=399,DIG=17 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
+9 ;;^DD(399,16,1,1,2)
+10 ;;=Q
+11 ;;^DD(399,16,1,1,"CREATE VALUE")
+12 ;;=TODAY
+13 ;;^DD(399,16,1,1,"DELETE VALUE")
+14 ;;=NO EFFECT
+15 ;;^DD(399,16,1,1,"FIELD")
+16 ;;=#17
+17 ;;^DD(399,16,1,2,0)
+18 ;;=^^TRIGGER^399^18
+19 ;;^DD(399,16,1,2,1)
+20 ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(1)=$S($D(^DGCR(399,D0,"S")):^("S"),1:"") S X=$P(Y(1),U,18),X=X S DIU=X K Y S X=DIV S X=DUZ X ^DD(399,16,1,2,1.4)
+21 ;;^DD(399,16,1,2,1.4)
+22 ;;=S DIH=$S($D(^DGCR(399,DIV(0),"S")):^("S"),1:""),DIV=X S $P(^("S"),U,18)=DIV,DIH=399,DIG=18 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
+23 ;;^DD(399,16,1,2,2)
+24 ;;=Q
+25 ;;^DD(399,16,1,2,"CREATE VALUE")
+26 ;;=S X=DUZ
+27 ;;^DD(399,16,1,2,"DELETE VALUE")
+28 ;;=NO EFFECT
+29 ;;^DD(399,16,1,2,"FIELD")
+30 ;;=#18
+31 ;;^DD(399,16,2)
+32 ;;=S Y(0)=Y S Y=$S(Y:"YES",Y=0:"NO",1:"")
+33 ;;^DD(399,16,2.1)
+34 ;;=S Y=$S(Y:"YES",Y=0:"NO",1:"")
+35 ;;^DD(399,16,3)
+36 ;;=Enter 'Yes' or '1' if you want this billing record to be cancelled, 'No' or '0' if you do not want this billing record to be cancelled.
+37 ;;^DD(399,16,21,0)
+38 ;;=^^1^1^2880831^
+39 ;;^DD(399,16,21,1,0)
+40 ;;=This allows the user to cancel this bill.
+41 ;;^DD(399,16,"DT")
+42 ;;=2880608
+43 ;;^DD(399,17,0)
+44 ;;=DATE BILL CANCELLED^DI^^S;17^S %DT="ETX" D ^%DT S X=Y K:Y<1 X
+45 ;;^DD(399,17,1,0)
+46 ;;=^.1
+47 ;;^DD(399,17,1,1,0)
+48 ;;=^^TRIGGER^399^.13
+49 ;;^DD(399,17,1,1,1)
+50 ;;=K DIV S DIV=X,D0=DA,DIV(0)=D0 S Y(0)=X I $P(^DGCR(399,DA,"S"),U,16)=1 I X S X=DIV S Y(1)=$S($D(^DGCR(399,D0,0)):^(0),1:"") S X=$P(Y(1),U,13),X=X S DIU=X K Y S X=DIV S X=7 X ^DD(399,17,1,1,1.4)
+51 ;;^DD(399,17,1,1,1.4)
+52 ;;=S DIH=$S($D(^DGCR(399,DIV(0),0)):^(0),1:""),DIV=X S $P(^(0),U,13)=DIV,DIH=399,DIG=.13 D ^DICR:$N(^DD(DIH,DIG,1,0))>0
+53 ;;^DD(399,17,1,1,2)
+54 ;;=Q
+55 ;;^DD(399,17,1,1,"CREATE CONDITION")
+56 ;;=I $P(^DGCR(399,DA,"S"),U,16)=1
+57 ;;^DD(399,17,1,1,"CREATE VALUE")
+58 ;;=S X=7
+59 ;;^DD(399,17,1,1,"DELETE VALUE")
+60 ;;=NO EFFECT
+61 ;;^DD(399,17,1,1,"FIELD")
+62 ;;=STATUS
+63 ;;^DD(399,17,3)
+64 ;;=Enter date on which this bill was cancelled.
+65 ;;^DD(399,17,5,1,0)
+66 ;;=399^16^1
+67 ;;^DD(399,17,21,0)
+68 ;;=^^1^1^2880831^
+69 ;;^DD(399,17,21,1,0)
+70 ;;=This is the date on which this billing record was cancelled.
+71 ;;^DD(399,17,"DT")
+72 ;;=2900119
+73 ;;^DD(399,18,0)
+74 ;;=BILL CANCELLED BY^P200'I^VA(200,^S;18^Q
+75 ;;^DD(399,18,3)
+76 ;;=Enter user who cancelled this bill.
+77 ;;^DD(399,18,5,1,0)
+78 ;;=399^16^2
+79 ;;^DD(399,18,21,0)
+80 ;;=^^1^1^2880831^
+81 ;;^DD(399,18,21,1,0)
+82 ;;=This is the user who cancelled this bill.
+83 ;;^DD(399,18,"DT")
+84 ;;=2900921
+85 ;;^DD(399,19,0)
+86 ;;=REASON CANCELLED^RFX^^S;19^K:$L(X)>100!($L(X)<3)!'(X?1A.ANP) X I '$D(X) X ^DD(399,19,9.3)
+87 ;;^DD(399,19,3)
+88 ;;=Enter the 3-100 character reason(s) why this bill was cancelled.
+89 ;;^DD(399,19,9.3)
+90 ;;=W ?5,"Reason for cancellation is mandatory if you wish to cancel this bill.",!,?5,"Bill will not be cancelled if this field is left unanswered.",!
+91 ;;^DD(399,19,21,0)
+92 ;;=^^3^3^2900417^^^
+93 ;;^DD(399,19,21,1,0)
+94 ;;=This is the reason(s) why this bill was cancelled. This entry is mandatory
+95 ;;^DD(399,19,21,2,0)
+96 ;;=when cancelling a bill. Enter 3-100 characters, the first character must
+97 ;;^DD(399,19,21,3,0)
+98 ;;=be an alphabetic character.
+99 ;;^DD(399,19,"DT")
+100 ;;=2920121
+101 ;;^DD(399,40,0)
+102 ;;=CONDITION CODE^399.04SA^^CC;0
+103 ;;^DD(399,40,21,0)
+104 ;;=^^2^2^2931229^^^