ORWDBA81 ; SLC/GDU - Billing Awareness - Phase I [10/18/04 10:42]
 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**195**;Dec 17, 1997
 ;
 ;Enable Clinical Indicator Data Capture By Provider Parameter Module
 ;ORWDBA81 - Mass assign the parameter to all providers without the 
 ;           parameter and set it to 1 to enable the CIDC functionality.
 ;
 ;Local Variables
 ;DIR          Input array variable for ^DIR
 ;DTOUT        Timeout indicator, output variable of ^DIR
 ;DUOUT        Up arrow indicator, output variable of ^DIR
 ;ENT          Entity the parameter is assigned to, input variable for
 ;             ADD^XPAR
 ;ORERR        Error Message, output variable of ADD^XPAR
 ;INST         Instance indicator, input variable for ADD^XPAR
 ;IOF          Clear Screen and move cursor to top of screen, standard
 ;             Kernal IO variable
 ;PAR          The Name or IEN of a parameter in the PARAMETER DEFINITION
 ;             FILE, input variable for ADD^XPAR 
 ;VAL          Value of the parameter being added, input variable for
 ;             ADD^XPAR
 ;X            Standard FileMan work varaible
 ;Y            Processed output of user selection, output variable for
 ;             ^DIR
 ;
 ;Global Variables
 ;^TMP("ORPUL" Temp global for providers who do not have the
 ;             Enable/Disable CIDC By Provider parameter assigned to them
 ;^XTV(8989.51 PARAMETER DEFINITION FILE, file # 8989.51
 ;
 ;External References
 ;^DIR         FileMan general purpose response reader
 ;ADD^XPAR     PARAMETER TOOLS, API to add a new parameter value
 ;
MAIN ;Starting point of this program
 N DIR,DTOUT,DUOUT,ENT,ORERR,INST,PAR,VAL,X,Y
 ;Prepare and display user options for this program
 S DIR(0)=$P($T(SXOPT),";",3)_";"
 S DIR(0)=DIR(0)_$P($T(OY),";",3)_";"_$P($T(ON),";",3)
 S DIR("A",1)=^TMP("ORPUL",$J,"A")_" "_$P($T(A1),";",3)
 S DIR("A",2)=$P($T(A2),";",3)
 S DIR("A",3)=$P($T(A3),";",3)
 S DIR("A")=$P($T(A4),";",3)
 S DIR("?",1)=$P($T(HY),";",3)
 S DIR("?")=$P($T(HN),";",3)
 D SCRHDR,^DIR K DIR
 ;Process user selection.
 I Y="NO"!($D(DTOUT))!($D(DUOUT)) Q  ;If NO, timeout, or up arrow quit
 ;Process the mass parameter assignment and functionality enabling
 S (ENT,X)="",(INST,VAL)=1
 S PAR=$QS($Q(^XTV(8989.51,"B","OR BILLING AWARENESS BY USER")),4)
 D SCRHDR
 W !!,$P($T(EP),";",3),!
 S X="" F  S X=$O(^TMP("ORPUL",$J,"A",X)) Q:X=""  D
 . W "."
 . S ENT=^TMP("ORPUL",$J,"A",X)
 . D ADD^XPAR(ENT,PAR,INST,VAL,.ORERR)
 ;Alert user the mass parameter assignment and functionality enabling is
 ;done.
 S DIR(0)="E",DIR("A")=$P($T(EC),";",3)
 D ^DIR K DIR Q
SCRHDR ;Screen Header
 W:$D(IOF) @IOF
 W !,$P($T(SH1),";",3),!,$P($T(SH2),";",3)
 Q
SXOPT ;;SX^
SH1 ;;Enable Clinical Indicator Data Capture By Provider Parameter Management
SH2 ;;Assign/Enable Parameter For All Providers Option
OY ;;YES:Enter YES to begin process of assign/enable
ON ;;NO:Enter NO to cancel process of assign/enable and quit
A1 ;;providers do not have this parameter assigned to them.
A2 ;;You have selected to assign the parameter and enable Clinical Indictor
A3 ;;Data Capture for all of these providers. This may take some time.
A4 ;;Are you sure you want to do this? (YES/NO - must be all caps)
HY ;;Enter YES to begin the assign/enable process.
HN ;;Enter NO to cancel the assign/enable process and quit.
EP ;;Now assigning CIDC parameter and enabling the functionality.
EC ;;CIDC parameter assignment and functionality enabling complete.
 
--- Routine Detail   --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORWDBA81   3514     printed  Sep 23, 2025@20:11:45                                                                                                                                                                                                    Page 2
ORWDBA81  ; SLC/GDU - Billing Awareness - Phase I [10/18/04 10:42]
 +1       ;;3.0;ORDER ENTRY/RESULTS REPORTING;**195**;Dec 17, 1997
 +2       ;
 +3       ;Enable Clinical Indicator Data Capture By Provider Parameter Module
 +4       ;ORWDBA81 - Mass assign the parameter to all providers without the 
 +5       ;           parameter and set it to 1 to enable the CIDC functionality.
 +6       ;
 +7       ;Local Variables
 +8       ;DIR          Input array variable for ^DIR
 +9       ;DTOUT        Timeout indicator, output variable of ^DIR
 +10      ;DUOUT        Up arrow indicator, output variable of ^DIR
 +11      ;ENT          Entity the parameter is assigned to, input variable for
 +12      ;             ADD^XPAR
 +13      ;ORERR        Error Message, output variable of ADD^XPAR
 +14      ;INST         Instance indicator, input variable for ADD^XPAR
 +15      ;IOF          Clear Screen and move cursor to top of screen, standard
 +16      ;             Kernal IO variable
 +17      ;PAR          The Name or IEN of a parameter in the PARAMETER DEFINITION
 +18      ;             FILE, input variable for ADD^XPAR 
 +19      ;VAL          Value of the parameter being added, input variable for
 +20      ;             ADD^XPAR
 +21      ;X            Standard FileMan work varaible
 +22      ;Y            Processed output of user selection, output variable for
 +23      ;             ^DIR
 +24      ;
 +25      ;Global Variables
 +26      ;^TMP("ORPUL" Temp global for providers who do not have the
 +27      ;             Enable/Disable CIDC By Provider parameter assigned to them
 +28      ;^XTV(8989.51 PARAMETER DEFINITION FILE, file # 8989.51
 +29      ;
 +30      ;External References
 +31      ;^DIR         FileMan general purpose response reader
 +32      ;ADD^XPAR     PARAMETER TOOLS, API to add a new parameter value
 +33      ;
MAIN      ;Starting point of this program
 +1        NEW DIR,DTOUT,DUOUT,ENT,ORERR,INST,PAR,VAL,X,Y
 +2       ;Prepare and display user options for this program
 +3        SET DIR(0)=$PIECE($TEXT(SXOPT),";",3)_";"
 +4        SET DIR(0)=DIR(0)_$PIECE($TEXT(OY),";",3)_";"_$PIECE($TEXT(ON),";",3)
 +5        SET DIR("A",1)=^TMP("ORPUL",$JOB,"A")_" "_$PIECE($TEXT(A1),";",3)
 +6        SET DIR("A",2)=$PIECE($TEXT(A2),";",3)
 +7        SET DIR("A",3)=$PIECE($TEXT(A3),";",3)
 +8        SET DIR("A")=$PIECE($TEXT(A4),";",3)
 +9        SET DIR("?",1)=$PIECE($TEXT(HY),";",3)
 +10       SET DIR("?")=$PIECE($TEXT(HN),";",3)
 +11       DO SCRHDR
           DO ^DIR
           KILL DIR
 +12      ;Process user selection.
 +13      ;If NO, timeout, or up arrow quit
           IF Y="NO"!($DATA(DTOUT))!($DATA(DUOUT))
               QUIT 
 +14      ;Process the mass parameter assignment and functionality enabling
 +15       SET (ENT,X)=""
           SET (INST,VAL)=1
 +16       SET PAR=$QSUBSCRIPT($QUERY(^XTV(8989.51,"B","OR BILLING AWARENESS BY USER")),4)
 +17       DO SCRHDR
 +18       WRITE !!,$PIECE($TEXT(EP),";",3),!
 +19       SET X=""
           FOR 
               SET X=$ORDER(^TMP("ORPUL",$JOB,"A",X))
               if X=""
                   QUIT 
               Begin DoDot:1
 +20               WRITE "."
 +21               SET ENT=^TMP("ORPUL",$JOB,"A",X)
 +22               DO ADD^XPAR(ENT,PAR,INST,VAL,.ORERR)
               End DoDot:1
 +23      ;Alert user the mass parameter assignment and functionality enabling is
 +24      ;done.
 +25       SET DIR(0)="E"
           SET DIR("A")=$PIECE($TEXT(EC),";",3)
 +26       DO ^DIR
           KILL DIR
           QUIT 
SCRHDR    ;Screen Header
 +1        if $DATA(IOF)
               WRITE @IOF
 +2        WRITE !,$PIECE($TEXT(SH1),";",3),!,$PIECE($TEXT(SH2),";",3)
 +3        QUIT 
SXOPT     ;;SX^
SH1       ;;Enable Clinical Indicator Data Capture By Provider Parameter Management
SH2       ;;Assign/Enable Parameter For All Providers Option
OY        ;;YES:Enter YES to begin process of assign/enable
ON        ;;NO:Enter NO to cancel process of assign/enable and quit
A1        ;;providers do not have this parameter assigned to them.
A2        ;;You have selected to assign the parameter and enable Clinical Indictor
A3        ;;Data Capture for all of these providers. This may take some time.
A4        ;;Are you sure you want to do this? (YES/NO - must be all caps)
HY        ;;Enter YES to begin the assign/enable process.
HN        ;;Enter NO to cancel the assign/enable process and quit.
EP        ;;Now assigning CIDC parameter and enabling the functionality.
EC        ;;CIDC parameter assignment and functionality enabling complete.