source: FOIAVistA/trunk/r/HEALTH_SUMMARY-GMTS/GMTSMAG.m@ 1397

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

initial load of FOIAVistA 6/30/08 version

File size: 962 bytes
Line 
1GMTSMAG ;SLC/RMP - Imaging Health Summary Component ; 08/27/2002
2 ;;2.7;Health Summary;**26,56**;Oct 20, 1995
3 ;
4 ; External References
5 ; DBIA 2791 ^MAG(2005
6 ; DBIA 10022 %XY^%RCR
7 ;
8MAIN ; Imaging Component
9 N %X,%Y,GMI,MAX,MAGDFN,IX,X,PROC,GMTSXX Q:'$D(^MAG(2005,"AC",DFN))
10 S MAGDFN=DFN,MAX=$S(+($G(GMTSNDM))>0:+($G(GMTSNDM)),1:99999)
11 D IMGPTRE^GMTSMAGE(.GMTSXX,MAGDFN_"^"_DUZ)
12 S %X="GMTSXX",%Y="^TMP(""MAG"",$J," D %XY^%RCR Q:'$D(^TMP("MAG",$J))
13 D WRTMAG S IX=0
14 F S IX=$O(^TMP("MAG",$J,IX)) Q:IX="" S X=^TMP("MAG",$J,IX) D WRT
15 K ^TMP("MAG",$J)
16 Q
17WRTMAG ; Writes Imaging Header
18 D CKP^GMTSUP Q:$D(GMTSQIT) W ?1,"Date/Time",?20,"Procedure",?34,"Short Description",!!
19 Q
20WRT ; Writes Image date/time, procedure, short text
21 N Y S Y=$P(X,U) S Y=$$FMTE(Y) D CKP^GMTSUP Q:$D(GMTSQIT) D
22 . W Y,?20,$E($P(X,U,2),1,12),?34,$E($P(X,U,3),1,43),!
23 Q
24FMTE(X) ; Fileman to External
25 S X=$G(X) D REGDTM4^GMTSU Q X
Note: See TracBrowser for help on using the repository browser.