ENSP1 ;(WASH ISC)/WDS@Charleston-Room, Lock, and Function Report ;4-22-93
V ;;7.0;ENGINEERING;;Aug 17, 1993
INIT ;
ASK S DIR(0)="SA^R:ROOM;S:SERVICE",DIR("A")="SORT REPORT BY: ",DIR("B")="R"
S DIR("?")=" <cr> or 'R' to list by room, 'S' to list by service, '^' to QUIT",DIR("??")="^D HELP^ENSP1" D ^DIR G:$D(DIRUT) EXIT G @Y(0)
;
SETUP ;Set up variables before tasking or printing directly
W !! K IOP D DEV^ENLIB G:POP EXIT S IOP=ION,L="0",DIC="^ENG(""SP"",",FLDS="[ENSP-ROOM-LOCK]"
S DIOEND="I IOST[""C-"" R !!,""Press <RETURN> to continue"",X:DTIME"
DQ1 S:$D(IO("Q")) IOP="Q;"_IOP D EN1^DIP G EXIT
;
SERVICE ; PRINT ROOM/LOCK/FUNCTION REPORT BY SERVICE ORDER
S DHD="Engineering ROOM/LOCK Report by Using Service for - "_$P(^DIC(6910,1,0),U,1)
S BY="#1.5,2;S2,.01" G SETUP
;
ROOM ; PRINT ROOM/LOCK/FUNCTION REPORT BY ROOM NUMBER
S DHD="Engineering ROOM/LOCK Report by Room Number for - "_$P(^DIC(6910,1,0),U,1)
S BY=".01" G SETUP
;
FLDS ;LOCAL SELECTION OF PRINT TEMPLATE FOR FLDS
S FLDS="[ENSPRM]",DA=$O(^ENG(6910.2,"B","SPACE SURVEY PRINTOUT",0)) I DA>0,$D(^ENG(6910.2,DA,0)) S X=$P(^(0),"^",2) I X="L",$D(^DIPT("B","ENZSPRM")) S FLDS="[ENZSPRM]"
Q
EXIT K DA,DIR,FR,TO Q
;
HELP W !!,"Sort by ROOM gives an 80 column listing of all rooms that have"
W !,"key/lock assignments in room order along with their assigned functions."
W !!,"Sort by SERVICE gives a similar report that is useful as a keying"
W !,"plan for all services. It is broken down by Service with each"
W !,"assigned key broken out in its own segment. Room numbers for the"
W !,"particular key are sorted in order under that key.",! Q
;ENSP1
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HENSP1 1661 printed Nov 22, 2024@17:05:48 Page 2
ENSP1 ;(WASH ISC)/WDS@Charleston-Room, Lock, and Function Report ;4-22-93
V ;;7.0;ENGINEERING;;Aug 17, 1993
INIT ;
ASK SET DIR(0)="SA^R:ROOM;S:SERVICE"
SET DIR("A")="SORT REPORT BY: "
SET DIR("B")="R"
+1 SET DIR("?")=" <cr> or 'R' to list by room, 'S' to list by service, '^' to QUIT"
SET DIR("??")="^D HELP^ENSP1"
DO ^DIR
if $DATA(DIRUT)
GOTO EXIT
GOTO @Y(0)
+2 ;
SETUP ;Set up variables before tasking or printing directly
+1 WRITE !!
KILL IOP
DO DEV^ENLIB
if POP
GOTO EXIT
SET IOP=ION
SET L="0"
SET DIC="^ENG(""SP"","
SET FLDS="[ENSP-ROOM-LOCK]"
+2 SET DIOEND="I IOST[""C-"" R !!,""Press <RETURN> to continue"",X:DTIME"
DQ1 if $DATA(IO("Q"))
SET IOP="Q;"_IOP
DO EN1^DIP
GOTO EXIT
+1 ;
SERVICE ; PRINT ROOM/LOCK/FUNCTION REPORT BY SERVICE ORDER
+1 SET DHD="Engineering ROOM/LOCK Report by Using Service for - "_$PIECE(^DIC(6910,1,0),U,1)
+2 SET BY="#1.5,2;S2,.01"
GOTO SETUP
+3 ;
ROOM ; PRINT ROOM/LOCK/FUNCTION REPORT BY ROOM NUMBER
+1 SET DHD="Engineering ROOM/LOCK Report by Room Number for - "_$PIECE(^DIC(6910,1,0),U,1)
+2 SET BY=".01"
GOTO SETUP
+3 ;
FLDS ;LOCAL SELECTION OF PRINT TEMPLATE FOR FLDS
+1 SET FLDS="[ENSPRM]"
SET DA=$ORDER(^ENG(6910.2,"B","SPACE SURVEY PRINTOUT",0))
IF DA>0
IF $DATA(^ENG(6910.2,DA,0))
SET X=$PIECE(^(0),"^",2)
IF X="L"
IF $DATA(^DIPT("B","ENZSPRM"))
SET FLDS="[ENZSPRM]"
+2 QUIT
EXIT KILL DA,DIR,FR,TO
QUIT
+1 ;
HELP WRITE !!,"Sort by ROOM gives an 80 column listing of all rooms that have"
+1 WRITE !,"key/lock assignments in room order along with their assigned functions."
+2 WRITE !!,"Sort by SERVICE gives a similar report that is useful as a keying"
+3 WRITE !,"plan for all services. It is broken down by Service with each"
+4 WRITE !,"assigned key broken out in its own segment. Room numbers for the"
+5 WRITE !,"particular key are sorted in order under that key.",!
QUIT
+6 ;ENSP1