- SROUTL1 ;BIR/ADM - UTILITY ROUTINE ;10/05/04
- ;;3.0; Surgery ;**134**;24 Jun 93
- ATT ; check for attend surg when completing case
- I $P($G(^SRF(DA,.1)),"^",13) Q
- D ASK I '$P($G(^SRF(DA,.1)),"^",13) K X
- Q
- ASK N SREQ,X,Y
- D EN^DDIOL("The Attending Surgeon field has not been entered. You must first enter the",,"!!")
- D EN^DDIOL("Attending Surgeon before the computer will accept entry of the Time Patient",,"!")
- D EN^DDIOL("Out of O.R.",,"!")
- K DIR S DIR("A",1)="",DIR("A")="Attending Surgeon",DIR(0)="130,.164" D ^DIR K DIR I $D(DTOUT)!$D(DUOUT) Q
- I +Y S SREQ(130,DA_",",.164)=+Y D FILE^DIE("","SREQ","^TMP(""SR"",$J)")
- Q
- ATTP ; check for attend provider when completing non-OR procedure
- I $P($G(^SRF(DA,"NON")),"^",7) Q
- D ASKP I '$P($G(^SRF(DA,"NON")),"^",7) K X
- Q
- ASKP N SREQ,X,Y
- D EN^DDIOL("The Attending Provider field has not been entered. You must first enter",,"!!")
- D EN^DDIOL("the Attending Provider before the computer will accept entry of the Time",,"!")
- D EN^DDIOL("Procedure Ended.",,"!")
- K DIR S DIR("A",1)="",DIR("A")="Attending Provider",DIR(0)="130,124" D ^DIR K DIR I $D(DTOUT)!$D(DUOUT) Q
- I +Y S SREQ(130,DA_",",124)=+Y D FILE^DIE("","SREQ","^TMP(""SR"",$J)")
- Q
- SROUTL1 ;BIR/ADM - UTILITY ROUTINE ;10/05/04
- +1 ;;3.0; Surgery ;**134**;24 Jun 93
- ATT ; check for attend surg when completing case
- +1 IF $PIECE($GET(^SRF(DA,.1)),"^",13)
- QUIT
- +2 DO ASK
- IF '$PIECE($GET(^SRF(DA,.1)),"^",13)
- KILL X
- +3 QUIT
- ASK NEW SREQ,X,Y
- +1 DO EN^DDIOL("The Attending Surgeon field has not been entered. You must first enter the",,"!!")
- +2 DO EN^DDIOL("Attending Surgeon before the computer will accept entry of the Time Patient",,"!")
- +3 DO EN^DDIOL("Out of O.R.",,"!")
- +4 KILL DIR
- SET DIR("A",1)=""
- SET DIR("A")="Attending Surgeon"
- SET DIR(0)="130,.164"
- DO ^DIR
- KILL DIR
- IF $DATA(DTOUT)!$DATA(DUOUT)
- QUIT
- +5 IF +Y
- SET SREQ(130,DA_",",.164)=+Y
- DO FILE^DIE("","SREQ","^TMP(""SR"",$J)")
- +6 QUIT
- ATTP ; check for attend provider when completing non-OR procedure
- +1 IF $PIECE($GET(^SRF(DA,"NON")),"^",7)
- QUIT
- +2 DO ASKP
- IF '$PIECE($GET(^SRF(DA,"NON")),"^",7)
- KILL X
- +3 QUIT
- ASKP NEW SREQ,X,Y
- +1 DO EN^DDIOL("The Attending Provider field has not been entered. You must first enter",,"!!")
- +2 DO EN^DDIOL("the Attending Provider before the computer will accept entry of the Time",,"!")
- +3 DO EN^DDIOL("Procedure Ended.",,"!")
- +4 KILL DIR
- SET DIR("A",1)=""
- SET DIR("A")="Attending Provider"
- SET DIR(0)="130,124"
- DO ^DIR
- KILL DIR
- IF $DATA(DTOUT)!$DATA(DUOUT)
- QUIT
- +5 IF +Y
- SET SREQ(130,DA_",",124)=+Y
- DO FILE^DIE("","SREQ","^TMP(""SR"",$J)")
- +6 QUIT