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

DGR1131.m

Go to the documentation of this file.
  1. DGR1131 ;ALB/KUM,BDB,ARF - Health Benefit Plan View History Expanded - List Manager Screen for screen 11.3.1 ;5/30/19 10:56am
  1. ;;5.3;Registration;**987,1006,1014**;Aug 13, 1993;Build 42
  1. ;
  1. EN(DFN,DGNAME,HBP) ;Main entry point to invoke the DGEN HBP VIEWEXP list
  1. ; Input -- DFN Patient ID
  1. ; DGNAME Text for plan selected from the list in screen 11.3
  1. ; HBP Patient Plan Details array
  1. ;
  1. D WAIT^DICD
  1. D EN^VALM("DGEN HBP VIEWEXP")
  1. Q
  1. ;
  1. HDR ;Header code
  1. N X,DGSTR,DGWD,DGSPC,DGPLAN
  1. D LISTHDR^DGRPU(1) ;DG*5.3*1014 - ARF - sets patient data in the 1st and 2nd entries in VALMHDR array
  1. ;S VALMHDR(1)=$E("Patient: "_$P($G(^DPT(DFN,0)),U),1,30) ;DG*5.3*1014 begin comment previous code
  1. ;S VALMHDR(1)=VALMHDR(1)_" ("_VA("BID")_")"
  1. ;S X="PATIENT TYPE UNKNOWN"
  1. ;I $D(^DPT(DFN,"TYPE")),$D(^DG(391,+^("TYPE"),0)) S X=$P(^DG(391,+^DPT(DFN,"TYPE"),0),U,1)
  1. ;S VALMHDR(1)=$$SETSTR^VALM1(X,VALMHDR(1),60,80)
  1. ;S VALMHDR(2)=" "
  1. ;S VALMHDR(3)="Action Date/Time Profile" ;DG*5.3*1006 BDB ; Time is now displayed with the date
  1. ;S VALMHDR(4)="------ --------- -------" ;DG*5.3*1006 BDB
  1. ;S DGSTR=$$TRIM^XLFSTR($E(DGNAME,6,999)),DGWD=80,DGSPC=" "
  1. ;D FSTRING(DGSTR,DGWD,.DGPLAN)
  1. ;S VALMHDR(5)=DGPLAN(1,0)
  1. ;I DGPLAN=2 D
  1. ;.S VALMHDR(6)=DGSPC_DGPLAN(2,0)
  1. ;S VALMHDR(7)=" "
  1. ;S VALMSG="+ Next Screen - Prev Screen ?? More Actions" ;DG*5.3*1014 end -increased following VALAMHDR subscripts ;DG*5.3*1014 end comment previous code
  1. S VALMHDR(3)=" "
  1. S VALMHDR(4)="Action Date/Time Profile" ;DG*5.3*1006 BDB ; Time is now displayed with the date
  1. S VALMHDR(5)="------ --------- -------" ;DG*5.3*1006 BDB
  1. S DGSTR=$$TRIM^XLFSTR($E(DGNAME,6,999)),DGWD=80,DGSPC=" "
  1. D FSTRING(DGSTR,DGWD,.DGPLAN)
  1. S VALMHDR(6)=DGPLAN(1,0)
  1. I DGPLAN=2 D
  1. .S VALMHDR(7)=DGSPC_DGPLAN(2,0)
  1. S VALMHDR(8)=" "
  1. S VALMSG="+ Next Screen - Prev Screen ?? More Actions"
  1. Q
  1. ;
  1. INIT ; -- init variables and list array
  1. N DGACT,LST,CNT
  1. D CLEAN^VALM10
  1. D CLEAR^VALM1
  1. S LST=$P(HBP("DETAIL",0),"^",4)
  1. ;I LST="" W !,"No detail description is available for this Veteran Medical Benefit Plan"
  1. I LST="" W !,"No detail description is available for this VHA Profile" ;DG*5.3*1006 BDB
  1. S DGACT=$$FIND1^DIC(25.11,,"XQ",$$TRIM^XLFSTR($E(DGNAME,37,999))) ;DG*5.3*1006 ; BDB; Plan name is at location 37
  1. F CNT=1:1:LST D SET^VALM10(CNT," "_HBP("DETAIL",DGACT,CNT))
  1. S VALMCNT=CNT
  1. S VALMBCK="R"
  1. Q
  1. ;
  1. HELP ; -- help code
  1. S X="?" D DISP^XQORM1 W !!
  1. Q
  1. ;
  1. EXIT ; -- exit code
  1. Q
  1. ;
  1. EXPND ; -- expand code
  1. Q
  1. ;
  1. PEXIT ; MENU protocol exit code
  1. S VALMSG="+ Next Screen - Prev Screen ?? More Actions"
  1. Q
  1. ;
  1. FSTRING(DGSTR,DGWD,DGARRAY) ;Parse text string into lines of length DGWD
  1. ; Input:
  1. ; DGSTR - (required) Text string to be parsed
  1. ; DGWD - Length of parsed lines (default =80)
  1. ;
  1. ; Output:
  1. ; DGARRAY - (required) Result array of formatted output text, passed by reference
  1. ;
  1. N X,DGI,DIWL,DIWR,DIWF
  1. K DGARRAY,^UTILITY($J,"W")
  1. S X=$G(DGSTR)
  1. I X'="" S DIWL=1,DIWR=$G(DGWD,80),DIWF="" D ^DIWP
  1. I $D(^UTILITY($J,"W")) M DGARRAY=^UTILITY($J,"W",1)
  1. K ^UTILITY($J,"W")
  1. Q