IVMCMB ;ALB/SEK,BRM,TDM - SEND INCOME TEST TRANSMISSION BULLETIN ; 4/2/09 1:19pm
;;2.0;INCOME VERIFICATION MATCH;**17,49,140**;21-OCT-94;Build 2
;
; Input array required:
; ^TMP($J,"IVMBULL" -- contains lists of tests which were uploaded
; dfn^type of test^dt of test^category^action
;
BULL ; Send mail message notifying site of uploaded income tests.
;
G BULLQ ; This bulletin has been disabled. IVM*2*140
;
K IVMTEXT
I '$D(^TMP($J,"IVMBULL")) G BULLQ
S XMSUB="HEC INCOME TEST UPLOAD"
S IVMTEXT(1)="Income tests were uploaded from the Health Eligibility Center"
S IVMTEXT(2)="for the following patients:"
S IVMTEXT(3)=" "
S IVMTEXT(4)=" Name PID Type TestDate Old->New Action"
S IVMTEXT(5)=" Code"
S IVMBCTR=$G(^TMP($J,"IVMBULL",0))
F IVMBDA=1:1:IVMBCTR D
.S IVMBULLM=$G(^TMP($J,"IVMBULL",IVMBDA)) Q:'IVMBULLM
.S IVMPAT=$$PT^IVMUFNC4($P(IVMBULLM,"^"))
.S $E(IVMTEXT(IVMBDA+5),1,30)=$E($P(IVMPAT,"^"),1,18)_" "_$P(IVMPAT,"^",2)
.S $E(IVMTEXT(IVMBDA+5),31,41)=$S($P(IVMBULLM,"^",2)=1:"Means Test",$P(IVMBULLM,"^",2)=2:"Copay Test",$P(IVMBULLM,"^",2)=4:"LTC Test",1:"")
.S Y=$P(IVMBULLM,"^",3) X ^DD("DD") ;test date
.S $E(IVMTEXT(IVMBDA+5),43,53)=Y
.S $E(IVMTEXT(IVMBDA+5),56,56)=$P(IVMBULLM,"^",4) ;status before
.S $E(IVMTEXT(IVMBDA+5),57,58)="->"
.S $E(IVMTEXT(IVMBDA+5),59)=$P(IVMBULLM,"^",5) ;status after
.S $E(IVMTEXT(IVMBDA+5),64,78)=$P(IVMBULLM,"^",6) ;action
;
D MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
BULLQ K IVMBCTR,IVMBDA,IVMBULLM,^TMP($J,"IVMBULL"),IVMPAT,Y
Q
;
BULL1(DFN,WDATE,SITE) ;
;Send message notifying site of hardship determination
;
N IVMTEXT,IVMPAT
S IVMPAT=$$PT^IVMUFNC4(DFN)
S XMSUB="HEC NOTIFICATION OF HARDSHIP"
S IVMTEXT(1)="A hardship determination was uploaded from the Health Eligibility Center"
S IVMTEXT(2)="for the following patient:"
S IVMTEXT(3)=" "
S IVMTEXT(4)=" Name: "_$P(IVMPAT,"^")
S IVMTEXT(5)=" PID: "_$P(IVMPAT,"^",2)
S IVMTEXT(6)=" Effective Date: "_$S(WDATE:$$FMTE^XLFDT(WDATE),1:"UNKNOWN")
S IVMTEXT(7)="Site Granting Hardship: "_$S($L(SITE):SITE,1:"UNKNOWN")
;
D MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
Q
;
BULL2(DFN,WDATE,SITE) ;
;Send message notifying site of deletion of hardship determination
;
N IVMTEXT,IVMPAT
S IVMPAT=$$PT^IVMUFNC4(DFN)
S XMSUB="HEC NOTIFICATION OF HARDSHIP"
S IVMTEXT(1)="Notification has been received from the Health Eligibility Center "
S IVMTEXT(2)="that the hardship determination was deleted for the following patient:"
S IVMTEXT(3)=" "
S IVMTEXT(4)=" Name: "_$P(IVMPAT,"^")
S IVMTEXT(5)=" PID: "_$P(IVMPAT,"^",2)
S IVMTEXT(6)=" Effective Date Prior to Deletion: "_$S(WDATE:$$FMTE^XLFDT(WDATE),1:"UNKNOWN")
S IVMTEXT(7)="Site Originally Granting Hardship: "_$S($L(SITE):SITE,1:"UNKNOWN")
;
D MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
Q
;
BULL3(DFN) ;
;Send message notifying site to discontinue net-worth adjudication
;
Q:('$G(DFN))
;
N IVMTEXT,IVMPAT
S IVMPAT=$$PT^IVMUFNC4(DFN)
S XMSUB="HEC Authority Over Networth-Adjudication"
S IVMTEXT(1)="Please discontinue development of net-worth for the following patient:"
S IVMTEXT(2)=" "
S IVMTEXT(3)=" "
S IVMTEXT(4)=" Name: "_$P(IVMPAT,"^")
S IVMTEXT(5)=" PID: "_$P(IVMPAT,"^",2)
;
D MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
Q
;
ADD(DFN,TYPETEST,ACTION,TESTDATE,STATUS1,STATUS2) ;
;Adds to the notification list
;
N COUNT
S COUNT=$G(^TMP($J,"IVMBULL",0))+1
S ^TMP($J,"IVMBULL",COUNT)=DFN_U_$G(TYPETEST)_U_$G(TESTDATE)_U_$G(STATUS1)_U_$G(STATUS2)_U_$G(ACTION)
S ^TMP($J,"IVMBULL",0)=COUNT
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HIVMCMB 3844 printed Sep 15, 2024@21:25:27 Page 2
IVMCMB ;ALB/SEK,BRM,TDM - SEND INCOME TEST TRANSMISSION BULLETIN ; 4/2/09 1:19pm
+1 ;;2.0;INCOME VERIFICATION MATCH;**17,49,140**;21-OCT-94;Build 2
+2 ;
+3 ; Input array required:
+4 ; ^TMP($J,"IVMBULL" -- contains lists of tests which were uploaded
+5 ; dfn^type of test^dt of test^category^action
+6 ;
BULL ; Send mail message notifying site of uploaded income tests.
+1 ;
+2 ; This bulletin has been disabled. IVM*2*140
GOTO BULLQ
+3 ;
+4 KILL IVMTEXT
+5 IF '$DATA(^TMP($JOB,"IVMBULL"))
GOTO BULLQ
+6 SET XMSUB="HEC INCOME TEST UPLOAD"
+7 SET IVMTEXT(1)="Income tests were uploaded from the Health Eligibility Center"
+8 SET IVMTEXT(2)="for the following patients:"
+9 SET IVMTEXT(3)=" "
+10 SET IVMTEXT(4)=" Name PID Type TestDate Old->New Action"
+11 SET IVMTEXT(5)=" Code"
+12 SET IVMBCTR=$GET(^TMP($JOB,"IVMBULL",0))
+13 FOR IVMBDA=1:1:IVMBCTR
Begin DoDot:1
+14 SET IVMBULLM=$GET(^TMP($JOB,"IVMBULL",IVMBDA))
if 'IVMBULLM
QUIT
+15 SET IVMPAT=$$PT^IVMUFNC4($PIECE(IVMBULLM,"^"))
+16 SET $EXTRACT(IVMTEXT(IVMBDA+5),1,30)=$EXTRACT($PIECE(IVMPAT,"^"),1,18)_" "_$PIECE(IVMPAT,"^",2)
+17 SET $EXTRACT(IVMTEXT(IVMBDA+5),31,41)=$SELECT($PIECE(IVMBULLM,"^",2)=1:"Means Test",$PIECE(IVMBULLM,"^",2)=2:"Copay Test",$PIECE(IVMBULLM,"^",2)=4:"LTC Test",1:"")
+18 ;test date
SET Y=$PIECE(IVMBULLM,"^",3)
XECUTE ^DD("DD")
+19 SET $EXTRACT(IVMTEXT(IVMBDA+5),43,53)=Y
+20 ;status before
SET $EXTRACT(IVMTEXT(IVMBDA+5),56,56)=$PIECE(IVMBULLM,"^",4)
+21 SET $EXTRACT(IVMTEXT(IVMBDA+5),57,58)="->"
+22 ;status after
SET $EXTRACT(IVMTEXT(IVMBDA+5),59)=$PIECE(IVMBULLM,"^",5)
+23 ;action
SET $EXTRACT(IVMTEXT(IVMBDA+5),64,78)=$PIECE(IVMBULLM,"^",6)
End DoDot:1
+24 ;
+25 DO MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
BULLQ KILL IVMBCTR,IVMBDA,IVMBULLM,^TMP($JOB,"IVMBULL"),IVMPAT,Y
+1 QUIT
+2 ;
BULL1(DFN,WDATE,SITE) ;
+1 ;Send message notifying site of hardship determination
+2 ;
+3 NEW IVMTEXT,IVMPAT
+4 SET IVMPAT=$$PT^IVMUFNC4(DFN)
+5 SET XMSUB="HEC NOTIFICATION OF HARDSHIP"
+6 SET IVMTEXT(1)="A hardship determination was uploaded from the Health Eligibility Center"
+7 SET IVMTEXT(2)="for the following patient:"
+8 SET IVMTEXT(3)=" "
+9 SET IVMTEXT(4)=" Name: "_$PIECE(IVMPAT,"^")
+10 SET IVMTEXT(5)=" PID: "_$PIECE(IVMPAT,"^",2)
+11 SET IVMTEXT(6)=" Effective Date: "_$SELECT(WDATE:$$FMTE^XLFDT(WDATE),1:"UNKNOWN")
+12 SET IVMTEXT(7)="Site Granting Hardship: "_$SELECT($LENGTH(SITE):SITE,1:"UNKNOWN")
+13 ;
+14 DO MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
+15 QUIT
+16 ;
BULL2(DFN,WDATE,SITE) ;
+1 ;Send message notifying site of deletion of hardship determination
+2 ;
+3 NEW IVMTEXT,IVMPAT
+4 SET IVMPAT=$$PT^IVMUFNC4(DFN)
+5 SET XMSUB="HEC NOTIFICATION OF HARDSHIP"
+6 SET IVMTEXT(1)="Notification has been received from the Health Eligibility Center "
+7 SET IVMTEXT(2)="that the hardship determination was deleted for the following patient:"
+8 SET IVMTEXT(3)=" "
+9 SET IVMTEXT(4)=" Name: "_$PIECE(IVMPAT,"^")
+10 SET IVMTEXT(5)=" PID: "_$PIECE(IVMPAT,"^",2)
+11 SET IVMTEXT(6)=" Effective Date Prior to Deletion: "_$SELECT(WDATE:$$FMTE^XLFDT(WDATE),1:"UNKNOWN")
+12 SET IVMTEXT(7)="Site Originally Granting Hardship: "_$SELECT($LENGTH(SITE):SITE,1:"UNKNOWN")
+13 ;
+14 DO MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
+15 QUIT
+16 ;
BULL3(DFN) ;
+1 ;Send message notifying site to discontinue net-worth adjudication
+2 ;
+3 if ('$GET(DFN))
QUIT
+4 ;
+5 NEW IVMTEXT,IVMPAT
+6 SET IVMPAT=$$PT^IVMUFNC4(DFN)
+7 SET XMSUB="HEC Authority Over Networth-Adjudication"
+8 SET IVMTEXT(1)="Please discontinue development of net-worth for the following patient:"
+9 SET IVMTEXT(2)=" "
+10 SET IVMTEXT(3)=" "
+11 SET IVMTEXT(4)=" Name: "_$PIECE(IVMPAT,"^")
+12 SET IVMTEXT(5)=" PID: "_$PIECE(IVMPAT,"^",2)
+13 ;
+14 DO MAIL^IVMUFNC("DGMT MT/CT UPLOAD ALERTS")
+15 QUIT
+16 ;
ADD(DFN,TYPETEST,ACTION,TESTDATE,STATUS1,STATUS2) ;
+1 ;Adds to the notification list
+2 ;
+3 NEW COUNT
+4 SET COUNT=$GET(^TMP($JOB,"IVMBULL",0))+1
+5 SET ^TMP($JOB,"IVMBULL",COUNT)=DFN_U_$GET(TYPETEST)_U_$GET(TESTDATE)_U_$GET(STATUS1)_U_$GET(STATUS2)_U_$GET(ACTION)
+6 SET ^TMP($JOB,"IVMBULL",0)=COUNT
+7 QUIT