ORDEA01 ;ISP/RFR - DEA TOOLS;10/15/2014 08:09
;;3.0;ORDER ENTRY/RESULTS REPORTING;**218,374,350,499,607**;Dec 17, 1997;Build 7
Q
SITE ;Edit the site-level parameter
N DA,SITE
S DA=$O(^ORD(100.7,0))
I +$G(DA)=0 D
.N FDA,ERROR,IEN
.S SITE=$P($$SITE^VASITE(),U,2)
.S FDA(100.7,"+1,",.01)=SITE,FDA(100.7,"+1,",.02)="YES"
.D UPDATE^DIE("E","FDA","IEN","ERROR")
.I $D(ERROR) D Q
..N IDX
..S IDX=0 F S IDX=$O(ERROR("DIERR",IDX)) Q:'IDX D
...W "FILEMAN ERROR #"_ERROR("DIERR",IDX)_":",!
...W ERROR("DIERR",IDX,"TEXT",1)
.S DA=IEN(1)
I +$G(DA)>0,($G(SITE)="") S SITE=$$GET1^DIQ(100.7,DA_",",.01)
Q:+$G(DA)=0
W !!,"This option is used to enable or disable electronic prescribing of outpatient",!
W "controlled substances for your entire site. Yes enables it and No disables it.",!
W !,"CONFIGURING SITE "_SITE,!
N DIE,DR
S DIE="^ORD(100.7,",DR=.02
D ^DIE
Q
USER ;Edit user-level parameter
N DA
S DA=$O(^ORD(100.7,0))
I +$G(DA)=0 D Q
.W !!,"NO SITE CONFIGURED.",!!
.W "You must first run the ePCS Site Enable/Disable [OR EPCS SITE PARAMETER] option",!
.W "before running this option.",!
.H 4
W !!,"This option is used to enable or disable electronic prescribing of outpatient",!
W "controlled substances for individual users.",!
W !,"CONFIGURING SITE "_$$GET1^DIQ(100.7,DA_",",.01),!
N EXIT
F D Q:+$G(EXIT)
.N DIC,X,Y,DTOUT,DUOUT,IEN,ACTION,DIR,DIRUT,DIROUT
.S DIC="^VA(200,",DIC(0)="AEQ",DIC("A")="Select the USER NAME: "
.D ^DIC
.S:+Y<1 EXIT=1
.Q:+Y<1
.S IEN=Y,ACTION=$S($D(^ORD(100.7,"C",+IEN)):"enabled^disable",1:"disabled^enable")
.W !!,$P(IEN,U,2)_" is currently "_$P(ACTION,U,1)_"."
.K X,Y
.S DIR(0)="Y^A",DIR("A")="Do you want to "_$P(ACTION,U,2)_" "_$P(IEN,U,2)
.S DIR("B")="NO"
.D ^DIR
.Q:$D(DIRUT)
.I Y=1 D
..N FDA,ERROR,SCHEDULES,SEX
..I $P(ACTION,U,1)="disabled" D
...N RETURN,PROBLEM,OUTPUT,TEXT,DELIMIT,COUNT,SFIEN,DEANUM,INPFLG,NDEAIEN
...I $O(^VA(200,+IEN,"PS4",0)) D
....S SFIEN=0 F S SFIEN=$O(^VA(200,+IEN,"PS4",SFIEN)) Q:'SFIEN D
.....S DEANUM=$$GET1^DIQ(200.5321,SFIEN_","_+IEN_",",.01,"E"),NDEAIEN=$$FIND1^DIC(8991.9,,"O",DEANUM,"B",,)
.....S INPFLG=$$GET1^DIQ(8991.9,NDEAIEN,.06,"I") I INPFLG=0 Q
...S RETURN=$S($O(^VA(200,+IEN,"PS4",0)):$$VDEADNA^XUSER(.RETURN,+IEN,NDEAIEN),1:$$VDEA^XUSER(.RETURN,+IEN))
...S SEX=$$GET1^DIQ(200,+IEN_",",4),SEX=$S(SEX="MALE":"he",SEX="FEMALE":"she",1:"it")
...I 'RETURN D
.... S PROBLEM="" F S PROBLEM=$O(RETURN(PROBLEM)) Q:PROBLEM="" D
..... I PROBLEM["DEA number with no expiration date" K RETURN(PROBLEM)
..... I PROBLEM["expired DEA number" K RETURN(PROBLEM)
.... S PROBLEM=$O(RETURN("")) I PROBLEM["permitted to prescribe all schedules",$O(RETURN(PROBLEM))="" S RETURN=1
...I RETURN D
....S FDA(100.71,"+1,"_DA_",",.01)=+IEN
....D UPDATE^DIE("S","FDA",,"ERROR")
...S PROBLEM="" F S PROBLEM=$O(RETURN(PROBLEM)) Q:$G(PROBLEM)="" D
....I PROBLEM'["Is permitted to prescribe" D
.....S COUNT=+$G(COUNT)+1,PROBLEM(COUNT)=$$LOW^XLFSTR($E(PROBLEM,1))_$P($E(PROBLEM,2,*),".",1)
.....S:PROBLEM(COUNT)["user account status:" PROBLEM(COUNT)=$P(PROBLEM(COUNT),":",1)_" is"_$P(PROBLEM(COUNT),":",2)
....S:PROBLEM["Is permitted to prescribe" SCHEDULES=$$LOW^XLFSTR($E(PROBLEM,1))_$E(PROBLEM,2,*)
...S PROBLEM=+$G(COUNT)
...I 'RETURN D
....W !!
....S DELIMIT=", "
....F COUNT=1:1:PROBLEM D
.....S:COUNT=PROBLEM DELIMIT=" and "
.....S TEXT=$S($G(TEXT)'="":TEXT_DELIMIT,1:"")_PROBLEM(COUNT)
....S TEXT="Cannot enable "_$P(IEN,U,2)_" to sign controlled substance orders because "_$S($E(TEXT,1,4)'="user":SEX_" ",1:"")_TEXT_"."
....D WRAP^ORUTL(TEXT,"OUTPUT")
....F COUNT=1:1:OUTPUT W OUTPUT(COUNT),!
..I $P(ACTION,U,1)="enabled" D
...S FDA(100.71,$O(^ORD(100.7,"C",+IEN,DA,0))_","_DA_",",.01)="@"
...D FILE^DIE("S","FDA","ERROR")
..I $D(ERROR) D
...N IDX
...S IDX=0 F S IDX=$O(ERROR("DIERR",IDX)) Q:'IDX D
....W !!,"FILEMAN ERROR #"_ERROR("DIERR",IDX)_":",!
....W ERROR("DIERR",IDX,"TEXT",1),!
..I '$D(ERROR),($D(FDA)) D
...N OUTPUT,COUNT,TEXT
...S TEXT="Successfully "_$P(ACTION,U,2)_"d "_$P(IEN,U,2)
...S TEXT=TEXT_$S($G(SCHEDULES)'="":" and "_SEX_" "_SCHEDULES,1:".")
...D WRAP^ORUTL(TEXT,"OUTPUT")
...W !!
...F COUNT=1:1:OUTPUT W OUTPUT(COUNT),!
Q
PRVCHK ;CHECK SINGLE PROVIDER IS PROPERLY SETUP
N DIC,Y,X,DTOUT,DUOUT
S DIC="^VA(200,",DIC(0)="AEOQ"
S DIC("A")="Select the provider: "
D ^DIC
Q:+Y<1
W !!
N STATUS,RETURN,TEXT,OUTPUT,LINE,LAST,USING
;*499 - select if there are multiple DEA #s
S USING=""
S STATUS=$S($O(^VA(200,+Y,"PS4",0)):$$VDEADNM^XUSER(.RETURN,+Y),1:$$VDEA^XUSER(.RETURN,+Y))
S:$P(STATUS,"^",2)'="" USING="Using DEA # "_$P(STATUS,"^",2)_", "
S STATUS=+STATUS
S STATUS=$$CHKSWIT(.RETURN,+Y,STATUS)
I $D(RETURN("Has an expired DEA number.")) S STATUS=0 ;BDB
W USING,!
S TEXT="This provider is"_$S(STATUS=0:" not",1:"")_" able to write controlled substance orders"
I STATUS=0 S OUTPUT=2,OUTPUT(1)=TEXT_" for the",OUTPUT(2)="following reasons:"
I STATUS=1 S TEXT=TEXT_" and "
S RETURN="" F S RETURN=$O(RETURN(RETURN)) Q:$G(RETURN)="" D
.I STATUS=1 D
..I RETURN["Is permitted to prescribe" D
...D WRAP^ORUTL(TEXT_"is"_$P(RETURN,"Is",2),"OUTPUT")
...S TEXT=""
..I RETURN'["Is permitted to prescribe" D WRAP^ORUTL(RETURN,"LAST")
.I STATUS=0 D
..I RETURN["Is permitted to prescribe" D WRAP^ORUTL("Once all of the issues above are resolved, the provider is"_$P(RETURN,"Is",2),"LAST")
..I RETURN'["Is permitted to prescribe" S OUTPUT=OUTPUT+1,OUTPUT(OUTPUT)=RETURN
I '$D(OUTPUT) D WRAP^ORUTL(TEXT_"is permitted to prescribe any schedule.","OUTPUT")
F LINE=1:1:OUTPUT W OUTPUT(LINE),!
I $D(LAST)>9 D
.I STATUS=1 W !,"However, the following item"_$S(LAST=1:" was",1:"s were")_" noted:",!
.F LINE=1:1:+$G(LAST) W LAST(LINE),!
G PRVCHK
Q
CHKSWIT(RETURN,IEN,RETVAL) ;CHECK THE LITTLE SWITCH
I '$D(^ORD(100.7,"C",IEN)) D
.S RETURN("Is not an ENABLED USER in the OE/RR EPCS PARAMETERS file.")="",RETVAL=0
Q RETVAL
REPORTS ;PROMPT THE USER FOR THE REPORT TO RUN
N DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT,REP
S REP("CFG")="Provider Incomplete Configuration;INCOMPL^ORDEA01A;INCOMPLQ^ORDEA01A"
S REP("DUP")="Duplicate VA Numbers;DUPVA^ORDEA01A;DUPVAQ^ORDEA01A"
;S REP("DET")="DETOX/MAINTENANCE ID List;DETOX^ORDEA01A;DETOXQ^ORDEA01A" - OR*3*607 - DETOX/X-WAIVER REMOVAL
S REP("LAS")="Provider Last Names Containing Punctuation;LAST^ORDEA01B;LASTQ^ORDEA01B"
S REP("FEE")="Fee Basis/C & A Providers Without a DEA Number;FEEDEA^ORDEA01B;FEEDEAQ^ORDEA01B"
S REP("AUD")="Logical Access Control Audit;AUDIT^ORDEA01B;AUDITQ^ORDEA01B"
S DIR(0)="SO"
S REP="" F S REP=$O(REP(REP)) Q:$G(REP)="" S $P(DIR(0),U,2)=$P(DIR(0),U,2)_REP_":"_$P(REP(REP),";")_";"
S DIR("A")="Select the data validation report to run"
D ^DIR
Q:$D(DIRUT)
Q:'$D(REP(Y))
S REP=Y
D @$P(REP(Y),";",2)
Q
DISPRMPT() ;PROMPT THE USER TO INCLUDE DISUSERED AND TERMINATED USERS
;RETURNS: ^ IF USER QUIT OR TIMED OUT
; OTHERWISE, THE VALUE OF VARIABLE Y
N DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT
S DIR(0)="Y"_U,DIR("A",1)="Do you want to include DISUSERed and TERMINATED users"
S DIR("A")="in the output",DIR("B")="NO"
D ^DIR
Q:$D(DIRUT) U
Q Y
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HORDEA01 7271 printed Dec 13, 2024@02:29:54 Page 2
ORDEA01 ;ISP/RFR - DEA TOOLS;10/15/2014 08:09
+1 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**218,374,350,499,607**;Dec 17, 1997;Build 7
+2 QUIT
SITE ;Edit the site-level parameter
+1 NEW DA,SITE
+2 SET DA=$ORDER(^ORD(100.7,0))
+3 IF +$GET(DA)=0
Begin DoDot:1
+4 NEW FDA,ERROR,IEN
+5 SET SITE=$PIECE($$SITE^VASITE(),U,2)
+6 SET FDA(100.7,"+1,",.01)=SITE
SET FDA(100.7,"+1,",.02)="YES"
+7 DO UPDATE^DIE("E","FDA","IEN","ERROR")
+8 IF $DATA(ERROR)
Begin DoDot:2
+9 NEW IDX
+10 SET IDX=0
FOR
SET IDX=$ORDER(ERROR("DIERR",IDX))
if 'IDX
QUIT
Begin DoDot:3
+11 WRITE "FILEMAN ERROR #"_ERROR("DIERR",IDX)_":",!
+12 WRITE ERROR("DIERR",IDX,"TEXT",1)
End DoDot:3
End DoDot:2
QUIT
+13 SET DA=IEN(1)
End DoDot:1
+14 IF +$GET(DA)>0
IF ($GET(SITE)="")
SET SITE=$$GET1^DIQ(100.7,DA_",",.01)
+15 if +$GET(DA)=0
QUIT
+16 WRITE !!,"This option is used to enable or disable electronic prescribing of outpatient",!
+17 WRITE "controlled substances for your entire site. Yes enables it and No disables it.",!
+18 WRITE !,"CONFIGURING SITE "_SITE,!
+19 NEW DIE,DR
+20 SET DIE="^ORD(100.7,"
SET DR=.02
+21 DO ^DIE
+22 QUIT
USER ;Edit user-level parameter
+1 NEW DA
+2 SET DA=$ORDER(^ORD(100.7,0))
+3 IF +$GET(DA)=0
Begin DoDot:1
+4 WRITE !!,"NO SITE CONFIGURED.",!!
+5 WRITE "You must first run the ePCS Site Enable/Disable [OR EPCS SITE PARAMETER] option",!
+6 WRITE "before running this option.",!
+7 HANG 4
End DoDot:1
QUIT
+8 WRITE !!,"This option is used to enable or disable electronic prescribing of outpatient",!
+9 WRITE "controlled substances for individual users.",!
+10 WRITE !,"CONFIGURING SITE "_$$GET1^DIQ(100.7,DA_",",.01),!
+11 NEW EXIT
+12 FOR
Begin DoDot:1
+13 NEW DIC,X,Y,DTOUT,DUOUT,IEN,ACTION,DIR,DIRUT,DIROUT
+14 SET DIC="^VA(200,"
SET DIC(0)="AEQ"
SET DIC("A")="Select the USER NAME: "
+15 DO ^DIC
+16 if +Y<1
SET EXIT=1
+17 if +Y<1
QUIT
+18 SET IEN=Y
SET ACTION=$SELECT($DATA(^ORD(100.7,"C",+IEN)):"enabled^disable",1:"disabled^enable")
+19 WRITE !!,$PIECE(IEN,U,2)_" is currently "_$PIECE(ACTION,U,1)_"."
+20 KILL X,Y
+21 SET DIR(0)="Y^A"
SET DIR("A")="Do you want to "_$PIECE(ACTION,U,2)_" "_$PIECE(IEN,U,2)
+22 SET DIR("B")="NO"
+23 DO ^DIR
+24 if $DATA(DIRUT)
QUIT
+25 IF Y=1
Begin DoDot:2
+26 NEW FDA,ERROR,SCHEDULES,SEX
+27 IF $PIECE(ACTION,U,1)="disabled"
Begin DoDot:3
+28 NEW RETURN,PROBLEM,OUTPUT,TEXT,DELIMIT,COUNT,SFIEN,DEANUM,INPFLG,NDEAIEN
+29 IF $ORDER(^VA(200,+IEN,"PS4",0))
Begin DoDot:4
+30 SET SFIEN=0
FOR
SET SFIEN=$ORDER(^VA(200,+IEN,"PS4",SFIEN))
if 'SFIEN
QUIT
Begin DoDot:5
+31 SET DEANUM=$$GET1^DIQ(200.5321,SFIEN_","_+IEN_",",.01,"E")
SET NDEAIEN=$$FIND1^DIC(8991.9,,"O",DEANUM,"B",,)
+32 SET INPFLG=$$GET1^DIQ(8991.9,NDEAIEN,.06,"I")
IF INPFLG=0
QUIT
End DoDot:5
End DoDot:4
+33 SET RETURN=$SELECT($ORDER(^VA(200,+IEN,"PS4",0)):$$VDEADNA^XUSER(.RETURN,+IEN,NDEAIEN),1:$$VDEA^XUSER(.RETURN,+IEN))
+34 SET SEX=$$GET1^DIQ(200,+IEN_",",4)
SET SEX=$SELECT(SEX="MALE":"he",SEX="FEMALE":"she",1:"it")
+35 IF 'RETURN
Begin DoDot:4
+36 SET PROBLEM=""
FOR
SET PROBLEM=$ORDER(RETURN(PROBLEM))
if PROBLEM=""
QUIT
Begin DoDot:5
+37 IF PROBLEM["DEA number with no expiration date"
KILL RETURN(PROBLEM)
+38 IF PROBLEM["expired DEA number"
KILL RETURN(PROBLEM)
End DoDot:5
+39 SET PROBLEM=$ORDER(RETURN(""))
IF PROBLEM["permitted to prescribe all schedules"
IF $ORDER(RETURN(PROBLEM))=""
SET RETURN=1
End DoDot:4
+40 IF RETURN
Begin DoDot:4
+41 SET FDA(100.71,"+1,"_DA_",",.01)=+IEN
+42 DO UPDATE^DIE("S","FDA",,"ERROR")
End DoDot:4
+43 SET PROBLEM=""
FOR
SET PROBLEM=$ORDER(RETURN(PROBLEM))
if $GET(PROBLEM)=""
QUIT
Begin DoDot:4
+44 IF PROBLEM'["Is permitted to prescribe"
Begin DoDot:5
+45 SET COUNT=+$GET(COUNT)+1
SET PROBLEM(COUNT)=$$LOW^XLFSTR($EXTRACT(PROBLEM,1))_$PIECE($EXTRACT(PROBLEM,2,*),".",1)
+46 if PROBLEM(COUNT)["user account status
SET PROBLEM(COUNT)=$PIECE(PROBLEM(COUNT),":",1)_" is"_$PIECE(PROBLEM(COUNT),":",2)
End DoDot:5
+47 if PROBLEM["Is permitted to prescribe"
SET SCHEDULES=$$LOW^XLFSTR($EXTRACT(PROBLEM,1))_$EXTRACT(PROBLEM,2,*)
End DoDot:4
+48 SET PROBLEM=+$GET(COUNT)
+49 IF 'RETURN
Begin DoDot:4
+50 WRITE !!
+51 SET DELIMIT=", "
+52 FOR COUNT=1:1:PROBLEM
Begin DoDot:5
+53 if COUNT=PROBLEM
SET DELIMIT=" and "
+54 SET TEXT=$SELECT($GET(TEXT)'="":TEXT_DELIMIT,1:"")_PROBLEM(COUNT)
End DoDot:5
+55 SET TEXT="Cannot enable "_$PIECE(IEN,U,2)_" to sign controlled substance orders because "_$SELECT($EXTRACT(TEXT,1,4)'="user":SEX_" ",1:"")_TEXT_"."
+56 DO WRAP^ORUTL(TEXT,"OUTPUT")
+57 FOR COUNT=1:1:OUTPUT
WRITE OUTPUT(COUNT),!
End DoDot:4
End DoDot:3
+58 IF $PIECE(ACTION,U,1)="enabled"
Begin DoDot:3
+59 SET FDA(100.71,$ORDER(^ORD(100.7,"C",+IEN,DA,0))_","_DA_",",.01)="@"
+60 DO FILE^DIE("S","FDA","ERROR")
End DoDot:3
+61 IF $DATA(ERROR)
Begin DoDot:3
+62 NEW IDX
+63 SET IDX=0
FOR
SET IDX=$ORDER(ERROR("DIERR",IDX))
if 'IDX
QUIT
Begin DoDot:4
+64 WRITE !!,"FILEMAN ERROR #"_ERROR("DIERR",IDX)_":",!
+65 WRITE ERROR("DIERR",IDX,"TEXT",1),!
End DoDot:4
End DoDot:3
+66 IF '$DATA(ERROR)
IF ($DATA(FDA))
Begin DoDot:3
+67 NEW OUTPUT,COUNT,TEXT
+68 SET TEXT="Successfully "_$PIECE(ACTION,U,2)_"d "_$PIECE(IEN,U,2)
+69 SET TEXT=TEXT_$SELECT($GET(SCHEDULES)'="":" and "_SEX_" "_SCHEDULES,1:".")
+70 DO WRAP^ORUTL(TEXT,"OUTPUT")
+71 WRITE !!
+72 FOR COUNT=1:1:OUTPUT
WRITE OUTPUT(COUNT),!
End DoDot:3
End DoDot:2
End DoDot:1
if +$GET(EXIT)
QUIT
+73 QUIT
PRVCHK ;CHECK SINGLE PROVIDER IS PROPERLY SETUP
+1 NEW DIC,Y,X,DTOUT,DUOUT
+2 SET DIC="^VA(200,"
SET DIC(0)="AEOQ"
+3 SET DIC("A")="Select the provider: "
+4 DO ^DIC
+5 if +Y<1
QUIT
+6 WRITE !!
+7 NEW STATUS,RETURN,TEXT,OUTPUT,LINE,LAST,USING
+8 ;*499 - select if there are multiple DEA #s
+9 SET USING=""
+10 SET STATUS=$SELECT($ORDER(^VA(200,+Y,"PS4",0)):$$VDEADNM^XUSER(.RETURN,+Y),1:$$VDEA^XUSER(.RETURN,+Y))
+11 if $PIECE(STATUS,"^",2)'=""
SET USING="Using DEA # "_$PIECE(STATUS,"^",2)_", "
+12 SET STATUS=+STATUS
+13 SET STATUS=$$CHKSWIT(.RETURN,+Y,STATUS)
+14 ;BDB
IF $DATA(RETURN("Has an expired DEA number."))
SET STATUS=0
+15 WRITE USING,!
+16 SET TEXT="This provider is"_$SELECT(STATUS=0:" not",1:"")_" able to write controlled substance orders"
+17 IF STATUS=0
SET OUTPUT=2
SET OUTPUT(1)=TEXT_" for the"
SET OUTPUT(2)="following reasons:"
+18 IF STATUS=1
SET TEXT=TEXT_" and "
+19 SET RETURN=""
FOR
SET RETURN=$ORDER(RETURN(RETURN))
if $GET(RETURN)=""
QUIT
Begin DoDot:1
+20 IF STATUS=1
Begin DoDot:2
+21 IF RETURN["Is permitted to prescribe"
Begin DoDot:3
+22 DO WRAP^ORUTL(TEXT_"is"_$PIECE(RETURN,"Is",2),"OUTPUT")
+23 SET TEXT=""
End DoDot:3
+24 IF RETURN'["Is permitted to prescribe"
DO WRAP^ORUTL(RETURN,"LAST")
End DoDot:2
+25 IF STATUS=0
Begin DoDot:2
+26 IF RETURN["Is permitted to prescribe"
DO WRAP^ORUTL("Once all of the issues above are resolved, the provider is"_$PIECE(RETURN,"Is",2),"LAST")
+27 IF RETURN'["Is permitted to prescribe"
SET OUTPUT=OUTPUT+1
SET OUTPUT(OUTPUT)=RETURN
End DoDot:2
End DoDot:1
+28 IF '$DATA(OUTPUT)
DO WRAP^ORUTL(TEXT_"is permitted to prescribe any schedule.","OUTPUT")
+29 FOR LINE=1:1:OUTPUT
WRITE OUTPUT(LINE),!
+30 IF $DATA(LAST)>9
Begin DoDot:1
+31 IF STATUS=1
WRITE !,"However, the following item"_$SELECT(LAST=1:" was",1:"s were")_" noted:",!
+32 FOR LINE=1:1:+$GET(LAST)
WRITE LAST(LINE),!
End DoDot:1
+33 GOTO PRVCHK
+34 QUIT
CHKSWIT(RETURN,IEN,RETVAL) ;CHECK THE LITTLE SWITCH
+1 IF '$DATA(^ORD(100.7,"C",IEN))
Begin DoDot:1
+2 SET RETURN("Is not an ENABLED USER in the OE/RR EPCS PARAMETERS file.")=""
SET RETVAL=0
End DoDot:1
+3 QUIT RETVAL
REPORTS ;PROMPT THE USER FOR THE REPORT TO RUN
+1 NEW DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT,REP
+2 SET REP("CFG")="Provider Incomplete Configuration;INCOMPL^ORDEA01A;INCOMPLQ^ORDEA01A"
+3 SET REP("DUP")="Duplicate VA Numbers;DUPVA^ORDEA01A;DUPVAQ^ORDEA01A"
+4 ;S REP("DET")="DETOX/MAINTENANCE ID List;DETOX^ORDEA01A;DETOXQ^ORDEA01A" - OR*3*607 - DETOX/X-WAIVER REMOVAL
+5 SET REP("LAS")="Provider Last Names Containing Punctuation;LAST^ORDEA01B;LASTQ^ORDEA01B"
+6 SET REP("FEE")="Fee Basis/C & A Providers Without a DEA Number;FEEDEA^ORDEA01B;FEEDEAQ^ORDEA01B"
+7 SET REP("AUD")="Logical Access Control Audit;AUDIT^ORDEA01B;AUDITQ^ORDEA01B"
+8 SET DIR(0)="SO"
+9 SET REP=""
FOR
SET REP=$ORDER(REP(REP))
if $GET(REP)=""
QUIT
SET $PIECE(DIR(0),U,2)=$PIECE(DIR(0),U,2)_REP_":"_$PIECE(REP(REP),";")_";"
+10 SET DIR("A")="Select the data validation report to run"
+11 DO ^DIR
+12 if $DATA(DIRUT)
QUIT
+13 if '$DATA(REP(Y))
QUIT
+14 SET REP=Y
+15 DO @$PIECE(REP(Y),";",2)
+16 QUIT
DISPRMPT() ;PROMPT THE USER TO INCLUDE DISUSERED AND TERMINATED USERS
+1 ;RETURNS: ^ IF USER QUIT OR TIMED OUT
+2 ; OTHERWISE, THE VALUE OF VARIABLE Y
+3 NEW DIR,X,Y,DTOUT,DUOUT,DIRUT,DIROUT
+4 SET DIR(0)="Y"_U
SET DIR("A",1)="Do you want to include DISUSERed and TERMINATED users"
+5 SET DIR("A")="in the output"
SET DIR("B")="NO"
+6 DO ^DIR
+7 if $DATA(DIRUT)
QUIT U
+8 QUIT Y