- DGPFRAL ;ALB/RBS - PRF ACTION NOT LINKED REPORT ; 7/26/05 3:18pm
- ;;5.3;Registration;**554,1015**;Aug 13, 1993;Build 21
- ;
- ;This routine will be used for selecting sort parameters to produce
- ;the DGPF ACTION NOT LINKED REPORT for Patient Record Flags.
- ;
- ; Selection options will provide the ability to report by:
- ; CATEGORY
- ; BEGINNING DATE
- ; ENDING DATE
- ;
- ; The following reporting sort array will be built by user prompts:
- ; DGSORT("DGCAT") = CATEGORY
- ; 1^Category I (National)
- ; 2^Category II (Local)
- ; 3^Both
- ; DGSORT("DGBEG") = BEGINNING DATE (internal FileMan date)
- ; DGSORT("DGEND") = ENDING DATE (internal FileMan date)
- ;
- ;-- no direct entry
- QUIT
- ;
- EN ;Entry point
- ;-- user prompts for report selection sorts
- ; Input: none
- ; Output: Report generated using user selected parameters
- ;
- N DGASK ;return value from $$ANSWER^DGPFUT call
- N DGCAT ;flag category to report on
- N DGDIRA ;DGDIRA - DIR("A") string
- N DGDIRB ;DGDIRB - DIR("B") string
- N DGDIRH ;DGDIRH - DIR("?") string
- N DGDIRO ;DGDIR0 - DIR(0) string
- N DGFIRST ;first assignment date
- N DGSEL ;help text var
- N DGSORT ;array or report parameters
- N ZTSAVE ;open array reference of input parameters used by tasking
- ;
- S DGFIRST=$P(+$O(^DGPF(26.14,"D","")),".") ;first assignment date
- I 'DGFIRST D Q
- . W !?2,">>> No Patient Record Flag Assignments have been found.",*7
- . I $$ANSWER^DGPFUT("Enter RETURN to continue","","E") ;pause
- ;
- ;-- prompt for selection of a flag category
- S DGDIRA="Select Flag Category"
- S DGDIRB=""
- S DGDIRH="Enter one of the category selections to report on"
- S DGDIRO="S^1:Category I (National);2:Category II (Local);3:Both"
- S DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- Q:(DGASK<1)
- S DGCAT=DGASK,DGSORT("DGCAT")=DGASK_U_$S(DGCAT=1:"Category I (National)",DGCAT=2:"Category II (Local)",DGCAT=3:"Both",1:"")
- ;
- ;-- prompt for beginning date
- S DGDIRA="Select Beginning Date"
- S DGDIRB=""
- S DGDIRH="^D HELP^DGPFRAL(1)"
- S DGDIRO="D^"_DGFIRST_":DT:EX"
- S DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- Q:(DGASK=-1)
- S DGSORT("DGBEG")=DGASK
- ;
- ;-- prompt for ending date
- S DGDIRA="Select Ending Date"
- S DGDIRB=""
- S DGDIRH="^D HELP^DGPFRAL(2)"
- S DGDIRO="D^"_DGSORT("DGBEG")_":DT:EX"
- S DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- Q:(DGASK=-1)
- S DGSORT("DGEND")=DGASK
- ;
- K DGCAT,DGDIRA,DGDIRB,DGDIRO,DGDIRH,DGASK,DGFIRST
- ;
- ;-- prompt for device
- S ZTSAVE("DGSORT(")=""
- D EN^XUTMDEVQ("START^DGPFRAL1","Assignment Action Not Linked to a Progress Note Report",.ZTSAVE)
- D HOME^%ZIS
- Q
- ;
- HELP(DGSEL) ;provide extended DIR("?") help text.
- ;
- ; Input: DGSEL - prompt var for help text word selection
- ; Output: none
- ;
- W !," Enter the "_$S(DGSEL=1:"earliest",1:"latest")_" Assignment Action Date to include in the report."
- W !," Please enter a date from the specified date range displayed."
- Q
- DGPFRAL ;ALB/RBS - PRF ACTION NOT LINKED REPORT ; 7/26/05 3:18pm
- +1 ;;5.3;Registration;**554,1015**;Aug 13, 1993;Build 21
- +2 ;
- +3 ;This routine will be used for selecting sort parameters to produce
- +4 ;the DGPF ACTION NOT LINKED REPORT for Patient Record Flags.
- +5 ;
- +6 ; Selection options will provide the ability to report by:
- +7 ; CATEGORY
- +8 ; BEGINNING DATE
- +9 ; ENDING DATE
- +10 ;
- +11 ; The following reporting sort array will be built by user prompts:
- +12 ; DGSORT("DGCAT") = CATEGORY
- +13 ; 1^Category I (National)
- +14 ; 2^Category II (Local)
- +15 ; 3^Both
- +16 ; DGSORT("DGBEG") = BEGINNING DATE (internal FileMan date)
- +17 ; DGSORT("DGEND") = ENDING DATE (internal FileMan date)
- +18 ;
- +19 ;-- no direct entry
- +20 QUIT
- +21 ;
- EN ;Entry point
- +1 ;-- user prompts for report selection sorts
- +2 ; Input: none
- +3 ; Output: Report generated using user selected parameters
- +4 ;
- +5 ;return value from $$ANSWER^DGPFUT call
- NEW DGASK
- +6 ;flag category to report on
- NEW DGCAT
- +7 ;DGDIRA - DIR("A") string
- NEW DGDIRA
- +8 ;DGDIRB - DIR("B") string
- NEW DGDIRB
- +9 ;DGDIRH - DIR("?") string
- NEW DGDIRH
- +10 ;DGDIR0 - DIR(0) string
- NEW DGDIRO
- +11 ;first assignment date
- NEW DGFIRST
- +12 ;help text var
- NEW DGSEL
- +13 ;array or report parameters
- NEW DGSORT
- +14 ;open array reference of input parameters used by tasking
- NEW ZTSAVE
- +15 ;
- +16 ;first assignment date
- SET DGFIRST=$PIECE(+$ORDER(^DGPF(26.14,"D","")),".")
- +17 IF 'DGFIRST
- Begin DoDot:1
- +18 WRITE !?2,">>> No Patient Record Flag Assignments have been found.",*7
- +19 ;pause
- IF $$ANSWER^DGPFUT("Enter RETURN to continue","","E")
- End DoDot:1
- QUIT
- +20 ;
- +21 ;-- prompt for selection of a flag category
- +22 SET DGDIRA="Select Flag Category"
- +23 SET DGDIRB=""
- +24 SET DGDIRH="Enter one of the category selections to report on"
- +25 SET DGDIRO="S^1:Category I (National);2:Category II (Local);3:Both"
- +26 SET DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- +27 IF (DGASK<1)
- QUIT
- +28 SET DGCAT=DGASK
- SET DGSORT("DGCAT")=DGASK_U_$SELECT(DGCAT=1:"Category I (National)",DGCAT=2:"Category II (Local)",DGCAT=3:"Both",1:"")
- +29 ;
- +30 ;-- prompt for beginning date
- +31 SET DGDIRA="Select Beginning Date"
- +32 SET DGDIRB=""
- +33 SET DGDIRH="^D HELP^DGPFRAL(1)"
- +34 SET DGDIRO="D^"_DGFIRST_":DT:EX"
- +35 SET DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- +36 IF (DGASK=-1)
- QUIT
- +37 SET DGSORT("DGBEG")=DGASK
- +38 ;
- +39 ;-- prompt for ending date
- +40 SET DGDIRA="Select Ending Date"
- +41 SET DGDIRB=""
- +42 SET DGDIRH="^D HELP^DGPFRAL(2)"
- +43 SET DGDIRO="D^"_DGSORT("DGBEG")_":DT:EX"
- +44 SET DGASK=$$ANSWER^DGPFUT(DGDIRA,DGDIRB,DGDIRO,DGDIRH)
- +45 IF (DGASK=-1)
- QUIT
- +46 SET DGSORT("DGEND")=DGASK
- +47 ;
- +48 KILL DGCAT,DGDIRA,DGDIRB,DGDIRO,DGDIRH,DGASK,DGFIRST
- +49 ;
- +50 ;-- prompt for device
- +51 SET ZTSAVE("DGSORT(")=""
- +52 DO EN^XUTMDEVQ("START^DGPFRAL1","Assignment Action Not Linked to a Progress Note Report",.ZTSAVE)
- +53 DO HOME^%ZIS
- +54 QUIT
- +55 ;
- HELP(DGSEL) ;provide extended DIR("?") help text.
- +1 ;
- +2 ; Input: DGSEL - prompt var for help text word selection
- +3 ; Output: none
- +4 ;
- +5 WRITE !," Enter the "_$SELECT(DGSEL=1:"earliest",1:"latest")_" Assignment Action Date to include in the report."
- +6 WRITE !," Please enter a date from the specified date range displayed."
- +7 QUIT