XUSER ;ISP/RFR - A common set of user functions ;06/09/15 10:51
Source file <XUSER.m>
Name | Comments | DBIA/ICR reference |
---|---|---|
LOOKUP(XUF) | ;Do a user lookup
|
|
LK1 | ||
LKX | ||
ACTIVE(XUDA) | ;Get if a user is active.
|
|
BULL | ;Called from bulletin in DD of file #200 for 'Sub Alt Name' fld.
|
|
PROVIDER(XUDA,XUF) | ;See if user qualifies as a CPRS provider
|
|
DEA(FG,IEN,DATE,RXDEA) | ;sr. ef. Return users DEA # or Facility DEA_"-"_user VA# or null
|
|
DETOX(IEN,DATE) | ;*689 - Returns the Detox # from file 8991.9/200 - p580/REM
|
|
SDEA(FG,IEN,PSDEA,DATE,IDEA,INIEN) | ;validation for new DEA regulations p580-JC(CPRS)
|
|
CVA | ; VA number
|
|
SCHK(DEA,PSDEA,N3) | ;
|
|
GVA(INIEN) | ; Find Facility DEA and VA #
; INN - Pointer to INSTITUTION file (#4) |
|
VDEA(RETURN,IEN) |
|
|
DIV4(XUROOT,XUDUZ) | ;Return the Divisions that this user is assigned to.
|
|
VDEADNA(RETURN,NPIEN,DNDEAIEN) | ||
VDEADNM(RETURN,NPIEN) | ||
NAME(IEN,FL) | ;Return the full name from Name Components file
|
|
HL7(IEN) | ;Return a HL7 name from the components file
|
|
SCR200() | ;Whole File Screen logic for file 200
; ZEXCEPT: DIC,DINDEX - Kernel exemption |
|
PRDEA(IEN) | ; 689 - Return Prescriber's active DEA
; IEN-Prescriber DUZ from file 200 |
|
PRXDT(IEN) | ; 689 - Return Prescriber's default DEA Expiration Date
; IEN-Prescriber DUZ from file 200 |
|
PRSCH(IEN) | ; 689 - Return Prescriber's default DEA schedules
; IEN-Prescriber DUZ from file 200 |
|
DEAXDT(DEA) | ; 689 - Return Expiration Date for DEA
; DEA-DEA Number. Example: AH1966007 |
|
DEASCH(DEA) | ; 689 - Return DEA Schedules for DEA number
; DEA-DEA Number. Example: AH1966007 |
Name | Field # of Occurrence |
---|---|
^DIC | LK1 |
$$FIND1^DIC | BULL+5 |
$$GET1^DID | VDEA+39 |
$$GET1^DIQ | DETOX+11, DETOX+12, DETOX+13, DETOX+14, DETOX+19 |
^DIR | LK1+3 |
$$FMADD^XLFDT | SDEA+45 |
$$FMTE^XLFDT | LK1+1 |
$$HLNAME^XLFNAME | HL7+2 |
$$NAMEFMT^XLFNAME | NAME+4 |
$$REPLACE^XLFSTR | VDEA+39 |
$$STRIP^XLFSTR | VDEA+30 |
$$GET^XPAR | DEA+46, SDEA+18 |
PARENT^XUAF4 | DEA+50, GVA+6 |
$$DEASCH^XUPSPRA | DEASCH+2 |
$$DEAXDT^XUPSPRA | DEAXDT+2 |
$$PRDEA^XUPSPRA | PRDEA+2 |
$$PRSCH^XUPSPRA | PRSCH+2 |
$$PRXDT^XUPSPRA | PRXDT+2 |
$$VDEADNA^XUSER3 | VDEADNA+1 |
$$VDEADNM^XUSER3 | VDEA+10, VDEADNM+1 |
Name | Line Occurrences |
---|---|
Function Call: WRITE |
|
Routine Call |
|
Routine Call |
|
Routine Call |
|
Name | Line Occurrences (* Changed, ! Killed) |
---|---|
^DD("DD" | SDEA+28, SDEA+31, SDEA+49 |
^DIC(4 - [#4] | DEA+48, DEA+51, DEA+53, GVA+4, GVA+7, GVA+9 |
^VA(200 - [#200] | ACTIVE+2, ACTIVE+3, ACTIVE+5, BULL+6, PROVIDER+10, PROVIDER+26, PROVIDER+27, DEA+11, DEA+12, DEA+17 , DEA+18, DEA+21, DEA+22, DEA+27, DEA+33, DEA+39, DETOX+10, DETOX+27, SDEA+13, SDEA+14 , SDEA+20, SDEA+22, SDEA+23, SDEA+29, SDEA+33, SDEA+36, SDEA+48, CVA+4, VDEA+10, VDEA+19 , VDEA+22, VDEA+25, VDEA+28, VDEA+30, VDEA+37, VDEA+42, VDEA+52, DIV4+4 |
^XTV(8991.9 - [#8991.9] | DEA+19, DEA+23, DEA+24, DEA+30, DEA+31, DEA+36, DEA+37, SDEA+24, SDEA+25, SDEA+29 , SDEA+36, SDEA+43, SDEA+45, SDEA+47, SDEA+48 |
^XUSEC("ORES" | VDEA+17 |
^XUSEC("XUORES" | PROVIDER+13 |
^XUSEC("XUSHOWSSN" | SCR200+10 |
Name | Field # of Occurrence |
---|---|
^( | DIV4+4 |
>> | Not killed explicitly |
* | Changed |
! | Killed |
~ | Newed |
Name | Field # of Occurrence |
---|---|
% | ACTIVE+1~, ACTIVE+6*, PROVIDER+5~, PROVIDER+20*, DIV4+3~*, DIV4+4* |
%1 | DIV4+3~*, DIV4+4*, DIV4+5 |
A | SDEA+9~ |
A( | SCHK+4* |
A(1 | SCHK+5 |
A(2 | SCHK+6 |
A(3 | SCHK+7 |
A(4 | SCHK+8 |
A(5 | SCHK+9 |
A(6 | SCHK+10 |
ALTRET | DEA+8~, DEA+15*, DEA+30, DEA+33*, DEA+34*, DEA+36, DEA+39*, DEA+40 |
AR1 | DETOX+8~ |
AR1( | DETOX+21 |
AR1(9999999 | DETOX+19* |
AR2 | DETOX+8~ |
AR2( | DETOX+22 |
AR2(9999999 | DETOX+20* |
AR3 | DETOX+8~ |
AR3( | DETOX+24 |
AR3(9999999 | DETOX+16* |
AR4 | DETOX+8~ |
AR4( | DETOX+16*, DETOX+25 |
ASCHED | VDEA+33~, VDEA+35*, VDEA+42*, VDEA+43, VDEA+44 |
DATE | DEA~, DEA+10*, DEA+20, DEA+27, DEA+28, DEA+32, DEA+38, DEA+55, DETOX~, DETOX+9* , DETOX+16, DETOX+17, DETOX+29, DETOX+30, SDEA~, SDEA+10*, SDEA+28, SDEA+29, SDEA+31, SDEA+36 , SDEA+45, SDEA+46, SDEA+49, GVA+11, VDEA+8~, VDEA+25*, VDEA+26 |
DEA | DEA+8~, SDEA+9~, SDEA+13*, SDEA+27*, SDEA+30, SDEA+33, SDEA+35*, SDEA+37, SDEA+41*, SDEA+42 , SDEA+43, SDEA+46, CVA+4, CVA+5, CVA+6, SCHK~, SCHK+5, SCHK+6, SCHK+7, SCHK+8 , SCHK+9, SCHK+10, SCHK+11, GVA+11*, VDEA+8~, DEAXDT~, DEAXDT+2, DEASCH~, DEASCH+2 |
DEARR | SDEA+9~, SDEA+12*, SDEA+28*, SDEA+31, SDEA+32 |
DEATYP | SDEA+9~, SDEA+24*, SDEA+29, SDEA+36, SDEA+47~*, SDEA+48 |
DELIMIT | VDEA+45~, VDEA+46*, VDEA+48*, VDEA+49 |
DET | DETOX+8~*, DETOX+14*, DETOX+16, DETOX+18, DETOX+19, DETOX+20, DETOX+28*, DETOX+29, DETOX+30 |
DIC | LOOKUP+4~, LK1* |
DIC(0 | LK1*, SCR200+4 |
>> DINDEX | SCR200+7 |
DIR | LOOKUP+4~ |
DIR("A" | LK1+3* |
DIR("B" | LK1+3* |
DIR(0 | LK1+3* |
>> DIRUT | LK1+4 |
DNDEAIEN | VDEADNA~, VDEADNA+1 |
DT | LK1+1, ACTIVE+6, PROVIDER+20, DEA+10, DETOX+9, SDEA+10, VDEA+26 |
DUZ | DEA+9, DIV4+3, SCR200+10 |
DUZ(2 | DEA+9, GVA+3 |
E | SDEA+9~, SDEA+12*, SDEA+13*, SDEA+21, SDEA+31*, SDEA+32*, SDEA+34*, SDEA+38*, SDEA+39*, SDEA+40 |
ERROR | VDEA+38~ |
FAIL | DEA+8~, DEA+46*, DEA+47 |
FB | DEA+8~, DEA+14*, DEA+43, SDEA+9~, SDEA+13*, SDEA+15*, SDEA+32, CVA+2 |
FG | DEA~, DEA+9*, DEA+44, SDEA~, SDEA+16* |
FL | NAME~, NAME+2*, NAME+3*, NAME+4 |
FOVR | SDEA+9~, SDEA+18*, SDEA+31, SDEA+49 |
I | BULL+4~, BULL+6*, DEA+8~, DEA+17*, DEA+18, DETOX+8~, DETOX+10*, DETOX+11, DETOX+21*, DETOX+22* , DETOX+24*, DETOX+25*, SDEA+9~, SCHK+4* |
IDEA | SDEA~, SDEA+16*, SDEA+19, SDEA+20, SDEA+21, SDEA+35, SDEA+41 |
IEN | DEA~, DEA+9*, DEA+11, DEA+12, DEA+17, DEA+18, DEA+21, DEA+22, DEA+27, DEA+33 , DEA+39, DETOX~, DETOX+7, DETOX+10, DETOX+11, DETOX+27, SDEA~, SDEA+13, SDEA+14, SDEA+16* , SDEA+20, SDEA+22, SDEA+23, SDEA+29, SDEA+33, SDEA+36, SDEA+48, CVA+4, VDEA~, VDEA+10 , VDEA+12, VDEA+17, VDEA+19, VDEA+22, VDEA+25, VDEA+28, VDEA+30, VDEA+37, VDEA+42, VDEA+52 , NAME~, NAME+1, HL7~, HL7+1, PRDEA~, PRDEA+2, PRXDT~, PRXDT+2, PRSCH~, PRSCH+2 |
IN | DEA+8~, DEA+48*, DEA+49, DEA+51*, DEA+55, GVA+2~, GVA+4*, GVA+5, GVA+7*, GVA+11 |
INDEX | VDEA+45~, VDEA+47*, VDEA+48, VDEA+49 |
INIEN | SDEA~, SDEA+11*, SDEA+33, CVA+1*, CVA+4, GVA~, GVA+3 |
ININN | GVA+2~ |
INN | DEA+8~, DEA+9*, DEA+48, DEA+50, DEA+51*, DEA+53, GVA+2~, GVA+3*, GVA+4, GVA+6 , GVA+7*, GVA+9 |
J | DEA+8~, DEA+18*, DEA+19, DEA+21*, DEA+22, DEA+27, DEA+33, DEA+39, DETOX+8~, DETOX+11* , DETOX+12, DETOX+13, DETOX+14, DETOX+19, SDEA+9~, SDEA+22*, SDEA+23 |
K | DEA+8~, DEA+22*, DEA+23, DEA+24, DEA+30, DEA+31, DEA+36, DEA+37, SDEA+9~, SDEA+23* , SDEA+24, SDEA+25, SDEA+29, SDEA+36 |
LABEL | VDEA+38~, VDEA+39*, VDEA+40*, VDEA+41 |
N | DEA+8~, DEA+11*, DEA+13, DEA+14, DETOX+8~*, DETOX+15*, DETOX+16, DETOX+27*, DETOX+28, SDEA+9~ , SDEA+13*, SDEA+15, SDEA+25*, SDEA+26, SDEA+27, SDEA+35, SDEA+43*, SDEA+44, SDEA+45, SDEA+47 , SDEA+48 |
N1 | DEA+8~, DETOX+8~, DETOX+27*, DETOX+28 |
N3 | SDEA+9~, SDEA+13*, SDEA+29*, SDEA+30, SDEA+33*, SDEA+36*, SDEA+37, SDEA+46, SDEA+48*, CVA+4* , CVA+6, SCHK~, SCHK+1, SCHK+3, SCHK+4 |
NA | NAME+1~, NAME+4, HL7+1~, HL7+2 |
NA("FIELD" | NAME+1*, HL7+1* |
NA("FILE" | NAME+1*, HL7+1* |
NA("IENS" | NAME+1*, HL7+1* |
NODE | VDEA+29~, VDEA+30*, VDEA+31, VDEA+32 |
NODEA | VDEA+8~, VDEA+21* |
NP | DEA+22*, DETOX+8~*, DETOX+11*, DETOX+26 |
NPIEN | VDEADNA~, VDEADNA+1, VDEADNM~, VDEADNM+1 |
NVA | DEA+8~, DEA+12*, DEA+14, SDEA+9~, SDEA+14*, SDEA+15 |
PIECE | VDEA+33~, VDEA+36*, VDEA+37, VDEA+39, VDEA+40, VDEA+42 |
PSD | BULL+4~, BULL+5*, BULL+6 |
PSDEA | SDEA~, SDEA+16*, SDEA+17, SDEA+30, SDEA+33, SDEA+37, SDEA+46, CVA+6, SCHK~, SCHK+2 , SCHK+5, SCHK+6, SCHK+7, SCHK+8, SCHK+9, SCHK+10 |
RET | DEA+8~, DEA+15*, DEA+16, DEA+20*, DEA+25*, DEA+26, DEA+27*, DEA+28*, DEA+30, DEA+36 , DEA+40, DEA+41, DEA+42, DEA+47 |
RETURN | VDEA~, VDEA+10, VDEADNA~, VDEADNA+1, VDEADNM~, VDEADNM+1 |
RETURN("Does | not hold the ORES security key." , VDEA+18* |
RETURN("Has n | either a DEA number nor a VA number." , VDEA+23* |
RETURN("Is no | longer able to write medication orders (inactive date)." , VDEA+27*, t authorized to write medication orders." , VDEA+20*, t permitted to prescribe any schedules." , VDEA+31*, VDEA+52* |
RETURN("Is pe | rmitted to prescribe all schedules." , VDEA+43*, rmitted to prescribe schedule" , VDEA+50* |
RETURN("User | account does not exist." , VDEA+13*, account status: " , VDEA+15*, cannot sign on." , VDEA+14* |
RETVAL | VDEA+8~, VDEA+12*, VDEA+13*, VDEA+14*, VDEA+15*, VDEA+16, VDEA+18*, VDEA+20*, VDEA+23*, VDEA+27* , VDEA+31*, VDEA+52*, VDEA+53 |
RXDEA | DEA~, DEA+9*, DEA+16, DEA+17, DEA+20 |
SCHED | VDEA+33~, VDEA+41*, VDEA+47, VDEA+48, VDEA+49, VDEA+50 |
SMATCH | SDEA+9~, SDEA+12*, SDEA+21, SDEA+22, SDEA+38*, SDEA+39*, SDEA+40*, CVA+6*, CVA+7 |
SMATCHIP | SDEA+9~, SDEA+12*, SDEA+28*, SDEA+30*, SDEA+38, SDEA+39, SDEA+40 |
SMATCHNP | SDEA+9~, SDEA+12*, SDEA+35, SDEA+37*, SDEA+39 |
SMATCHVA | SDEA+9~, SDEA+33*, SDEA+34, SDEA+40 |
SPEC | VDEA+33~, VDEA+39 |
SPEC("SCHEDUL | E " , VDEA+34* |
STATUS | VDEA+8~, VDEA+10*, VDEA+12*, VDEA+13, VDEA+14, VDEA+15, VDEA+16 |
SUF | DEA+33~*, DEA+34 |
TEXT | VDEA+45~, VDEA+49*, VDEA+50 |
U | LK1+1, LK1+3, ACTIVE+3, ACTIVE+4, ACTIVE+5, ACTIVE+6, PROVIDER+16, PROVIDER+20, DEA+13, DEA+14 , DEA+18, DEA+19, DEA+22, DEA+23, DEA+24, DEA+27, DEA+30, DEA+31, DEA+33, DEA+36 , DEA+37, DEA+39, DEA+48, DEA+51, DEA+53, DETOX+28, SDEA+13, SDEA+15, SDEA+23, SDEA+24 , SDEA+26, SDEA+27, SDEA+28, SDEA+35, SDEA+45, SDEA+47, SDEA+49, SCHK+4, GVA+4, GVA+7 , GVA+9, VDEA+15, VDEA+19, VDEA+22, VDEA+25, VDEA+30, VDEA+37, VDEA+41, VDEA+42, VDEA+47 , VDEA+48, VDEA+49, VDEA+50, DIV4+4 |
VA | DEA+8~, DEA+13*, DEA+44, DEA+55, SDEA+9~, SDEA+13*, SDEA+19, SDEA+32, CVA+3, GVA+11 |
VDEA | DETOX+8~*, DETOX+17* |
X1 | ACTIVE+1~, ACTIVE+2*, ACTIVE+3, ACTIVE+4, ACTIVE+6, PROVIDER+5~, PROVIDER+10*, PROVIDER+16, PROVIDER+20 |
X2 | ACTIVE+1~, ACTIVE+2*, ACTIVE+3*, ACTIVE+4*, ACTIVE+5*, ACTIVE+6*, ACTIVE+7, PROVIDER+5~, PROVIDER+10* |
XDT | DEA+8~, DEA+19*, DEA+20, DEA+24*, DEA+25, DEA+27, DEA+28, DEA+31*, DEA+32, DEA+37* , DEA+38, DETOX+8~, DETOX+13*, DETOX+16, DETOX+17, DETOX+19, DETOX+20, DETOX+28*, DETOX+29, DETOX+30 , SDEA+9~, SDEA+26*, SDEA+28, SDEA+29, SDEA+31, SDEA+36, SDEA+45*, SDEA+46, SDEA+49 |
>> XMY( | BULL+6* |
XU1 | DEA+50~, GVA+6~ |
XU1("P" | DEA+51, GVA+7 |
XUDA | LOOKUP+4~, LK1*, LK1+1*, LK1+3, LK1+4*, LKX, ACTIVE~, ACTIVE+2, ACTIVE+3, ACTIVE+5 , PROVIDER~, PROVIDER+7, PROVIDER+10, PROVIDER+13, PROVIDER+26, PROVIDER+27 |
XUDUZ | DIV4~, DIV4+3*, DIV4+4 |
XUEXDT | DEA+53~*, DEA+54*, DEA+55, GVA+9~*, GVA+10*, GVA+11 |
XUF | LOOKUP~, LK1+1, LK1+2, PROVIDER~, PROVIDER+26 |
XUORES | PROVIDER+5~, PROVIDER+13*, PROVIDER+20, PROVIDER+23 |
XUROOT | DIV4~ |
XUROOT( | DIV4+4* |
Y | LOOKUP+4~, LK1, LK1+1*, LK1+4, SDEA+9~, SDEA+28*, SDEA+31*, SDEA+49* |
Y(0 | LK1+1 |