source: FOIAVistA/tag/r/SURGERY-SR/SROACAR.m@ 1093

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

WorldVistAEHR overlayed on FOIAVistA

File size: 2.2 KB
Line 
1SROACAR ;BIR/MAM - OPEATIVE DATA ;03/29/06
2 ;;3.0; Surgery ;**38,71,93,95,100,125,142,153**;24 Jun 93;Build 11
3 I '$D(SRTN) W !!,"A Surgery Risk Assessment must be selected prior to using this option.",!!,"Press <RET> to continue " R X:DTIME G END
4 S SRACLR=0,SRSOUT=0,SRSUPCPT=1 D ^SROAUTL
5START D:SRACLR RET G:SRSOUT END S SRACLR=0 K SRA,SRAO D ^SROACR1
6ASK W !,"Select Operative Information to Edit: " R X:DTIME I '$T!("^"[X) G END
7 S:X="a" X="A" I '$D(SRAO(X)),(X'?.N1":".N),(X'="A") D HELP G:SRSOUT END G START
8 I X="A" S X="1:22"
9 I X?.N1":".N S Y=$E(X),Z=$P(X,":",2) I Y<1!(Z>22)!(Y>Z) D HELP G:SRSOUT END G START
10 D HDR^SROAUTL
11 I X?.N1":".N D RANGE G START
12 I $D(SRAO(X)),+X=X S EMILY=X D G START
13 .I $$LOCK^SROUTL(SRTN) W ! D ONE,UNLOCK^SROUTL(SRTN)
14 I $D(SRAO(X)) W ! S EMILY=X D G START
15 .I $$LOCK^SROUTL(SRTN) D ONE,UNLOCK^SROUTL(SRTN)
16END I 'SRSOUT D ^SROACR2
17 W @IOF D ^SRSKILL
18 Q
19HELP W @IOF,!!!!,"Enter the number or range of numbers you want to edit. Examples of proper",!,"responses are listed below."
20 W !!,"1. Enter 'A' to update all information.",!!,"2. Enter a number (1-22) to update the information in that field. (For",!," example, enter '9' to update Valve Repair.)"
21 W !!,"3. Enter a range of numbers (1-22) separated by a ':' to enter a range of",!," information. (For example, enter '6:8' to enter Aortic Valve",!," Replacement, Mitral Valve Replacement, and Tricuspid Valve Replacement.)"
22 D RET
23 Q
24RANGE ; range of numbers
25 I $$LOCK^SROUTL(SRTN) D D UNLOCK^SROUTL(SRTN)
26 .W ! S SHEMP=$P(X,":"),CURLEY=$P(X,":",2) F EMILY=SHEMP:1:CURLEY Q:SRSOUT D ONE
27 Q
28ONE ; edit one item
29 ;I EMILY=16 D MIS^SROACR1 Q
30 I EMILY=22 D OPS Q
31 K DR,DIE S DA=SRTN,DR=$P(SRAO(EMILY),"^",2)_"T",DIE=130 D ^DIE K DR I $D(Y) S SRSOUT=1
32 I 'SRSOUT,EMILY=12!(EMILY=13) D OK
33 Q
34OK N SRISCH,SRCPB S X=$G(^SRF(SRTN,206)),SRISCH=$P(X,"^",36),SRCPB=$P(X,"^",37)
35 I SRISCH,SRCPB,SRISCH>SRCPB W !!," *** NOTE: Ischemic Time is greater than CPB Time!! Please check. ***",! D RET W !
36 Q
37RET Q:SRSOUT W ! K DIR S DIR(0)="E" D ^DIR K DIR I $D(DTOUT)!$D(DUOUT) S SRSOUT=1
38 Q
39OPS ; enter other cardiac procedures, specify
40 S DIE=130,DA=SRTN,DR="502T" D ^DIE K DR Q:$D(Y)
41 I X'="Y" K ^SRF(SRTN,209.1) Q
42 S DIE=130,DA=SRTN,DR="484T" D ^DIE K DR
43 Q
Note: See TracBrowser for help on using the repository browser.