Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: PSJ007

PSJ007.m

Go to the documentation of this file.
  1. PSJ007 ;BIR/RSB-UTILITY ROUTINE FOR PATCH PSJ*5*7 ; 16 Jun 98 / 12:28 PM
  1. ;;5.0; INPATIENT MEDICATIONS ;**7**; 16 DEC 97
  1. ;
  1. Q
  1. EN ; QUEUE UP 53.1 CLEANUP
  1. S ZTIO="",ZTDTH=$$CON(XPDQUES("POS ONE"))
  1. S ZTDESC="Inpatient Medications Patch PSJ*5*7 Unit Dose Non-Verified Orders File Cleanup"
  1. S ZTRTN="START^PSJ007" D ^%ZTLOAD
  1. I $D(ZTSK) D MES^XPDUTL(" ") D MES^XPDUTL("Task #"_ZTSK_" is queued to run"_$S($D(PSJCONV):" NOW",1:" at "_XPDQUES("POS ONE")))
  1. TEST ; Test text creation.
  1. N PM S PM="This task will find and delete entries the NON-VERIFIED/PENDING ORDERS" D MES^XPDUTL(PM)
  1. S PM="file (#53.1) that have no zero node." D MES^XPDUTL(PM)
  1. Q
  1. START ;
  1. N PSJ
  1. F PSJ=0:0 S PSJ=$O(^PS(53.1,PSJ)) Q:'PSJ K:'$D(^PS(53.1,PSJ,0)) ^PS(53.1,PSJ)
  1. S ZTREQ="@"
  1. Q
  1. ;
  1. GETDT ; check date/time for job to run
  1. N %DT,Y S %DT="NRS"
  1. D ^%DT I Y=-1 K X
  1. E S X=Y
  1. Q
  1. CON(X) ;
  1. N %DT S %DT="NRS" D ^%DT
  1. Q Y