source: WorldVistAEHR/trunk/r/SURGERY-SR/SROPRIN.m@ 1259

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

initial load of WorldVistAEHR

File size: 863 bytes
Line 
1SROPRIN ;B'HAM ISC/MAM - PRINCIPAL ANESTHESIA TECHNIQUE; 5 Jan 1989 8:31 AM
2 ;;3.0; Surgery ;**22,26,32,38**;24 Jun 93
3PRIN I $P(^SRF(SRTN,6,SRT,0),"^",3)="Y" S SRTECH=$P(^SRF(SRTN,6,SRT,0),"^"),SRZ=1 Q
4 I SRT=$O(^SRF(SRTN,6,0)),'$O(^SRF(SRTN,6,SRT)) S SRTECH=$P(^SRF(SRTN,6,SRT,0),"^"),SRZ=1
5 Q
6CHECK ; check for already existing Principal Technique
7 Q:$E(X)="N"
8 S (SRPT,SRT)=0 F S SRT=$O(^SRF(DA(1),6,SRT)) Q:'SRT!SRPT I SRT'=DA,$P(^(SRT,0),"^",3)="Y" W *7,!!,"An anesthesia technique has already been selected as 'PRINCIPAL' technique.",! S SRPT=1 K X
9 K SRPT,SRT
10 Q
11TECH ; entry from reports to get principal technique
12 K SRTECH,SRZ S SRT=0 F S SRT=$O(^SRF(SRTN,6,SRT)) Q:'SRT D PRIN Q:$D(SRZ)
13 I $D(SRTECH) D ANES
14 I '$D(SRTECH) S SRTECH="NOT ENTERED"
15 Q
16ANES ; anesthesia technique
17 N C
18 S Y=SRTECH,C=$P(^DD(130.06,.01,0),"^",2) D Y^DIQ S SRTECH=Y
19 Q
Note: See TracBrowser for help on using the repository browser.