AMERPREF ;GDIT/HS/BEE - AMER SITE PREFERENCES ; 07 Oct 2013 11:33 AM
;;3.0;ER VISIT SYSTEM;**10**;MAR 03, 2009;Build 23
;
Q
;
EN ;
;
NEW DA,DIC,DIE,DLAYGO,DR,FAC,X,Y
;
;First Select the facility
FAC W !!
S DIC="^AMER(2.5,",DIC(0)="AEMQL"
S DLAYGO=9002318.2 D ^DIC S FAC=+Y
I FAC=-1 Q
;
;Edit the fields
S DIE="^AMER(2.5,",DA=FAC,DR="[AMER ER FACILITY]"
D ^DIE
;
G FAC
;
Q
;
;SCREEN for 9009082.58/.01 field
SCREEN(Y) I '$G(Y) Q 0
I $$GET1^DIQ(9009083,Y_",",1,"E")="CLINIC TYPE" Q 1
Q 0
AMERPREF ;GDIT/HS/BEE - AMER SITE PREFERENCES ; 07 Oct 2013 11:33 AM
+1 ;;3.0;ER VISIT SYSTEM;**10**;MAR 03, 2009;Build 23
+2 ;
+3 QUIT
+4 ;
EN ;
+1 ;
+2 NEW DA,DIC,DIE,DLAYGO,DR,FAC,X,Y
+3 ;
+4 ;First Select the facility
FAC WRITE !!
+1 SET DIC="^AMER(2.5,"
SET DIC(0)="AEMQL"
+2 SET DLAYGO=9002318.2
DO ^DIC
SET FAC=+Y
+3 IF FAC=-1
QUIT
+4 ;
+5 ;Edit the fields
+6 SET DIE="^AMER(2.5,"
SET DA=FAC
SET DR="[AMER ER FACILITY]"
+7 DO ^DIE
+8 ;
+9 GOTO FAC
+10 ;
+11 QUIT
+12 ;
+13 ;SCREEN for 9009082.58/.01 field
SCREEN(Y) IF '$GET(Y)
QUIT 0
+1 IF $$GET1^DIQ(9009083,Y_",",1,"E")="CLINIC TYPE"
QUIT 1
+2 QUIT 0