source: WorldVistAEHR/trunk/r/KERNEL-XU-A4A7-USC-XG-XLF-XNOA-XPD-XQ-XVIR-ZI-ZOSF-ZOSV-ZT-ZU-%Z-XIP--XQAB--XUC--XUR--ZIN--ZTED/ZISHUNT.m@ 701

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

initial load of WorldVistAEHR

File size: 1.9 KB
RevLine 
[613]1ZISHUNT ;SFISC/AC - HUNT GROUP MANAGER ;11/29/89 15:52
2 ;;8.0;KERNEL;;Jul 10, 1995
3 ;
4EDIT ;Edit Hunt Groups.
5 S DIC("A")="Select Hunt Group: ",ZISHG(0)="E" D DIC
6 Q
7DEL ;Delete Hunt Groups
8 K ^TMP($J)
9 S DIC("A")="Delete which Hunt Group: ",ZISHG(0)="D",ZISHGK=0 D DIC
10 Q:'ZISHGK
11 W !,"You have selected for deletion the following Hunt Groups:",!
12 F ZISI=1:1:ZISHGK I $D(^TMP($J,"DEL",ZISI)) W !?20,$P(^(ZISI),"^",2)
13 W !!,"OK TO DELETE" S %=0,U="^" D YN^DICN
14 I %'=1 W *7," ??" K ^TMP($J),ZISI,ZISHGK Q
15 F ZISI=1:1:ZISHGK I $D(^TMP($J,"DEL",ZISI)) S ZISY=^(ZISI),DA=+ZISY,DIE="^%ZIS(1,",DR=".01///@" D ^DIE W !?20,$P(ZISY,"^",2)_" -- DELETED"
16 K ^TMP($J),ZISI,ZISHGK,ZISY
17 Q
18DIC W !,DIC("A") R X:DTIME
19 G END:X["^",END:X=""
20 I X?1"?" W !," Enter name of Hunt Group",!!," DO YOU WANT THE ENTIRE HUNT GROUP LIST" S %=0,U="^" D YN^DICN G DIC:%'=1 S X="??" D LST G DIC
21 I X?2"?" D LST G DIC
22 S DIC="^%ZIS(1,",DIC(0)="EMZ",DIC("S")="I $D(^(""TYPE"")),^(""TYPE"")=""HG"""
23 I X=$C(32) S X=$S($D(^DISV(DUZ,"^%ZIS(1,")):^("^%ZIS(1,"),1:"") G DIC:'X S X="`"_X
24 D ^DIC
25 I Y<0 S X1=$O(^%ZIS(1,"B",X)) I X1]"",$P(X1,X)="" G DIC
26 I Y<0 X:$D(^DD(3.5,.01,0)) $P(^(0),"^",5) I '$D(X) W *7," ??" G DIC
27 G @ZISHG(0)
28 ;
29LST S DIC="^%ZIS(1,",DIC(0)="EMZ",DIC("S")="I $D(^(""TYPE"")),^(""TYPE"")=""HG""" D ^DIC Q
30 ;
31E I Y<0 W !?2,*7," ARE YOU ADDING '"_X_"' AS A NEW HUNT GROUP" S %=0,U="^" D YN^DICN W:%'=1 *7," ??" G DIC:%'=1 D ADD
32 Q:Y'>0
33 S DIE=DIC,DA=+Y,DR=30 D ^DIE
34 S DIC("A")="Select Hunt Group: ",ZISHG(0)="E" G DIC
35 ;S DIC="^%ZIS(1,",DIC(0)="AEMZ",DIC("A")="Select Hunt Group: ",DIC("S")="I $D(^(""TYPE"")),^(""TYPE"")=""HG""" D ^DIC
36 Q
37ADD ;Add Hunt Groups
38 S DIC(0)="LMZ",DLAYGO=3,DIC("DR")="2////HG" D ^DIC I Y<0 W *7,"<"_X_" DELETED>" Q
39 Q
40D I Y>0,$P(Y,"^",2)]"" S ZISHGK=ZISHGK+1,^TMP($J,"DEL",ZISHGK)=Y,DIC("A")="Another Hunt Group: "
41 W:Y'>0 *7," ??"
42 S DIC("A")="Delete which Hunt Group: ",ZISHG(0)="D" G DIC
43END K DA,DIC,DIE,DR,X1,X,Y,ZISHG(0) Q
Note: See TracBrowser for help on using the repository browser.