source: FOIAVistA/trunk/r/SURGERY-SR/SRO1L1.m@ 868

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

initial load of FOIAVistA 6/30/08 version

File size: 3.2 KB
Line 
1SRO1L1 ;BIR/ADM - UPDATE 1-LINER CASE, CONTINUED ;02/14/07
2 ;;3.0; Surgery ;**86,88,100,129,142,153,160**;24 Jun 93;Build 7
3 S SRSOUT=0,SRSUPCPT=2 D NCODE^SROAUTL
4 N SRLCK,SRCSTAT S SRLCK=$$LOCK^SROUTL(SRTN) I 'SRLCK Q
5 D SRA^SROES
6EDIT S SRA=$G(^SRF(SRTN,"RA")) I $P(SRA,"^",2)="N",$P(SRA,"^",6)="N",$P(SRA,"^",7)'="" D ^SROAEX,END Q
7 S SRCSTAT=">> Coding "_$S($P($G(^SRO(136,SRTN,10)),"^"):"",1:"Not ")_"Complete <<"
8 S SRR=0 D TSTAT,HDR^SROAUTL D TECH^SROPRIN
9 S X=$P(^SRF(SRTN,"OP"),"^",2) I X S Y=$P($$CPT^ICPTCOD(X),"^",2) D SSPRIN^SROCPT S SRCPT=Y
10 S SRQ=0,SRDR=".011;.04;.035;.166;1.09;1.13"
11 S SRAO(1)="In/Out-Patient Status^.011",SRAO(2)="Major or Minor^.03",SRAO(2)="Surgical Specialty^.04",SRAO(3)="Surgical Priority^.035",SRAO(4)="Attending Code^.166"
12 S SRAO(5)="ASA Class^1.13",SRAO(6)="Wound Classification^1.09",SRAO(7)="Anesthesia Technique^.37",SRAO(8)="CPT Codes (view only)^",SRAO(9)="Other Procedures^.42"
13 K DA,DIC,DIQ,DR,SRY S DIC="^SRF(",DA=SRTN,DIQ="SRY",DIQ(0)="E",DR=SRDR D EN^DIQ1 K DA,DIC,DIQ,DR
14 S SRY(130,SRTN,.37,"E")=SRTECH,SRY(130,SRTN,.42,"E")=$S($O(^SRF(SRTN,13,0)):"***INFORMATION ENTERED***",1:"***NONE ENTERED***"),SRY(130,SRTN,27,"E")=SRCPT
15 F I=1:1:9 W !,$J(I,2)_". "_$P(SRAO(I),"^")_":" D
16 .I I=8 D PROC Q
17 .S SREXT(1)=SRY(130,SRTN,$P(SRAO(I),"^",2),"E") I $L(SREXT(1))>48 D
18 ..N I,J,X,Y S X=SREXT(1) F I=0:1:47 S J=48-I,Y=$E(X,J) I Y=" " S SREXT(1)=$E(X,1,J-1),SREXT(2)=$E(X,J+1,$L(X)) Q
19 .W ?32,SREXT(1) W:$D(SREXT(2)) !,?32,SREXT(2) K SREXT
20 W !! F I=1:1:80 W "-"
21 S SRX=9 D SEL
22 K DA,DIK S DIK="^SRF(",DIK(1)=".232^AQ",DA=SRTN D EN1^DIK K DA,DIK
23 G:SRR=1 EDIT
24END D EXIT^SROES D:$G(SRLCK) UNLOCK^SROUTL(SRTN)
25 Q
26PROC N I,SRPROC,SRL S SRL=48 D CPTS^SROAUTL0
27 F I=1:1 Q:'$D(SRPROC(I)) W:I=1 ?32,SRPROC(I) W:I'=1 !,?32,SRPROC(I)
28 Q
29SEL W !!,"Select number of item to edit: " R X:DTIME I '$T!(X["^") S SRSOUT=1 Q
30 Q:X="" S:X="a" X="A" I '$D(SRAO(X)),(X'?.N1":".N),(X'="A") D HELP S SRR=1 Q
31 I X?1.2N1":"1.2N S Y=$P(X,":"),Z=$P(X,":",2) I Y<1!(Z>SRX)!(Y>Z) D HELP S SRR=1 Q
32 I X="A" S X="1:"_SRX
33 I X?1.2N1":"1.2N D RANGE S SRR=1 Q
34 I $D(SRAO(X)) S EMILY=X W !! D ONE S SRR=1
35 Q
36HELP W @IOF,!!!!,"Enter the number or range of numbers you want to edit. Examples of proper"
37 W !,"responses are listed below.",!!,"1. Enter 'A' to update all items."
38 W !!,"2. Enter a number (1-"_SRX_") to update an individual item. (For example,"
39 W !," enter '1' to update "_$P(SRAO(1),"^")_")"
40 W !!,"3. Enter a range of numbers (1-"_SRX_") separated by a ':' to enter a range"
41 W !," of items. (For example, enter '1:4' to update items 1, 2, 3 and 4.)",!
42PRESS W ! K DIR S DIR(0)="E" D ^DIR K DIR I $D(DTOUT)!$D(DUOUT) S SRSOUT=1
43 Q
44RANGE ; range of numbers
45 S SHEMP=$P(X,":"),CURLEY=$P(X,":",2) F EMILY=SHEMP:1:CURLEY Q:SRSOUT D ONE
46 Q
47ONE ; edit one item
48 I EMILY=7 D UPANES Q
49 I EMILY=8 D DISP^SROAUTL0 Q
50 I EMILY=9 D ^SROTHER Q
51 K DR,DIE S DA=SRTN,DR=$P(SRAO(EMILY),"^",2)_"T",DIE=130 D ^DIE K DR I $D(Y) S SRSOUT=1
52 Q
53UPANES K DR,DIE,DA S DA=SRTN,DR=.37,DR(2,130.06)=".01T;.05T;42T",DIE=130 D ^DIE K DR
54 Q
55TSTAT ; transmission status
56 N SR905 S SR905=$P($G(^SRF(SRTN,.4)),"^",2)
57 S SRHDR(.5)="Transmission Status: "_$S(SR905="T":"TRANSMITTED",SR905="R":"QUEUED TO TRANSMIT",1:"NOT QUEUED")
58 Q
Note: See TracBrowser for help on using the repository browser.