source: FOIAVistA/trunk/r/DIETETICS-FH/FHADR3.m@ 711

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

initial load of FOIAVistA 6/30/08 version

File size: 911 bytes
Line 
1FHADR3 ; HISC/NCA - Facility Workload ;11/3/94 15:37
2 ;;5.5;DIETETICS;;Jan 28, 2005
3EN1 ; Enter/Edit Outpatients Visits
4 D QR^FHADR1 G:'PRE KIL
5 S OLD=$S($E(PRE,5)=1:$E(PRE,1,3)-1_"0400",1:$E(PRE,1,5)-1_"00")
6 S (Z,ZZZ)=""
7 K DIC,DIE W ! S DIE="^FH(117.3,",DA=PRE
8 S DR="21;23;S:X'="""" ZZZ=X"
9 L +^FH(117.3,PRE,0):0 I '$T W !?5,"Another user is editing the entry." G KIL
10 D ^DIE K DR
11 I ZZZ,$D(^FH(117.3,OLD,"CLIN",0)) D
12 .I '$D(^FH(117.3,PRE,"CLIN",0)) D
13 ..S ^FH(117.3,PRE,"CLIN",0)="^117.325^^",NDE=$G(^FH(117.3,PRE,"CLIN",0)),NDE=$P(NDE,"^",4)
14 ..F LP=0:0 S LP=$O(^FH(117.3,OLD,"CLIN",LP)) Q:LP<1 S Z1=$G(^(LP,0)) D
15 ...I Z1'="",'$D(^FH(117.3,PRE,"CLIN",LP,0)) S ^(0)=$P(Z1,"^",1),^FH(117.3,PRE,"CLIN","B",$P(Z1,"^",1),LP)="",NDE=NDE+1,$P(^FH(117.3,PRE,"CLIN",0),"^",3,4)=LP_"^"_NDE Q
16 ..Q
17 .Q
18 S DR="I 'ZZZ S Y="""";25"
19 S DR(2,117.325)=".01:1"
20 D ^DIE L -^FH(117.3,PRE,0) K DIE,DR
21KIL G KILL^XUSCLEAN
Note: See TracBrowser for help on using the repository browser.