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

SDRROR.m

Go to the documentation of this file.
  1. SDRROR ;10N20/MAH;Recall Reminder CPRS Display;01/15/2008
  1. ;;5.3;Scheduling;**536,561,571**;Aug 13, 1993;Build 3
  1. ;;This routine is called from ORWCV
  1. ;;and will be called if Outpatient Clinic param entry is either
  1. ;;null or cards
  1. ;VAR BEG,END,AND DFN WILL BE KILLED WITH OR ROUTINES
  1. COVER ; GET RECALL DATES FOR A PATIENT
  1. ;At ORWCV TAG VST+24 ADD D COVER^SDRROR
  1. Q:BEG<1!(END<1)
  1. F RCIFN=0:0 S RCIFN=$O(^SD(403.5,"B",DFN,RCIFN)) Q:RCIFN<1 D
  1. .S RCX=$G(^SD(403.5,RCIFN,0)) Q:RCX=""
  1. .S RCDT=$P(RCX,U,6) Q:RCDT<BEG Q:RCDT>END
  1. .S RCTYPE=$P(RCX,U,4),RCCLIN=$P(RCX,U,2)
  1. .S:RCTYPE]"" RCTYPE=$P($G(^SD(403.51,RCTYPE,0)),U,2)
  1. .S:RCCLIN]"" RCCLIN=$$GET1^DIQ(44,RCCLIN_",",.01)
  1. .S DATE1=RCDT S:$D(^TMP("ORVSTLIST",$J,RCDT)) DATE1=RCDT+.0001_RCIFN ;SD*571 added RCIFN so all recalls for same date for patient display in CPRS
  1. .S RCNODE="RECALL ("_RCTYPE_") "_RCCLIN,RCNODE=$E(RCNODE,1,45)
  1. .S ^TMP("ORVSTLIST",$J,DATE1,"R",1)="R;"_RCDT_";"_RCIFN_U_RCDT_U_RCNODE
  1. K RCIFN,RCX,RCTYPE,RCCLIN,RCDT,RCNODE,DATE1
  1. Q
  1. RCDTL ; RECALL DETAILS At ORWCV TAG DTLVST+18 ADD I $P(APPTINFO,";")="R" D RCDTL^SDRROR
  1. S RPT(1)="The patient will be sent a letter prior to this date reminding them to make an" ;SD*561 text changed to read 'prior to this date'
  1. S RPT(2)="appointment with the listed clinic."
  1. S RCIFN=$P(APPTINFO,";",3) Q:RCIFN=""
  1. S APPTINFO=$G(^SD(403.5,RCIFN,0)) Q:APPTINFO=""
  1. S COMM=$P(APPTINFO,U,7),FAST=$P(APPTINFO,U,8)
  1. S:FAST]"" FAST=$P($P(^DD(403.5,2.6,0),FAST_":",2),";")
  1. S RPT(3)=" "
  1. S:FAST]"" RPT(4)="Patient should be "_FAST
  1. S RPT($S(FAST]"":5,1:4))="Comment: "_COMM
  1. K RCIFN,COMM,FAST
  1. Q