source: WorldVistAEHR/trunk/r/SURGERY-SR/SROICU.m@ 1766

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

initial load of WorldVistAEHR

File size: 1.6 KB
Line 
1SROICU ;B'HAM ISC/MAM - UNSCHEDULED ADMISSIONS TO ICU ; [ 01/08/98 9:54 AM ]
2 ;;3.0; Surgery ;**77,106**;24 Jun 93
3 S SRINST=SRSITE("SITE"),SRSOUT=0 W @IOF,!,"Report of Unscheduled Admissions to the ICU",!
4DATE D DATE^SROUTL(.SRSD,.SRED,.SRSOUT) G:SRSOUT END
5SPEC W @IOF,!,"Do you want the report for a specific Surgical Specialty ? NO// " R SRYN:DTIME I '$T!(SRYN["^") S SRSOUT=1 G END
6 S SRSS="",SRYN=$E(SRYN) I SRYN="" S SRYN="N"
7 I "YyNn"'[SRYN W !!,"Enter 'YES' to print this report for a specific surgical specialty, or RETURN",!,"to print the report, sorted by the date of operation, for all specialties.",!!,"Press RETURN to continue " R X:DTIME G SPEC
8 I "Yy"[SRYN D SP I SRSOUT G END
9 W !!,"This report is designed to use a 132 column format."
10 N SRINSTP S SRINST=$$INST^SROUTL0() G:SRINST="^" END S SRINSTP=$P(SRINST,U),SRINST=$S(SRINST["ALL DIVISIONS":SRINST,1:$P(SRINST,U,2))
11 W ! K IOP,POP,IO("Q"),%ZIS S %ZIS="QM",%ZIS("A")="Print the Report on which Device ? " D ^%ZIS I POP S SRSOUT=1 G END
12 I $D(IO("Q")) K IO("Q") S ZTDESC="Unscheduled Admissions to ICU",ZTRTN="EN^SROICU",(ZTSAVE("SRSD"),ZTSAVE("SRED"),ZTSAVE("SRSS"),ZTSAVE("SRINST"),ZTSAVE("SRINSTP"))="" D ^%ZTLOAD G END
13EN ; entry when queued
14 U IO I SRSS D ^SROICU1 G END
15 D ^SROICU2
16END I $E(IOST)'="P",'SRSOUT W !!,"Press RETURN to continue " R X:DTIME
17 W:$E(IOST)="P" @IOF I $D(ZTQUEUED) Q:$G(ZTSTOP) S ZTREQ="@" Q
18 D ^%ZISC K SRTN D ^SRSKILL W @IOF
19 Q
20SP ; select specialty
21 W ! K DIC S DIC("S")="I '$P(^(0),""^"",3)",DIC=137.45,DIC(0)="QEAMZ",DIC("A")="Print the report for which Surgical Specialty ? " D ^DIC I Y<0 S SRSOUT=1
22 S SRSS=+Y
23 Q
Note: See TracBrowser for help on using the repository browser.