ORPR07A ; slc/dcm - WWW.PrintCodes.com
;;3.0;ORDER ENTRY/RESULTS REPORTING;**69**;Dec 17, 1997
LBSCREEN(ORIFN,OACTION,ORRACT,ACTION,TYPE) ;Lab Label/Requisition Screen
;ORIFN=ifn of order ^OR(100,ORIFN)
;OACTION=ifn of order action ^OR(100,ORIFN,8,OACTION)
;ORRACT=1 if request is a reprint
;ACTION=a string of action codes to allow printing (NW DC HD RL)
;TYPE=a string of lab collection types to allow printing (LC IC WC SP)
;Example of screen allowing print of New order with collection types LC or IC:
; $$LBSCREEN(ifn,1,,"NW","LCIC")
N ACT,X3
Q:'$G(ORIFN) 0
S X3=$P($G(^OR(100,ORIFN,3)),"^",3)
I X3=1!(X3=2)!(X3=13)!(X3=14) Q 0
Q:$G(ORRACT) 1
Q:'$G(OACTION) 0
Q:'$D(^OR(100,ORIFN,8,+OACTION,0)) 0 S ACT=$P(^(0),"^",2)
I $L($G(ACTION)),ACTION[ACT,TYPE[$$VALUE^ORCSAVE2(ORIFN,"COLLECT") Q 1
Q 0
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORPR07A 840 printed Dec 13, 2024@02:32:42 Page 2
ORPR07A ; slc/dcm - WWW.PrintCodes.com
+1 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**69**;Dec 17, 1997
LBSCREEN(ORIFN,OACTION,ORRACT,ACTION,TYPE) ;Lab Label/Requisition Screen
+1 ;ORIFN=ifn of order ^OR(100,ORIFN)
+2 ;OACTION=ifn of order action ^OR(100,ORIFN,8,OACTION)
+3 ;ORRACT=1 if request is a reprint
+4 ;ACTION=a string of action codes to allow printing (NW DC HD RL)
+5 ;TYPE=a string of lab collection types to allow printing (LC IC WC SP)
+6 ;Example of screen allowing print of New order with collection types LC or IC:
+7 ; $$LBSCREEN(ifn,1,,"NW","LCIC")
+8 NEW ACT,X3
+9 if '$GET(ORIFN)
QUIT 0
+10 SET X3=$PIECE($GET(^OR(100,ORIFN,3)),"^",3)
+11 IF X3=1!(X3=2)!(X3=13)!(X3=14)
QUIT 0
+12 if $GET(ORRACT)
QUIT 1
+13 if '$GET(OACTION)
QUIT 0
+14 if '$DATA(^OR(100,ORIFN,8,+OACTION,0))
QUIT 0
SET ACT=$PIECE(^(0),"^",2)
+15 IF $LENGTH($GET(ACTION))
IF ACTION[ACT
IF TYPE[$$VALUE^ORCSAVE2(ORIFN,"COLLECT")
QUIT 1
+16 QUIT 0