MAGGTSY1 ;WOIFO/GEK - Imaging Session Utilities ; [ 06/20/2001 08:57 ] ;;3.0;IMAGING;**7**;Jul 12, 2002 ;; +---------------------------------------------------------------+ ;; | Property of the US Government. | ;; | No permission to copy or redistribute this software is given. | ;; | Use of unreleased versions of this software requires the user | ;; | to execute a written test agreement with the VistA Imaging | ;; | Development Office of the Department of Veterans Affairs, | ;; | telephone (301) 734-0100. | ;; | | ;; | The Food and Drug Administration classifies this software as | ;; | a medical device. As such, it may not be changed in any way. | ;; | Modifications to this software may result in an adulterated | ;; | medical device under 21CFR820, the use of which is considered | ;; | to be a violation of US Federal Statutes. | ;; +---------------------------------------------------------------+ ;; Q SESSION(MAGRY,DATA) ;RPC Call for MAGSYS utility. ; List of Sessions for a Workstation. ; DATA is '^' delimited string ; IEN Workstatin File ^ From Date ^ To Date ; N I,J,I1,CT,X,Y,Z,MAGX,MAGWIEN,MAGTIEN N DTFR,DTTO S ^TMP("MAGGTSY1","DATA")=DATA S MAGWIEN=$P(DATA,U,1) S MAGRY=$NA(^TMP($J,"MAGWSESS")) K ^TMP($J,"MAGWSESS") S CT=1 S DTFR=$P(DATA,U,2),DTTO=$P(DATA,U,3) I DTFR>DTTO S X=DTFR,DTFR=DTTO,DTTO=X I DTTO=0 S DTTO=9999999 S DTTO=DTTO_".9999" S ACI="L"_DTTO F S ACI=$O(^MAG(2006.82,"ACWRK",MAGWIEN,ACI),-1) S I1=$E(ACI,2,99) Q:I1