source: WorldVistAEHR/trunk/r/PCE_PATIENT_CARE_ENCOUNTER-AUTN-EFDP-PX-VSIT--PXRM/PXRRPRD.m@ 1211

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

initial load of WorldVistAEHR

File size: 2.1 KB
RevLine 
[613]1PXRRPRD ;ISL/PKR,ALB/Zoltan - PCE Provider Encounter reports driver.;9/22/98
2 ;;1.0;PCE PATIENT CARE ENCOUNTER;**3,10,12,18,61**;Aug 12, 1996
3MAIN ;
4 N PXRRIOD,PXRRPRJB,PXRRPRST,PXRROPT,PXRRQUE,PXRRXTMP
5 S PXRRXTMP=$$PXRRXTMP^PXRRWLD("PXRRPR")
6 S ^XTMP(PXRRXTMP,0)=$$FMADD^XLFDT(DT,7)_U_DT_U_"PXRR Provider Encounter Count"
7 ;
8 ;Establish the selection criteria.
9FAC ;Get the facility list.
10 N NFAC,PXRRFAC,PXRRFACN
11 D FACILITY^PXRRLCSC
12 I $D(DTOUT)!$D(DUOUT) G EXIT
13 ;
14DR ;Get the date range.
15 N PXRRBDT,PXRREDT
16 D PDR^PXRRADUT(.PXRRBDT,.PXRREDT,"ENCOUNTER")
17 I $D(DTOUT) G EXIT
18 I $D(DUOUT) G FAC
19 ;
20SCAT ;Get the service categories.
21 N PXRRSCAT
22 D SCAT^PXRRECSC
23 I $D(DTOUT) G EXIT
24 I $D(DUOUT) G DR
25 ;
26PRV ;Get the provider list.
27 N NCL,NPL,PXRRPECL,PXRRPRPL,PXRRPRSC
28 D PRV^PXRRPRSC
29 I $D(DTOUT) G EXIT
30 I $D(DUOUT) G SCAT
31 ;
32PRTY ;Get the report type (detailed or summary).
33 N PXRRPRTY
34 D PRTYPE^PXRRPRSC
35 I $D(DTOUT) G EXIT
36 I $D(DUOUT) G PRV
37 ;
38 ;Determine whether the report should be queued.
39 S %ZIS="QM"
40 W !
41 D ^%ZIS
42 I POP G EXIT
43 S PXRRIOD=ION_";"_IOST_";"_IOM_";"_IOSL
44 S PXRRQUE=$G(IO("Q"))
45 ;
46 ;Queue the report.
47 I PXRRQUE D
48 . N DESC,IODEV,ROUTINE
49 . S DESC="Provider Encounter Count Report - sort"
50 . S IODEV=""
51 . S ROUTINE="SORT^PXRRPRSE"
52 . S ^XTMP(PXRRXTMP,"SORTZTSK")=$$QUE^PXRRQUE(DESC,IODEV,ROUTINE,"SAVE^PXRRPRD")
53 .;
54 . S DESC="Provider Encounter Report - print"
55 . S IODEV=PXRRIOD
56 . I $P(PXRRPRTY,U,1)="D" S ROUTINE="PXRRPRDP"
57 . E S ROUTINE="PXRRPRSP"
58 . S ZTDTH="@"
59 . S ^XTMP(PXRRXTMP,"PRZTSK")=$$QUE^PXRRQUE(DESC,IODEV,ROUTINE,"SAVE^PXRRPRD")
60 E D SORT^PXRRPRSE
61 Q
62 ;=======================================================================
63EXIT ;
64 D EXIT^PXRRGUT
65 Q
66 ;
67 ;=======================================================================
68SAVE ;Save the variables.
69 S ZTSAVE("PXRRBDT")="",ZTSAVE("PXRREDT")=""
70 S ZTSAVE("PXRRCS(")="",ZTSAVE("NCS")=""
71 S ZTSAVE("PXRRFAC(")="",ZTSAVE("NFAC")=""
72 S ZTSAVE("PXRRFACN(")=""
73 S ZTSAVE("PXRRIOD")=""
74 S ZTSAVE("PXRRPECL(")="",ZTSAVE("NCL")=""
75 S ZTSAVE("PXRRPRPL(")="",ZTSAVE("NPL")=""
76 S ZTSAVE("PXRRPRSC")=""
77 S ZTSAVE("PXRRPRTY")=""
78 S ZTSAVE("PXRRQUE")=""
79 S ZTSAVE("PXRRSCAT")=""
80 S ZTSAVE("PXRRXTMP")=""
81 Q
82 ;
Note: See TracBrowser for help on using the repository browser.