source: FOIAVistA/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/ORWDBA10.m@ 1535

Last change on this file since 1535 was 628, checked in by George Lilly, 15 years ago

initial load of FOIAVistA 6/30/08 version

File size: 5.5 KB
Line 
1ORWDBA10 ; SLC/GDU - Billing Awareness - Phase I [11/24/04 13:42]
2 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**195,261**;Dec 17, 1997
3 ;Clinical Indicator Data Capture By Provider Parameter Module
4 ;
5 ;This program will enable or disable the CIDC functionality for all
6 ;active providers. For the active providers without the CIDC parameter,
7 ;this program will assign the CIDC parameter to them and enable or
8 ;disable the CIDC functionality.
9 ;
10 ;The enabling or disabling of the CIDC functionality is based on the
11 ;user selected value of an external variable passed to this program.
12 ;
13 ;External Variable:
14 ; CIDC Clinical Indicator Data Capture
15 ; A value of E for enable CIDC functionality.
16 ; A value of D for disable CIDC functionality.
17 ; Set by user selection in ORWDBA6 and passed to this
18 ; program.
19 ;Internal Variables:
20 ; CNT Counter variable, used to build temporary global
21 ; DIR Input array variable for ^DIR
22 ; DT Standard Fileman/Kernel variable for current date
23 ; DT is set, not newed or killed
24 ; DTOUT Timeout indicator, output variable of ^DIR
25 ; DUOUT Up arrow indicator, output variable of ^DIR
26 ; OREM Error Message, output variable for XPAR
27 ; IEN Internal Entry Number
28 ; LIST Input variable of XPAR where output ENVAL^XAR
29 ; will be stored
30 ; PTD Provider Termination Date
31 ; VAL Input variable of XPAR
32 ; A value of 1 will enable CIDC functionality
33 ; A value of 0 will disable CIDC functionality
34 ; X Work variable
35 ; Y Processed user selection, output variable of ^DIR
36 ;External References
37 ; ^DIR DBIA 10026
38 ; ADD^XPAR DBIA 2263
39 ; ENVAL^XPAR DBIA 2263
40 ;
41EN(CIDC) ;Entry point for this program
42 N CNT,DIR,DTOUT,DUOUT,OREM,IEN,LIST,PTD,VAL,X,Y
43 K ^TMP($J,"OR","CIDC")
44 S DT=$$DT^XLFDT
45 ;Get list of clinicians with the CIDC functionality parameter assigned
46 ;to them.
47 S OREM="",LIST="^TMP($J,""OR"",""CIDC"",""A"")"
48 D ENVAL^XPAR(LIST,"OR BILLING AWARENESS BY USER",1,.OREM,1)
49 ;Build list of active clinicians who do not have the CIDC functionality
50 ;parameter not assigned to them.
51 S IEN="",(CNT,^TMP($J,"OR","CIDC","U",0))=0
52 F S IEN=$O(^XUSEC("PROVIDER",IEN)) Q:IEN="" D
53 . ;Skip to next provider is CIDC parameter assigned
54 . I $D(^TMP($J,"OR","CIDC","A",IEN_";VA(200,",1))=1 Q
55 . ;Skip to next provider if DISUSER set to yes
56 . I $$GET1^DIQ(200,IEN,7)="YES" Q
57 . ;Get provider termination date, skip to next provider if this date is
58 . ;today's date or in the past.
59 . S PTD=$$GET1^DIQ(200,IEN,9.2,"I")
60 . I PTD'="",(PTD=DT)!(PTD<DT) Q
61 . ;Add to list
62 . S CNT=CNT+1
63 . S ^TMP($J,"OR","CIDC","U",0)=CNT
64 . S ^TMP($J,"OR","CIDC","U",CNT)=IEN_";VA(200,"
65 ;Build and display user interface
66 S DIR(0)="SX^;"_$P($T(OY),";",3)
67 S DIR(0)=DIR(0)_$S(CIDC="E":$P($T(OYE),";",3),1:$P($T(OYD),";",3))_";"
68 S DIR(0)=DIR(0)_$P($T(ON),";",3)
69 S DIR(0)=DIR(0)_$S(CIDC="E":$P($T(ONE),";",3),1:$P($T(OND),";",3))
70 S DIR("A",1)=$S(CIDC="E":$P($T(A2E),";",3),1:$P($T(A2D),";",3))
71 S DIR("A",2)=$P($T(A3),";",3)
72 S DIR("A")=$P($T(A4),";",3)
73 S DIR("?",1)=$P($T(HY),";",3)
74 S DIR("?",1)=DIR("?",1)_$S(CIDC="E":$P($T(HYE),";",3),1:$P($T(HYD),";",3))
75 S DIR("?")=$P($T(HN),";",3)
76 S DIR("?")=DIR("?")_$S(CIDC="E":$P($T(HNE),";",3),1:$P($T(HND),";",3))
77 D SCRHDR,^DIR K DIR
78 ;Process user's selection
79 ;If the user selects no, times out, or enters "^" quit program
80 I Y="NO"!($D(DTOUT))!($D(DUOUT)) W !!,$C(7),$P($T(CP),";",3) H 1 G EXIT
81 ;Enable/disable CIDC parameter functionality.
82 D SCRHDR
83 W !!,$S(CIDC="E":$P($T(EP),";",3),1:$P($T(DP),";",3))
84 S VAL=$S(CIDC="E":1,1:0)
85 ;Enable/disable CIDC functionality for active providers with the parameter
86 ;as per user selection
87 S X="" F S X=$O(^TMP($J,"OR","CIDC","A",X)) Q:X="" D
88 . W "."
89 . D CHG^XPAR(X,"OR BILLING AWARENESS BY USER",1,VAL,.OREM)
90 ;Assigning the CIDC parameter to active providers without it and enable/disable
91 ;CIDC functionality as per user selection
92 F X=1:1:^TMP($J,"OR","CIDC","U",0) D
93 . W "."
94 . D ADD^XPAR(^TMP($J,"OR","CIDC","U",X),"OR BILLING AWARENESS BY USER",1,VAL,.OREM)
95 ;Alert the user the enabling/disabling CIDC functionality is done.
96 S DIR("A")=$S(CIDC="E":$P($T(EC),";",3),1:$P($T(DC),";",3))
97 S DIR(0)="E"
98 D ^DIR K DIR
99EXIT ;Exit point of this routine
100 K ^TMP($J,"OR","CIDC")
101 Q
102 ;
103SCRHDR ;Screen Header
104 W:$D(IOF) @IOF
105 W !,$P($T(SH),";",3)
106 W !,$S(CIDC="E":$P($T(SHE),";",3),1:$P($T(SHD),";",3))
107 Q
108 ;Text for the user's interface
109SH ;;Enable Clinical Indicator Data Capture By Provider Parameter Management
110SHE ;;Enable Parameter For All Active Providers Option
111SHD ;;Disable Parameter For All Active Providers Option
112OY ;;YES:Enter YES to begin process to
113ON ;;NO:Enter NO to cancel process to
114OYE ;; enable CIDC
115ONE ;; enable CIDC and quit
116OYD ;; disable CIDC
117OND ;; disable CIDC and quit
118A1 ;;active providers do not have this parameter assigned to them.
119A2E ;;You have selected to enable Clinical Indictor Data Capture
120A2D ;;You have selected to disable Clinical Indicator Data Capture
121A3 ;;for all active providers. This may take some time.
122A4 ;;Are you sure you want to do this? (YES/NO - must be all cap)
123HY ;;Enter YES to begin the
124HN ;;Enter No or '^' to cancel the
125HYE ;; enable CIDC process.
126HNE ;; enable CIDC process and quit.
127HYD ;; disable CIDC process.
128HND ;; disable CIDC process and quit.
129EP ;;Now enabling CIDC functionality.
130EC ;;CIDC parameter functionality enabling complete.
131DP ;;Now disabling CIDC functionality.
132DC ;;CIDC parameter functionality disabling complete.
133CP ;;Process cancelled!
Note: See TracBrowser for help on using the repository browser.