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

AQAOPR9.m

Go to the documentation of this file.
  1. AQAOPR9 ; IHS/ORDC/LJF - OCC AUDIT LISTINGS ;
  1. ;;1.01;QAI MANAGEMENT;;OCT 05, 1995
  1. ;
  1. ;This rtn contains the user interface and the DIP call to print
  1. ;audit activity for one occurrence, for one user, or by a date
  1. ;range. Every data entry action on occurrences and action plans
  1. ;is tracked by the QI Audit file.
  1. ;
  1. REPORT ; >>> choose type of report to print
  1. S AQAOINAC="" ;bypass screen on occurrence file
  1. K AQAOBD,AQAOED S AQAOSRT=""
  1. K DIR S DIR(0)="SO^",DIR("A")="Choose ONE Report from List"
  1. F X=1:1:3 S DIR(0)=DIR(0)_X_":"_$P($T(RPT+X),";;",2)_";"
  1. S DIR(0)=$E(DIR(0),1,$L(DIR(0))-1)
  1. D ^DIR G END:$D(DIRUT),END:X="",END:Y=-1
  1. S AQAORPT=+Y G DATES:AQAORPT=1
  1. ;
  1. CHOOSE ; >>> choose which entry
  1. K DIC S DIC=$P($T(RPT+AQAORPT),";;",3),DIC(0)="AEQMZ" D ^DIC
  1. G REPORT:$D(DTOUT),REPORT:$D(DUOUT),CHOOSE:Y=-1
  1. S AQAOSRT=$S(AQAORPT=2:$P(Y,U,2),1:$P(^VA(200,+Y,0),U,2)) G PRINT
  1. ;
  1. DATES ; >> choose date ranges
  1. S AQAOBD=$$BDATE^AQAOLKP G REPORT:AQAOBD=""
  1. S AQAOED=$$EDATE^AQAOLKP G DATES:AQAOED=""
  1. ;
  1. ;
  1. ; >>> FIND DATA FOR SELECTED REPORT <<<
  1. PRINT ; >>> set up variables for dip call
  1. K DIC S DIC="^AQAGU(",L=0,FLDS="[AQAO AUDIT LIST]"
  1. S BY=$P($T(RPT+AQAORPT),";;",4),(FR,TO)=AQAOSRT_",?"
  1. I $D(AQAOBD) S FR=AQAOBD,TO=AQAOED
  1. D EN1^DIP
  1. ;
  1. D PRTOPT^AQAOVAR ;<cr> to continue code
  1. ;
  1. END D ^%ZISC,KILL^AQAOUTIL Q
  1. ;
  1. ;
  1. RPT ;;
  1. ;;For a DATE RANGE;;;;AUDIT DATE & TIME;;
  1. ;;For an OCCURRENCE;;^AQAOC(;;OCCURRENCE IFN,@AUDIT DATE & TIME;;
  1. ;;For a QI USER;;^AQAO(9,;;@USER INITIALS,@AUDIT DATE & TIME;;