source: FOIAVistA/trunk/r/PATIENT_DATA_EXCHANGE-VAQ/VAQADM51.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: 2.1 KB
Line 
1VAQADM51 ;ALB/JRP - GENERATE PDX TRANSMISSIONS;10-MAR-93 [ 09/26/96 2:29 PM ]
2 ;;1.5;PATIENT DATA EXCHANGE;**22**;NOV 17, 1993
3START ;START RESPONSE TIME MONITORING (TIME TO BUILD/SEND COMPLETE TRANSMISSION)
4 I ($D(XRTL)) D T0^%ZOSV
5 Q
6 ;
7STOP ;STOP RESPONSE TIME MONITORING
8 I ($D(XRT0)) S XRTN=$T(+0) D T1^%ZOSV K XRTN,XRT0
9 Q
10 ;
11XMIT15 ;GERNERATE & SEND VERSION 1.5 MESSAGES (CONTINUATION FOR VAQADM50)
12 ; DECLARATIONS DONE IN GENXMIT^VAQADM50
13 S DOMAIN=""
14 F S DOMAIN=$O(@ARRAY1@(DOMAIN)) Q:(DOMAIN="") D START D D STOP
15 .;EXTRACT INFORMATION FOR ALL TRANSACTIONS
16 .K @ARRAY5
17 .S TRANS=""
18 .F S TRANS=$O(@ARRAY1@(DOMAIN,TRANS)) Q:(TRANS="") D
19 ..;PLACE TRANSACTION POINTER IN ARRAY5
20 ..S TMPARR=$P(ARRAY5,")",1)_","_$C(34)_TRANS_$C(34)_")"
21 ..;EXTRACT INFO
22 ..S TMP=$$EXTRACT^VAQDBI(TRANS,TMPARR)
23 ..I (TMP) D
24 ...S @ARRAY3@(TRANS,0)="Error occurred while extracting information"
25 ...S @ARRAY3@(TRANS,1)=$P(TMP,"^",2)
26 ...K @ARRAY1@(DOMAIN,TRANS)
27 ...K @TMPARR
28 .;CREATE STUB MESSAGE
29 .S TMP="PDX (V1.5) TRANSMISSION FROM "_SITE
30 .S XMZ=$$MAKESTUB^VAQCON1(TMP,"PDX")
31 .I (XMZ<1) D Q
32 ..S X=$$KILLSTUB^VAQCON1(XMZ)
33 ..S TRANS=""
34 ..F S TRANS=$O(@ARRAY1@(DOMAIN,TRANS)) Q:(TRANS="") D
35 ...S @ARRAY3@(TRANS,0)="Error occurred while building transmission"
36 ...S @ARRAY3@(TRANS,1)=$P(XMZ,"^",2)
37 .;PLACE DOMAIN IN ARRAY1
38 .S TMPARR=$P(ARRAY1,")",1)_","_$C(34)_DOMAIN_$C(34)_")"
39 .;PLACE TRANSMISSION IN MESSAGE
40 .S TMP=$$XMIT^VAQCON(TMPARR,ARRAY5,XMZ,"",1)
41 .I (TMP<0) D Q
42 ..S X=$$KILLSTUB^VAQCON1(XMZ)
43 ..S TRANS=""
44 ..F S TRANS=$O(@TMPARR@(TRANS)) Q:(TRANS="") D
45 ...S @ARRAY3@(TRANS,0)="Error occurred while building transmission"
46 ...S @ARRAY3@(TRANS,1)=$P(TMP,"^",2)
47 .;SET ZERO NODE
48 .S TMP=$$SETZERO^VAQCON1(XMZ,TMP)
49 .I (TMP) D Q
50 ..S X=$$KILLSTUB^VAQCON1(XMZ)
51 ..S TRANS=""
52 ..F S TRANS=$O(@TMPARR@(TRANS)) Q:(TRANS="") D
53 ...S @ARRAY3@(TRANS,0)="Error occurred while building transmission"
54 ...S @ARRAY3@(TRANS,1)=$P(TMP,"^",2)
55 .;SEND TRANSMISSION
56 .S TMP=$G(@ARRAY2@(DOMAIN))
57 .S:(TMP="") TMP=DOMAIN
58 .S X="S.VAQ-PDX-SERVER"_"@"_TMP
59 .S XMY(X)=""
60 .S XMDUN="Patient Data eXchange"
61 .D ENT1^XMD
62 Q
Note: See TracBrowser for help on using the repository browser.