; *** Common procedure file error check
; Input: IMAGING TYPE file (#79.2) IEN (RAIMGTYI)
; PROCEDURE file (#71) IEN (RAPROCD0) (Optional)
; Output: Number_of_Common_Proccedures ^ $S(Duplicate_Sequence#:1,1:0)
EN1EXIT
EN5(RAD0,RAIMGTYI,RASEQ,SK)
; *** Update ^RAMIS(71.3,"AA", xref
; Input: RAD0 = RAD/NUC MED COMMON PROCEDURE file (#71.3) IEN
; RAPRC = PROCEDURE file (#71) IEN
; RASEQ = Sequence number
; SK = Set/Kill flag: $S(SK="S":Set_xref,SK="K":Kill_xref)
EN1
; *** Get an imaging type
; Input: None
; Output: The variable 'Y' will be one of the following
; -1 = No imaging type selected (up-arrow, time-out, etc.)
; 0 = No active imaging types found
; IEN = IMAGING TYPE file (#79.2) IEN
EN3(D0)
; *** imaging type of a procedure
; Input: RAD/NUC MED PROCEDURE file (#71) IEN
; Output: IMAGING TYPE file (#79.2) IEN
DESC(RAD0,RAY)
; Detemine if a procedure qualifies as a descendent for this
; parent procedure. Descendent must be either a detailed or series
; type procedure, must be of same imaging type of the parent, and must
; not be inactive. Called from ^DD(71.05,.01,0)
; 'RAD0' ien of parent procedure in file 71
; 'RAY' ien of pointed to procedure in file 71
; Returns: 'RA' i.e, 0:invalid procedure, 1:valid procedure
; RAPARNT: zero node of parent procedure
; RAPARNT(12): i-type of parent procedure
; RADESC : zero node of descendent procedure
; RADESC("I"): inactivation date (if any) of descendent
; RADESC(6) : procedure type of descendent
; RADESC(12) : i-type of descendent procedure