- IBCICME ;DSI/ESG - IBCI CLAIMSMANAGER ERROR REPORT ;6-APR-2001
- ;;2.0;INTEGRATED BILLING;**161**;21-MAR-94
- ;;Per VHA Directive 10-93-142, this routine should not be modified.
- ;
- NEW STOP,IBCIRTN,DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT,POP,RPTSPECS
- ;
- S STOP=0
- S IBCIRTN="IBCICME"
- W @IOF
- W !?10,"ClaimsManager Error Report",!
- ;
- ; If there are no errors currently stored in the file,
- ; then there is no point in going any further.
- I '$D(^IBA(351.9,"AEC")) D G EXIT
- . W !!?5,"There are no errors currently recorded in the ClaimsManager"
- . W !?5,"file. There is no data to report."
- . W !! S DIR("A")="Press RETURN to continue",DIR(0)="E" D ^DIR K DIR
- . Q
- ;
- ;
- A10 D ERRCODE I STOP G EXIT
- A20 D DATE^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A10
- A30 D DTRANGE^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A20
- A40 D STATUS^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A30
- A50 D TYPE^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A40
- A60 D ERRDISP I STOP G:$$STOP^IBCICMS EXIT G A50
- A70 D SELASN^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G:RPTSPECS("TYPE")="S" A50 G A60
- A80 D ASSIGN^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A70
- A90 D SORTBY^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A80
- A100 D ERRTXT I STOP G:$$STOP^IBCICMS EXIT G A90
- A110 D COMMENTS^IBCICMS I STOP G:$$STOP^IBCICMS EXIT G A100
- A120 D DEVICE^IBCICMS(IBCIRTN) I STOP G:$$STOP^IBCICMS EXIT G:RPTSPECS("TYPE")="S" A50 G A110
- ;
- EXIT ;
- QUIT ; quit from routine
- ;
- COMPILE ; This entry point is called from EN^XUTMDEVQ in either
- ; direct mode or queued mode.
- NEW IBCISCNT
- D BUILD^IBCICME1 ; compile report
- I '$G(ZTSTOP) D EN^IBCICMEP ; print report
- D ^%ZISC ; close the device
- KILL ^TMP($J,IBCIRTN) ; kill main scratch global
- KILL ^TMP($J,IBCIRTN_"-TOTALS") ; kill totals scratch global
- I $D(ZTQUEUED) S ZTREQ="@" ; purge the task record
- COMPX ;
- QUIT ; quit from routine
- ;
- ;
- ;
- ERRCODE ; This procedure displays the error codes currently in the file and
- ; lets the user select all of them or some of them.
- ;
- NEW J,ERR,PCE,NUM
- KILL ^TMP($J,"IBCICME ERROR CODES")
- ;
- ; The first entry should be ALL
- S J=1,ERR="ALL Error Codes in the ClaimsManager File"
- S ^TMP($J,"IBCICME ERROR CODES",J)=ERR
- S DIR("A",J)=$J(J,12)_" "_ERR
- ;
- ; Loop through all error codes to build the arrays
- S ERR=""
- F J=2:1 S ERR=$O(^IBA(351.9,"AEC",ERR)) Q:ERR="" D
- . S ^TMP($J,"IBCICME ERROR CODES",J)=ERR
- . S DIR("A",J)=$J(J,12)_" "_ERR
- . Q
- S DIR("A",J)=" " ; blank line before the prompt
- ;
- S DIR(0)="L^1:"_(J-1)
- S DIR("A")="Please Select the Error Codes to include"
- S DIR("B")=1
- S DIR("?",1)=" This response must be a list or range."
- S DIR("?",2)=" For example, 1,3,5 or 2-4,8"
- S DIR("?",3)=" "
- S DIR("?",4)=" If you include #1, then all codes will be included"
- S DIR("?")=" regardless of what you enter here."
- D ^DIR K DIR
- I $D(DIRUT) S STOP=1 G ERRCODEX
- ;
- ; Add a comma to the front of Y so the $F will work
- ; Check to see if the user response included ALL CODES
- S Y=","_Y
- KILL RPTSPECS("SELECTED ERRCODES")
- S RPTSPECS("ALL ERRCODES")=0
- I $F(Y,",1,") S RPTSPECS("ALL ERRCODES")=1 G ERRCODEX
- ;
- ; remove the leading the trailing commas and then build the list
- S Y=$E(Y,2,$L(Y)-1)
- F PCE=1:1:$L(Y,",") D
- . S NUM=$P(Y,",",PCE),ERR=""
- . I NUM'="" S ERR=^TMP($J,"IBCICME ERROR CODES",NUM)
- . I ERR'="" S RPTSPECS("SELECTED ERRCODES",ERR)=""
- . Q
- ;
- ERRCODEX ;
- KILL ^TMP($J,"IBCICME ERROR CODES")
- Q
- ;
- ;
- ERRTXT ;
- I RPTSPECS("TYPE")="S" S RPTSPECS("DISPLAY ERROR TEXT")=0 G ERRTXTX
- ; Only ask question if it is a detailed report
- W !
- S DIR(0)="Y"
- S DIR("A")="Do you want to see the ClaimsManager Error Messages for these bills"
- S DIR("B")="YES"
- S DIR("?",1)=" Enter YES if you would like to see the full description of the error"
- S DIR("?",2)=" including all lines of error message text."
- S DIR("?")=" Enter NO if you do not want to see this information."
- D ^DIR K DIR
- I $D(DIRUT) S STOP=1 G ERRTXTX
- S RPTSPECS("DISPLAY ERROR TEXT")=+Y
- ERRTXTX ;
- Q
- ;
- ;
- ERRDISP ; get the error display type (esg - 6/12/01)
- I RPTSPECS("TYPE")="S" S RPTSPECS("ERROR DISPLAY TYPE")=1 G ERRDISPX
- ; Only ask question if it is a detailed report
- NEW CH
- W !
- S CH="1:Display all ClaimsManager Errors for a Bill;"
- S CH=CH_"2:Display all Bills for a ClaimsManager Error Code"
- S DIR(0)="SO^"_CH
- S DIR("A")="Select the Error Display Type"
- S DIR("B")=1
- S DIR("?",1)=" The answer to this question will determine how the Bills and Errors"
- S DIR("?",2)=" are displayed on the report."
- S DIR("?",3)=" "
- S DIR("?",4)=" Select option 1 if you want to display all of the ClaimsManager"
- S DIR("?",5)=" errors for each bill that appears on the report. These errors will"
- S DIR("?",6)=" appear together with the bill."
- S DIR("?",7)=" "
- S DIR("?",8)=" Select option 2 if you want to break this report out by ClaimsManager"
- S DIR("?",9)=" error code. In this case, you will see separate sections for each"
- S DIR("?",10)=" error code and all bills in which a particular error code is present."
- S DIR("?",11)=" "
- S DIR("?",12)=" Remember that the bills and errors are still subject to the other"
- S DIR("?")=" selection and sort criteria that you enter."
- D ^DIR K DIR
- I $D(DIRUT) S STOP=1 G ERRDISPX
- S RPTSPECS("ERROR DISPLAY TYPE")=Y
- ;
- ERRDISPX ;
- Q
- ;
- --- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HIBCICME 5546 printed Jan 18, 2025@03:14:24 Page 2
- IBCICME ;DSI/ESG - IBCI CLAIMSMANAGER ERROR REPORT ;6-APR-2001
- +1 ;;2.0;INTEGRATED BILLING;**161**;21-MAR-94
- +2 ;;Per VHA Directive 10-93-142, this routine should not be modified.
- +3 ;
- +4 NEW STOP,IBCIRTN,DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT,POP,RPTSPECS
- +5 ;
- +6 SET STOP=0
- +7 SET IBCIRTN="IBCICME"
- +8 WRITE @IOF
- +9 WRITE !?10,"ClaimsManager Error Report",!
- +10 ;
- +11 ; If there are no errors currently stored in the file,
- +12 ; then there is no point in going any further.
- +13 IF '$DATA(^IBA(351.9,"AEC"))
- Begin DoDot:1
- +14 WRITE !!?5,"There are no errors currently recorded in the ClaimsManager"
- +15 WRITE !?5,"file. There is no data to report."
- +16 WRITE !!
- SET DIR("A")="Press RETURN to continue"
- SET DIR(0)="E"
- DO ^DIR
- KILL DIR
- +17 QUIT
- End DoDot:1
- GOTO EXIT
- +18 ;
- +19 ;
- A10 DO ERRCODE
- IF STOP
- GOTO EXIT
- A20 DO DATE^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A10
- A30 DO DTRANGE^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A20
- A40 DO STATUS^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A30
- A50 DO TYPE^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A40
- A60 DO ERRDISP
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A50
- A70 DO SELASN^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- if RPTSPECS("TYPE")="S"
- GOTO A50
- GOTO A60
- A80 DO ASSIGN^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A70
- A90 DO SORTBY^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A80
- A100 DO ERRTXT
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A90
- A110 DO COMMENTS^IBCICMS
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- GOTO A100
- A120 DO DEVICE^IBCICMS(IBCIRTN)
- IF STOP
- if $$STOP^IBCICMS
- GOTO EXIT
- if RPTSPECS("TYPE")="S"
- GOTO A50
- GOTO A110
- +1 ;
- EXIT ;
- +1 ; quit from routine
- QUIT
- +2 ;
- COMPILE ; This entry point is called from EN^XUTMDEVQ in either
- +1 ; direct mode or queued mode.
- +2 NEW IBCISCNT
- +3 ; compile report
- DO BUILD^IBCICME1
- +4 ; print report
- IF '$GET(ZTSTOP)
- DO EN^IBCICMEP
- +5 ; close the device
- DO ^%ZISC
- +6 ; kill main scratch global
- KILL ^TMP($JOB,IBCIRTN)
- +7 ; kill totals scratch global
- KILL ^TMP($JOB,IBCIRTN_"-TOTALS")
- +8 ; purge the task record
- IF $DATA(ZTQUEUED)
- SET ZTREQ="@"
- COMPX ;
- +1 ; quit from routine
- QUIT
- +2 ;
- +3 ;
- +4 ;
- ERRCODE ; This procedure displays the error codes currently in the file and
- +1 ; lets the user select all of them or some of them.
- +2 ;
- +3 NEW J,ERR,PCE,NUM
- +4 KILL ^TMP($JOB,"IBCICME ERROR CODES")
- +5 ;
- +6 ; The first entry should be ALL
- +7 SET J=1
- SET ERR="ALL Error Codes in the ClaimsManager File"
- +8 SET ^TMP($JOB,"IBCICME ERROR CODES",J)=ERR
- +9 SET DIR("A",J)=$JUSTIFY(J,12)_" "_ERR
- +10 ;
- +11 ; Loop through all error codes to build the arrays
- +12 SET ERR=""
- +13 FOR J=2:1
- SET ERR=$ORDER(^IBA(351.9,"AEC",ERR))
- if ERR=""
- QUIT
- Begin DoDot:1
- +14 SET ^TMP($JOB,"IBCICME ERROR CODES",J)=ERR
- +15 SET DIR("A",J)=$JUSTIFY(J,12)_" "_ERR
- +16 QUIT
- End DoDot:1
- +17 ; blank line before the prompt
- SET DIR("A",J)=" "
- +18 ;
- +19 SET DIR(0)="L^1:"_(J-1)
- +20 SET DIR("A")="Please Select the Error Codes to include"
- +21 SET DIR("B")=1
- +22 SET DIR("?",1)=" This response must be a list or range."
- +23 SET DIR("?",2)=" For example, 1,3,5 or 2-4,8"
- +24 SET DIR("?",3)=" "
- +25 SET DIR("?",4)=" If you include #1, then all codes will be included"
- +26 SET DIR("?")=" regardless of what you enter here."
- +27 DO ^DIR
- KILL DIR
- +28 IF $DATA(DIRUT)
- SET STOP=1
- GOTO ERRCODEX
- +29 ;
- +30 ; Add a comma to the front of Y so the $F will work
- +31 ; Check to see if the user response included ALL CODES
- +32 SET Y=","_Y
- +33 KILL RPTSPECS("SELECTED ERRCODES")
- +34 SET RPTSPECS("ALL ERRCODES")=0
- +35 IF $FIND(Y,",1,")
- SET RPTSPECS("ALL ERRCODES")=1
- GOTO ERRCODEX
- +36 ;
- +37 ; remove the leading the trailing commas and then build the list
- +38 SET Y=$EXTRACT(Y,2,$LENGTH(Y)-1)
- +39 FOR PCE=1:1:$LENGTH(Y,",")
- Begin DoDot:1
- +40 SET NUM=$PIECE(Y,",",PCE)
- SET ERR=""
- +41 IF NUM'=""
- SET ERR=^TMP($JOB,"IBCICME ERROR CODES",NUM)
- +42 IF ERR'=""
- SET RPTSPECS("SELECTED ERRCODES",ERR)=""
- +43 QUIT
- End DoDot:1
- +44 ;
- ERRCODEX ;
- +1 KILL ^TMP($JOB,"IBCICME ERROR CODES")
- +2 QUIT
- +3 ;
- +4 ;
- ERRTXT ;
- +1 IF RPTSPECS("TYPE")="S"
- SET RPTSPECS("DISPLAY ERROR TEXT")=0
- GOTO ERRTXTX
- +2 ; Only ask question if it is a detailed report
- +3 WRITE !
- +4 SET DIR(0)="Y"
- +5 SET DIR("A")="Do you want to see the ClaimsManager Error Messages for these bills"
- +6 SET DIR("B")="YES"
- +7 SET DIR("?",1)=" Enter YES if you would like to see the full description of the error"
- +8 SET DIR("?",2)=" including all lines of error message text."
- +9 SET DIR("?")=" Enter NO if you do not want to see this information."
- +10 DO ^DIR
- KILL DIR
- +11 IF $DATA(DIRUT)
- SET STOP=1
- GOTO ERRTXTX
- +12 SET RPTSPECS("DISPLAY ERROR TEXT")=+Y
- ERRTXTX ;
- +1 QUIT
- +2 ;
- +3 ;
- ERRDISP ; get the error display type (esg - 6/12/01)
- +1 IF RPTSPECS("TYPE")="S"
- SET RPTSPECS("ERROR DISPLAY TYPE")=1
- GOTO ERRDISPX
- +2 ; Only ask question if it is a detailed report
- +3 NEW CH
- +4 WRITE !
- +5 SET CH="1:Display all ClaimsManager Errors for a Bill;"
- +6 SET CH=CH_"2:Display all Bills for a ClaimsManager Error Code"
- +7 SET DIR(0)="SO^"_CH
- +8 SET DIR("A")="Select the Error Display Type"
- +9 SET DIR("B")=1
- +10 SET DIR("?",1)=" The answer to this question will determine how the Bills and Errors"
- +11 SET DIR("?",2)=" are displayed on the report."
- +12 SET DIR("?",3)=" "
- +13 SET DIR("?",4)=" Select option 1 if you want to display all of the ClaimsManager"
- +14 SET DIR("?",5)=" errors for each bill that appears on the report. These errors will"
- +15 SET DIR("?",6)=" appear together with the bill."
- +16 SET DIR("?",7)=" "
- +17 SET DIR("?",8)=" Select option 2 if you want to break this report out by ClaimsManager"
- +18 SET DIR("?",9)=" error code. In this case, you will see separate sections for each"
- +19 SET DIR("?",10)=" error code and all bills in which a particular error code is present."
- +20 SET DIR("?",11)=" "
- +21 SET DIR("?",12)=" Remember that the bills and errors are still subject to the other"
- +22 SET DIR("?")=" selection and sort criteria that you enter."
- +23 DO ^DIR
- KILL DIR
- +24 IF $DATA(DIRUT)
- SET STOP=1
- GOTO ERRDISPX
- +25 SET RPTSPECS("ERROR DISPLAY TYPE")=Y
- +26 ;
- ERRDISPX ;
- +1 QUIT
- +2 ;