source: WorldVistAEHR/trunk/r/PATCH_MANAGEMNT-AAQ/AAQMAILG.m@ 724

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

initial load of WorldVistAEHR

File size: 2.8 KB
Line 
1AAQMAILG ;FGO/JHS;FOR PRINT TEMPLATE XUSERINQFGO ;10-23-92 [5/23/01 4:58pm]
2 ;;8.0;KERNEL;**L11**;Jul 10, 1995
3 ;;Display user's Keys, Mail Groups, and Menu Templates
4 D ^XQDATE X ^%ZOSF("UCI") S AAQUCI=Y
5 I IOST["C-" D CONX G:AAQX="^" EXIT D HDR
6 I IOST["P-",$Y>(IOSL-4) D HDR
7 I $D(^VA(200,D0,51,0)) W !,"Keys Held",!,"---------" S Y=-1 F %=0:0 S %=$O(^VA(200,D0,51,%)),Y=Y+1 Q:'% I $D(^DIC(19.1,%,0))#2 D KEYS
8 I IOST["C-" D CONX G:AAQX="^" EXIT
9 G CHKMG
10KEYS W:'(Y#3) ! W ?(Y#3*27+2),$P(^DIC(19.1,%,0),U,1)
11 I IOST["C-",$Y>(IOSL-4),$X>51 D CON,HDR
12 I IOST["P-",$Y>(IOSL-4),$X>51 D HDR
13 Q
14CHKMG I IOST["C-",$Y>(IOSL-4) D CON,HDR
15 I IOST["P-",$Y>(IOSL-4) D HDR
16 I $D(^XMB(3.8,"AB",D0)) W !!,"Mail Groups",!,"-----------" F X=0:0 S X=$O(^XMB(3.8,"AB",D0,X)) Q:'X I $D(^XMB(3.8,X,0)) S I=^(0),J=$P(I,U,2) I J'="PE"!$D(^XMB(3.8,"AB",D0,X)) D AAQORG
17 G:'$D(^VA(200,D0,19.8)) EXIT
18 W !!,"Menu Templates",!,"--------------",!
19SHO ;Show a user his or her template names
20 S XQUSER=$P($P(^VA(200,D0,0),U),",",2)_" "_$P($P(^(0),U),",")
21 S U="^",(XQI,XQN,XQV)=0
22 S XQN=$O(^VA(200,D0,19.8,"B",XQN)) I XQN="" W !,XQUSER," doesn't have any Menu Templates stored in the Person File." G EXIT
23 D HOME^%ZIS:'$D(IOF),^XQDATE
24 W !,?10,"The menu templates of ",XQUSER," ",%Y S XQV=2
25 D SHO1 F XQI=0:0 S XQN=$O(^VA(200,D0,19.8,"B",XQN)) Q:XQN="" D SHO1
26 G EXIT
27SHO1 ;Write out template name and the first two options in it
28 I IOST["C-",$Y>(IOSL-4) D CON,HDR
29 S XQI=0,XQI=$O(^VA(200,D0,19.8,"B",XQN,XQI)) Q:'$D(^VA(200,D0,19.8,XQI,1,1,0))
30 S %=^VA(200,D0,19.8,XQI,1,1,0),%=$P(%,U,2,999),%1=+$P(%,U,1),%2=+$P(%,U,2)
31 I IOST["C-",'$D(ZTQUEUED),XQV+5>21 S XQV=0 W @IOF
32 W !!,"Template name: ",XQN S XQV=XQV+2
33 I %1 W !,?3,"1st option: ",$S($D(^DIC(19,%1,0))#2:$P(^(0),U,2),1:"*** Missing Option ***") S XQV=XQV+1
34 I %2 W !,?6,"2nd option: ",$S($D(^DIC(19,%2,0))#2:$P(^(0),U,2),1:"*** Missing Option ***") S XQV=XQV+1
35 I $L($P(%,U,3)) W !,?9,"Etc." S XQV=XQV+1
36 Q
37AAQORG I IOST["C-",$Y>(IOSL-4) D CON,HDR
38 I IOST["P-",$Y>(IOSL-4) D HDR
39 W !,?4,$P(I,U) I $D(^XMB(3.8,X,3)) W:^(3)=D0 ?33," (Organizer)"
40 W ?47,$S((J="PR"):"(Private)",1:"(Public)")
41 Q
42CON R !!,"Press RETURN to Continue - No Exit Here: ",AAQX:20
43 Q
44CONX R !!,"Press RETURN to Continue or '^' to Exit: ",AAQX:20 Q:AAQX="^"
45 Q
46HDR W @IOF S $X=1,$Y=1 W "User Inquiry ",%Y," (UCI: ",AAQUCI,")",!!
47 W $P(^VA(200,D0,0),U)," (#",D0,")",!! Q
48EXIT ;
49 ; Added the following for data collection by ADPACs.-05-23-2001/JFW
50 S AAQSPLR=$P($G(^VA(200,D0,"SPL")),U,1) ; -05-23-2001/JFW
51 I AAQSPLR="y"!(AAQSPLR="Y") S AAQSPLR="Yes" ;-05-23-2001/JFW
52 S:AAQSPLR'="Yes" AAQSPLR="No"
53 W !!,"Allowed to Use Spooler : ",AAQSPLR,! ;-05-23-2001/JFW
54 I IOST["P-" W @IOF
55 K %,%1,%2,%Y,AAQX,AAQUCI,I,J,X,XQI,XQLN,XQN,XQUSER,XQV,Y,ZTQUEUED
56 K AAQSPLR ; -05-23-2001/JFW
57 ; D0 cannot be killed here or FileMan will error out when
58 ; returning to the Print Template [XUSERINQFGO].
59 Q
Note: See TracBrowser for help on using the repository browser.