source: FOIAVistA/trunk/r/HEALTH_LEVEL_SEVEN-HL/HLCSREQ.m@ 1742

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

initial load of FOIAVistA 6/30/08 version

File size: 1.8 KB
Line 
1HLCSREQ ;ALB/MFK - HL7 MESSAGE REQUEUER SCREEN # 3 ;02/16/2000 15:58
2 ;;1.6;HEALTH LEVEL SEVEN;**61**;Oct 13, 1995
3EN ; -- main entry point
4 D EN^VALM("HL MESSAGE REQUEUER - 1")
5 Q
6 ;
7HDR ; -- header code
8 N TMP
9 S TMP="Known Logical Links"
10 S VALMHDR(1)=$$SETSTR^VALM1(TMP,"",(40-($L(TMP)\2)),$L(TMP))
11 Q
12 ;
13INIT ; -- init variables and list array
14 ; -- build array of indices and queues
15 N LLE,X,LINEENT,NAME,SIZE,HLPOINT,HLSENT,ENTRY,HLSTAT,X
16 S LLE=0,X=0
17 F S LLE=$O(^HLCS(870,LLE)) Q:(LLE="") D
18 .Q:('$D(^HLCS(870,LLE,2,0)))
19 .S LINEENT=""
20 .S SIZE=$P(^HLCS(870,LLE,2,0),"^",4)
21 .S:(SIZE="") SIZE=0
22 .S HLPOINT="",HLSENT=0
23 .F S HLPOINT=$O(^HLCS(870,LLE,2,"B",HLPOINT)) Q:(HLPOINT="") D
24 ..S ENTRY=$O(^HLCS(870,LLE,2,"B",HLPOINT,""))
25 ..Q:'ENTRY
26 ..Q:'$D(^HLCS(870,LLE,2,ENTRY,0))
27 ..S HLSTAT=$P($G(^HLCS(870,LLE,2,ENTRY,0)),"^",2)
28 ..S HLSENT=HLSENT+($S(HLSTAT="P":0,1:1))
29 .S NAME=$P(^HLCS(870,LLE,0),"^",1)
30 .S X=X+1
31 .S LINEENT=$$SETFLD^VALM1(X,LINEENT,"NUMBER")
32 .S LINEENT=$$SETFLD^VALM1(NAME,LINEENT,"QUEUE")
33 .S LINEENT=$$SETFLD^VALM1(SIZE,LINEENT,"SIZE")
34 .S LINEENT=$$SETFLD^VALM1(HLSENT,LINEENT,"SENT")
35 .S LINEENT=$$SETFLD^VALM1(SIZE-HLSENT,LINEENT,"PENDING")
36 .;D SET^VALM10(X,LINEENT)
37 .S ^TMP("HL",$J,X,0)=LINEENT
38 .S ^TMP("HL",$J,"B",X,LLE)=""
39 .S ^TMP("HL",$J,"IDX",X,X)=""
40 I (X=0) S ^TMP("HL",$J,1,0)="** No logical links have been defined **"
41 S VALMCNT=X
42 Q
43 ;
44HELP ; -- help code
45 S X="?" D DISP^XQORM1 W !!
46 Q
47 ;
48EXIT ; -- exit code
49 K ^TMP("HL",$J)
50 Q
51 ;
52EXPND ; -- expand code
53 N LOOP,MATCH,VALMY
54 S LOOP=""
55 D EN^VALM2(XQORNOD(0))
56 ; -- find out what the user selected
57 I ('$D(VALMY)) S VALMBCK="" Q
58 F LOOP=$O(VALMY(LOOP)) Q:(LOOP="") D
59 .S MATCH=$O(^TMP("HL",$J,"B",LOOP,""))
60 ; -- call entry to show individual messages
61 D EN^HLCSRES(MATCH)
62 ; -- re-index files in case entries were re-queued
63 D INIT
64 Q
65 ;
Note: See TracBrowser for help on using the repository browser.