source: FOIAVistA/trunk/r/NOIS-FSC/FSCEU.m@ 1397

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

initial load of FOIAVistA 6/30/08 version

File size: 2.6 KB
Line 
1FSCEU ;SLC/STAFF-NOIS Edit Utilities ;9/6/98 20:39
2 ;;1.1;NOIS;;Sep 06, 1998
3 ;
4UPDATE(CALL) ; from FSCEN, FSCLMPE1, FSCLMPEA, FSCLMPES
5 D UPDATE^FSCAUDIT(CALL)
6 D UPDATE^FSCTASK(CALL)
7 D BUILD(CALL)
8 Q
9 ;
10BUILD(CALL) ; from FSCELL, FSCLMPE1
11 N LINE,SHORT
12 D BUILD^FSCFORM(FSCCNT,CALL,.FSCSTYLE,0,"FSC MULT ")
13 S SHORT=$$SHORT^FSCGETS(CALL,FSCCNT),LINE=+$O(^TMP("FSC LIST CALLS",$J,"IDX",FSCCNT,0))
14 S ^TMP("FSC LIST CALLS",$J,LINE,0)=SHORT
15 S $P(^TMP("FSC MULT",$J,FSCCNT),U,2)=SHORT
16 S VALMHDR(1)=SHORT
17 I $L($G(FSCLNAME)),FSCLNAME'["(MODIFIED)" S FSCLNAME=FSCLNAME_" (MODIFIED)"
18 S FSCEDIT=1
19 S VALMCNT=+$P(@VALMAR,U,2),VALMBG=1
20 Q
21 ;
22WP(NAME,PROMPT) ; from FSCEC, FSCEN, FSCNMS
23 N CNT,DIC,DWLW,DWPK,LINE,TEXTNUM K DIC
24 K ^TMP("FSC TEXT",$J,NAME)
25 L +^FSCD("TEXT",0):30 I '$T D SOMEONE^FSCLMPE1 Q
26 S TEXTNUM=$P(^FSCD("TEXT",0),U,4)+1
27 F Q:'$D(^FSCD("TEXT",TEXTNUM,0)) S TEXTNUM=TEXTNUM+1
28 S $P(^FSCD("TEXT",0),U,3)=TEXTNUM,$P(^(0),U,4)=$P(^(0),U,4)+1
29 S ^FSCD("TEXT",TEXTNUM,0)=TEXTNUM
30 L -^FSCD("TEXT",0)
31 I $L($G(PROMPT)) W !,PROMPT
32 S DIC="^FSCD(""TEXT"","_TEXTNUM_",1,",DWLW=80,DWPK=1 D EN^DIWE K DIC
33 S (CNT,LINE)=0 F S LINE=$O(^FSCD("TEXT",TEXTNUM,1,LINE)) Q:LINE<1 S ^TMP("FSC TEXT",$J,NAME,LINE,0)=^(LINE,0),CNT=CNT+1
34 I $D(^TMP("FSC TEXT",$J,NAME)) S ^(NAME)=CNT
35 L +^FSCD("TEXT",0):30 I '$T D SOMEONE^FSCLMPE1 Q
36 K ^FSCD("TEXT",TEXTNUM)
37 S $P(^(0),U,4)=$P(^FSCD("TEXT",0),U,4)-1
38 L -^FSCD("TEXT",0)
39 Q
40 ;
41EDITWP(ARRAY,PROMPT) ; from FSCEC, FSCEN, FSCMU1, FSCNMS
42 ; only ^TMP("FSC ... globals can be edited
43 I $E(ARRAY)=U,$E(ARRAY,1,9)'="^TMP(""FSC" Q
44 N CNT,DIC,DWLW,DWPK,LINE,TEXT,TEXTNUM K DIC
45 L +^FSCD("TEXT",0):30 I '$T D SOMEONE^FSCLMPE1 Q
46 S TEXTNUM=$P(^FSCD("TEXT",0),U,4)+1
47 F Q:'$D(^FSCD("TEXT",TEXTNUM,0)) S TEXTNUM=TEXTNUM+1
48 S $P(^FSCD("TEXT",0),U,3)=TEXTNUM,$P(^(0),U,4)=$P(^(0),U,4)+1
49 S ^FSCD("TEXT",TEXTNUM,0)=TEXTNUM
50 L -^FSCD("TEXT",0)
51 I $L($G(PROMPT)) W !,PROMPT
52 S (CNT,LINE)=0 F S LINE=$O(@ARRAY@(LINE)) Q:LINE<1 D
53 .S TEXT=@ARRAY@(LINE,0),CNT=CNT+1
54 .S ^FSCD("TEXT",TEXTNUM,1,CNT,0)=TEXT
55 I CNT S ^FSCD("TEXT",TEXTNUM,1,0)="^^"_CNT_U_CNT_U_$G(DT)_U
56 K @ARRAY
57 S DIC="^FSCD(""TEXT"","_TEXTNUM_",1,",DWLW=80,DWPK=1 D EN^DIWE K DIC
58 S (CNT,LINE)=0 F S LINE=$O(^FSCD("TEXT",TEXTNUM,1,LINE)) Q:LINE<1 S @ARRAY@(LINE,0)=^(LINE,0),CNT=CNT+1
59 I $O(@ARRAY@(0)) S @ARRAY=CNT
60 L +^FSCD("TEXT",0):30 I '$T D SOMEONE^FSCLMPE1 Q
61 K ^FSCD("TEXT",TEXTNUM)
62 S $P(^(0),U,4)=$P(^FSCD("TEXT",0),U,4)-1
63 L -^FSCD("TEXT",0)
64 Q
65 ;
66SUB(CALL) ; $$(call#) -> @2 or @1 if subcomponents should be asked
67 N MOD
68 S MOD=+$P($G(^FSCD("CALL",CALL,0)),U,8)
69 I 'MOD Q "@2"
70 I $O(^FSC("SUB","AC",+$P($G(^FSC("MOD",MOD,0)),U,8),0)) Q "@1"
71 Q "@2"
Note: See TracBrowser for help on using the repository browser.