ORY38 ;SLC/MKB-Postinit for patch OR*3*38 ;11/20/98 09:24
;;3.0;ORDER ENTRY/RESULTS REPORTING;**38**;Dec 17, 1997
;
EN ; -- Clear default value for SC prompt in Outpt Med quick orders
;
N ORDLG,OR0,ORSC,DA,DIK
S ORSC=+$O(^ORD(101.41,"AB","OR GTX SERVICE CONNECTED",0)) Q:ORSC'>0
S ORDG=+$O(^ORD(100.98,"B","O RX",0)) Q:ORDG'>0 S ORDLG=0
W !!,"Clearing SC default from Outpatient Medication quick orders ..."
F S ORDLG=$O(^ORD(101.41,ORDLG)) Q:ORDLG'>0 S OR0=$G(^(ORDLG,0)) I $P(OR0,U,4)="Q",$P(OR0,U,5)=ORDG D
. S DA=$O(^ORD(101.41,ORDLG,6,"D",ORSC,0)),DA(1)=ORDLG
. I DA>0 S DIK="^ORD(101.41,"_ORDLG_",6," D ^DIK
W " done."
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORY38 657 printed Dec 13, 2024@02:41:38 Page 2
ORY38 ;SLC/MKB-Postinit for patch OR*3*38 ;11/20/98 09:24
+1 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**38**;Dec 17, 1997
+2 ;
EN ; -- Clear default value for SC prompt in Outpt Med quick orders
+1 ;
+2 NEW ORDLG,OR0,ORSC,DA,DIK
+3 SET ORSC=+$ORDER(^ORD(101.41,"AB","OR GTX SERVICE CONNECTED",0))
if ORSC'>0
QUIT
+4 SET ORDG=+$ORDER(^ORD(100.98,"B","O RX",0))
if ORDG'>0
QUIT
SET ORDLG=0
+5 WRITE !!,"Clearing SC default from Outpatient Medication quick orders ..."
+6 FOR
SET ORDLG=$ORDER(^ORD(101.41,ORDLG))
if ORDLG'>0
QUIT
SET OR0=$GET(^(ORDLG,0))
IF $PIECE(OR0,U,4)="Q"
IF $PIECE(OR0,U,5)=ORDG
Begin DoDot:1
+7 SET DA=$ORDER(^ORD(101.41,ORDLG,6,"D",ORSC,0))
SET DA(1)=ORDLG
+8 IF DA>0
SET DIK="^ORD(101.41,"_ORDLG_",6,"
DO ^DIK
End DoDot:1
+9 WRITE " done."
+10 QUIT