Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Info |  Source |  Call Graph |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  Used in RPC |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Naked Globals |  Local Variables |  Marked Items  | All
Print Page as PDF
Routine: DPTLK

Package: Registration

Routine: DPTLK


Information

DPTLK ;ALB/RMO,RTK,ARF,JAM - MAS Patient Look-up Main Routine ; 3/22/05 4:19pm

Source Information

Source file <DPTLK.m>

Call Graph

Call Graph

Call Graph Total: 29

Package Total Call Graph
Registration 15 $$CVEDT^DGCV  ($$FINDCUR,$$GET)^DGENA  $$CATEGORY^DGENA4  ($$FINDCUR,$$GET)^DGENEGT  $$ABOVE^DGENEGT1  $$EXT^DGENU  ^DGSEC  $$BADADR^DGUTL3  
(,SETDPT)^DPTLK1  ^DPTLK2  ($$VAADV,EP2)^DPTLK3  $$FILE^DPTLK4  ($$BS5,$$DMT,FFP)^DPTLK5  $$SEARCH^DPTLK7  $$TESTPAT^VADPT  
VA FileMan 7 CLRMSG^DDS  DO^DIC1  YN^DICN  DQ^DICQ  $$EXTERNAL^DILFD  $$GET1^DIQ  ^DIR  
Kernel 4 ENDR^%ZISS  $$FMTE^XLFDT  $$UP^XLFSTR  ($$IEN,$$LKUP)^XUAF4  
Master Patient Index VistA 3 CARDLOG^MPIFAPI  PATIENT^MPIFXMLP  CARDPV^MPIFXMLS  

Caller Graph

Legends:

Legend of Colors

Package Component Superscript legend

action A extended action Ea event driver Ed subscriber Su protocol O limited protocol LP run routine RR broker B edit E server Se print P screenman SM inquire I

Caller Graph

Caller Graph Total: 17

Package Total Caller Graph
Lab Service 3 LRHY0  LRHY01  LRHYAFT  
Registration 3 DG VIC PATIENT LOOKUP  DG5393PT  DGENACL1  
Inpatient Medications 2 PSJDPT  PSJIMO1  
Outpatient Pharmacy 2 PSOERPC0  PSOERX1A  
PCE Patient Care Encounter 2 PXDELFIX  ^AUPNPAT  
VA Point of Service 2 VPSPRINT  VPSRPC1  
Automated Lab Instruments 1 LA7VIN2  
Barcode Medication Administration 1 PSBRPC  
General Medical Record - Vitals 1 GMVRPCP  

Entry Points

Name Comments DBIA/ICR reference
EN ; -- Entry point
EN2
ASKPAT ; -- Prompt for patient
CHKPAT ; -- Custom Patient Lookup
CHKPAT1
MAG ; -- No patient found, check for mag stripe input, create stub
STOP ;
NOPAT ; -- No patient found, ask to add new
; DG*5.3*1031;jam; If in Load/Edit or Admit, and not in "Ask" mode (DIC(0)'["A"), then quit. This allows trigger code that does lookups which end up in this routine, to quit (and not call STOP and go back to ASKPAT)
; Otherwise, (per patch DG*5.3*993) do not allow adding a new patient and reprompt for the patient entry.
CHKDFN ; --
Q ; --
Q1 ; -- Clean up variables
QK
QK1
IX ; --
IATA(X) ; --
TRACK(X,START,END) ; find track where start/end are sentinels
FIELDS(IATA) ; -- Sets fields
BARCODE(X) ;
CACCARD(X) ;
EDIPI(EDIPI) ; - returns `DFN from EDIPI number
CARD(CARD) ; - returns `DFN from card number
VIC40(DGFLDS,DGVIC40,DGCAC) ; - returns the data used to create the
; patient file entry from mpi
ENR ;Display Enrollment information after patient selection
CV ;check for Combat Vet status
B32TO10(X) ; - convert from base 32 to base 10
RPCVIC(RETURN,DPTX) ; - patient lookup from VIC card, rpc/api
; non-interactive
; this function will return a patient's DFN based on input. input must
; be in the form of the FULL input from a VIC card (magstripe or bar
; code), the patient must be locally known (FULL doesn't but can contain
; additional card tracks)
; RETURN input should be passed by reference
  • ICR #5888
    • Status: Active
    • Usage: Controlled Subscription

    External References

    Name Field # of Occurrence
    ENDR^%ZISS ENR+21
    CLRMSG^DDS CHKDFN+6
    $$CVEDT^DGCV ENR+12, CV+2
    $$FINDCUR^DGENA ENR+2, CV+4
    $$GET^DGENA ENR+2, CV+4
    $$CATEGORY^DGENA4 ENR+3
    $$FINDCUR^DGENEGT ENR+14
    $$GET^DGENEGT ENR+15
    $$ABOVE^DGENEGT1 ENR+18
    $$EXT^DGENU ENR+5, ENR+10
    ^DGSEC CHKDFN+18
    $$BADADR^DGUTL3 Q+5
    DO^DIC1 CHKPAT+1
    YN^DICN CHKPAT+17, CHKDFN+14
    DQ^DICQ CHKPAT1+1
    $$EXTERNAL^DILFD ENR+4
    $$GET1^DIQ CHKDFN+3
    ^DIR MAG+10
    ^DPTLK1 CHKPAT1+28
    SETDPT^DPTLK1 CHKPAT1+5, CHKPAT1+10, CHKPAT1+22, CHKPAT1+28
    ^DPTLK2 NOPAT+4
    $$VAADV^DPTLK3 Q+6
    EP2^DPTLK3 MAG+17
    $$FILE^DPTLK4 MAG+22
    $$BS5^DPTLK5 CHKDFN+10
    $$DMT^DPTLK5 Q+19
    FFP^DPTLK5 Q+8
    $$SEARCH^DPTLK7 CHKPAT1+33
    CARDLOG^MPIFAPI IATA+26, BARCODE+16, EDIPI+3
    PATIENT^MPIFXMLP CHKPAT1+32
    CARDPV^MPIFXMLS VIC40+5
    $$TESTPAT^VADPT Q+4
    $$FMTE^XLFDT ENR+7, ENR+23, CV+5
    $$UP^XLFSTR ASKPAT+10, ASKPAT+13, RPCVIC+26
    $$IEN^XUAF4 CHKPAT1+19
    $$LKUP^XUAF4 EDIPI+4, CARD+2

    Interaction Calls

    Name Line Occurrences
    Function Call: WRITE
    • Prompt: !!?3,"Unable to proceed. Fileman version node ^DD(""VERSION"") is undefined."
    • Line Location: EN+3
    Function Call: READ
    • Variable: X(1)
    • Timeout: 1
    • Line Location: ASKPAT+12
    Function Call: WRITE
    • Prompt: !,"Could not add patient to patient file"
    • Line Location: MAG+15
    Function Call: WRITE
    • Prompt: !,"Could not add patient to patient file"
    • Line Location: MAG+23
    Function Call: WRITE
    • Prompt: !!?5,"Use Register A Patient option to add a new person."
    • Line Location: STOP+2
    Function Call: READ
    • Variable: X
    • Timeout: DTIME
    • Line Location: STOP+3
    Function Call: WRITE
    • Prompt: !!?5,"Press RETURN to continue..."
    • Line Location: STOP+3
    Function Call: WRITE
    • Prompt: *7,!,"WARNING : You may have selected a test patient."
    • Line Location: Q+4
    Function Call: WRITE
    • Prompt: *7,!,"WARNING : ** This patient has been flagged with a Bad Address Indicator."
    • Line Location: Q+5
    Function Call: WRITE
    • Prompt: *7,!,"** Patient is VA ADVANTAGE."
    • Line Location: Q+6
    Function Call: WRITE
    • Prompt: !?1,"Enrollment Priority: ",$S($G(DGENR("PRIORITY")):$$EXT^DGENU("PRIORITY",DGENR("PRIORITY")),1:""),$S($G(DGENR("SUBGRP"))="":"",1:$$EXT^DGENU("SUBGRP",$G(DGENR("SUBGRP"))))
    • Line Location: ENR+5
    Function Call: WRITE
    • Prompt: ?33,"Category: ",DGENCAT
    • Line Location: ENR+6
    Function Call: WRITE
    • Prompt: ?57,"End Date: ",$S($G(DGENR("END")):$$FMTE^XLFDT(DGENR("END"),"5DZ"),1:""),!
    • Line Location: ENR+7
    Function Call: WRITE
    • Prompt: ?1,"Enrollment Status: ",$S($G(DGENR("STATUS")):$$EXT^DGENU("STATUS",DGENR("STATUS")),1:"")
    • Line Location: ENR+10
    Function Call: WRITE
    • Prompt: IORVON
    • Condition for execution: $D(IORVON)
    • Line Location: ENR+22
    Function Call: WRITE
    • Prompt: "*** WARNING ***"
    • Line Location: ENR+22
    Function Call: WRITE
    • Prompt: IORVOFF
    • Condition for execution: $D(IORVOFF)
    • Line Location: ENR+22
    Function Call: WRITE
    • Prompt: !?14
    • Line Location: ENR+23
    Function Call: WRITE
    • Prompt: IORVON
    • Condition for execution: $D(IORVON)
    • Line Location: ENR+23
    Function Call: WRITE
    • Prompt: "*** PATIENT ENROLLMENT END",$S(DT>+DGENR("END"):"ED",1:"S")," EFFECTIVE ",$$FMTE^XLFDT(DGENR("END"),"5DZ")," ***"
    • Line Location: ENR+23
    Function Call: WRITE
    • Prompt: IORVOFF
    • Condition for execution: $D(IORVOFF)
    • Line Location: ENR+23
    Function Call: WRITE
    • Prompt: IORVON
    • Condition for execution: $D(IORVON)
    • Line Location: ENR+24
    Function Call: WRITE
    • Prompt: "*** PATIENT ENROLLMENT ENDING. ENROLLMENT END DATE IS NOT KNOWN. ***"
    • Line Location: ENR+24
    Function Call: WRITE
    • Prompt: IORVOFF
    • Condition for execution: $D(IORVOFF)
    • Line Location: ENR+24
    Function Call: WRITE
    • Prompt: !
    • Line Location: CV+4
    Function Call: WRITE
    • Prompt: ?3,"Combat Vet Status: "_$S($P(DGCV,U,3)=1:"ELIGIBLE",1:"EXPIRED"),?57,"End Date: "_$$FMTE^XLFDT($P(DGCV,U,2),"5DZ")
    • Line Location: CV+5
    Routine Call
    • DDS
    • Line Location:
      • CHKDFN+6
    Routine Call
    • DIR
    • Line Location:
      • MAG+10

    Used in RPC

    RPC Name Call Tags
    DG VIC PATIENT LOOKUP RPCVIC

    FileMan Files Accessed Via FileMan Db Call

    FileNo Call Tags
    ^DPT - [#2] Classic Fileman Calls,  GET1^DIQ
    ^DGEN(27.15 - [#27.15] EXTERNAL^DILFD

    Global Variables Directly Accessed

    Name Line Occurrences  (* Changed,  ! Killed)
    ^%ZOSF("EOFF" ASKPAT+12
    ^%ZOSF("EON" ASKPAT+12
    ^DD("OS" - [#.7] EN2+1, CHKPAT1+35
    ^DD("VERSION" EN+3, EN+4
    ^DD(2 IX+1
    ^DG(40.8 - [#40.8] Q+21
    ^DGCN(391.91 - [#391.91] CHKPAT1+19, CHKPAT1+21, EDIPI+5, CARD+3
    ^DISV( CHKPAT1+4, Q+2*
    ^DPT - [#2] CHKPAT1+9, CHKPAT1+28, CHKPAT1+36, CHKDFN+5, CHKDFN+11, CHKDFN+19, Q+2
    ^DPT("AXFFP" Q+8
    ^DPT("SSN" RPCVIC+28, RPCVIC+32
    ^DPT(0 EN+4, CHKPAT+17
    ^TMP("DGVIC" MAG+9

    Label References

    Name Line Occurrences
    $$B32TO10 BARCODE+14, CACCARD+14
    $$BARCODE ASKPAT+10, RPCVIC+30
    $$CACCARD ASKPAT+13, RPCVIC+31
    $$CARD IATA+27, BARCODE+17
    $$EDIPI CACCARD+15
    $$IATA ASKPAT+9, RPCVIC+29
    $$TRACK IATA+18
    @( MAG+14
    ASKPAT CHKPAT+8, CHKPAT+10, CHKPAT1+15, CHKPAT1+28, NOPAT+3, NOPAT+4, CHKDFN+1, CHKDFN+10, CHKDFN+18
    CHKDFN ASKPAT+15, CHKPAT+6, CHKPAT1+3, CHKPAT1+8, CHKPAT1+13, CHKPAT1+17, CHKPAT1+28
    CHKPAT CHKPAT1+28
    CHKPAT1 CHKPAT+13
    CV Q+13
    DPTLK IX+2
    EN2 MAG+5, MAG+12, MAG+15, MAG+20
    ENR Q+10
    NOPAT MAG+1
    Q QK
    Q1 MAG+6, MAG+12, MAG+15, MAG+20, QK1
    QK EN+2, EN+3, EN+4, ASKPAT+1, CHKPAT+8, CHKPAT+10, CHKPAT1+28, CHKDFN+1, CHKDFN+10, CHKDFN+18
    QK1 MAG+23, MAG+24, NOPAT+3, NOPAT+4
    STOP CHKPAT1+15, NOPAT+3

    Naked Globals

    Name Field # of Occurrence
    ^("OS" EN2+1, CHKPAT1+35
    ^("^DPT(" CHKPAT1+4
    ^(0 EN2+1, CHKPAT1+35, CHKDFN+5, Q+2

    Local Variables

    Legend:

    >> Not killed explicitly
    * Changed
    ! Killed
    ~ Newed

    Name Field # of Occurrence
    % CHKPAT+14~, CHKPAT+17*, CHKPAT+18, CHKDFN+10, CHKDFN+14*, CHKDFN+15
    BARCODE ASKPAT+7~, ASKPAT+8*, ASKPAT+10*, ASKPAT+12, ASKPAT+13, ASKPAT+15, MAG+1, RPCVIC+23~, RPCVIC+24*, RPCVIC+30*
    , RPCVIC+31
    CARD IATA+23~, IATA+24*, IATA+26, IATA+27, BARCODE+13~, BARCODE+14*, BARCODE+16, BARCODE+17, CARD~, CARD+3
    , CARD+4
    CNT FIELDS+2~, FIELDS+3*, FIELDS+5, FIELDS+6, FIELDS+7*
    D CHKPAT+11*, CHKPAT1+34!, Q1+1!, IX+1
    >> DDS CHKDFN+6
    >> DDSHBX CHKDFN+6
    >> DDXY CHKDFN+6
    DFN EDIPI+1~, EDIPI+5*, EDIPI+7, CARD+1~, CARD+3*, CARD+5
    DGCAC ASKPAT+7~, ASKPAT+8*, ASKPAT+13*, ASKPAT+15, MAG+1, VIC40~, VIC40+5
    DGCV CV+1~, CV+2*, CV+3, CV+5
    DGEDIPI CHKPAT1+18~, CHKPAT1+19*, CHKPAT1+20, CHKPAT1+21
    DGEGT ENR+1~, ENR+15*
    DGEGT("PRIORITY" ENR+16, ENR+18
    DGEGT("SUBGRP" ENR+18
    DGEGTIEN ENR+1~, ENR+14*, ENR+15
    DGENCAT ENR+1~, ENR+3*, ENR+4*, ENR+6
    DGENDFN ENR+1~
    DGENR ENR+1~, ENR+2, CV+4
    DGENR("END" ENR+7, ENR+23
    DGENR("PRIORITY" ENR+5, ENR+16, ENR+18
    DGENR("STATUS" ENR+9, ENR+10
    DGENR("SUBGRP" ENR+5, ENR+18
    DGFLDS MAG+15, MAG+22, Q1+6!, FIELDS+3*, FIELDS+4, FIELDS+6, FIELDS+9, FIELDS+10, FIELDS+11, VIC40~
    , VIC40+3*, VIC40+4, VIC40+6
    DGMPI VIC40+2~, VIC40+5
    DGMPI( VIC40+6
    DGNEW ASKPAT+2!
    DGOPT MAG+3~, MAG+4*, MAG+5
    DGPREFNM CHKDFN+2~, CHKDFN+3*, CHKDFN+5
    DGSEARCH EN+1~, ASKPAT+2!, CHKDFN+10
    DGVIC40 ASKPAT+7~, ASKPAT+8*, ASKPAT+12, CHKPAT+6, CHKPAT1+28, MAG+14, MAG+17, MAG+20, MAG+22, EDIPI+6*
    , CARD+4*, VIC40~, VIC40+5
    >> DIC EN2*
    >> DIC("A" ASKPAT+3
    >> DIC("B" ASKPAT+3, ASKPAT+5
    >> DIC("W" CHKPAT+2*, CHKPAT1+34!, Q1+1!
    >> DIC(0 EN+2, EN2*, ASKPAT+1, CHKPAT+8, CHKPAT+10, CHKPAT1+17, CHKPAT1+28, STOP+1, NOPAT+3, NOPAT+4
    CHKDFN+1, CHKDFN+5, CHKDFN+10, CHKDFN+18, Q+2, Q+4, Q+5, Q+6, Q+10, Q+13
    Q+19
    >> DICR Q1+2
    DIE EN+1~
    DIR MAG+11!
    DIR("A" MAG+8*
    DIR("B" MAG+8*
    DIR(0 MAG+8*
    >> DIVP CHKDFN+5
    DO EN2!, CHKPAT1+34!, Q1+1!
    DPTBTDT CHKDFN+18*, Q1+2!
    DPTCNT CHKPAT+4*, CHKPAT1+34!, Q1+1!
    DPTDFN EN+2!, CHKPAT1+6*, CHKPAT1+11*, CHKPAT1+17, CHKPAT1+23*, CHKPAT1+28*, CHKPAT1+32, CHKPAT1+33*, CHKPAT1+34*, CHKPAT1+36
    MAG+20, NOPAT+4, CHKDFN+1*, CHKDFN+3, CHKDFN+5, CHKDFN+10, CHKDFN+11, CHKDFN+15*, CHKDFN+18*, CHKDFN+19*
    Q+1, ENR+2, ENR+3, ENR+12, ENR+18, CV+2, CV+4
    DPTDIV Q+17~, Q+19*, Q+21
    >> DPTIDS( FIELDS+10*, FIELDS+11*
    DPTIFNS CHKPAT+3!, Q1+1!
    DPTIX Q1+1!, IX+1*
    DPTLSNME CHKDFN+11~*, CHKDFN+12
    >> DPTNOFZK QKQK1
    DPTNOFZY QK!, QK1!
    DPTS CHKPAT+3!, CHKPAT1+34!, Q1+1!
    DPTS( CHKPAT1+6, CHKPAT1+11, CHKPAT1+23, CHKPAT1+28, CHKPAT1+36*, CHKDFN+1, CHKDFN+5, CHKDFN+19, Q+1
    DPTSAVX EN+2!, EN2*, Q+1, Q1+3!
    DPTSEL CHKPAT+3!, CHKPAT1+34!, CHKDFN+5, Q1+3!
    DPTSSN CHKDFN+11~*, CHKDFN+13
    DPTSZ EN2+1*, CHKPAT1+34!, CHKPAT1+35*, Q1+3!
    DPTX EN+2!, EN2*, ASKPAT+1, ASKPAT+5*, ASKPAT+9*, ASKPAT+10*, ASKPAT+13*, ASKPAT+15, CHKPAT+6, CHKPAT+8
    CHKPAT+10, CHKPAT+12, CHKPAT1CHKPAT1+3, CHKPAT1+8, CHKPAT1+9, CHKPAT1+13, CHKPAT1+15, CHKPAT1+17, CHKPAT1+19
    CHKPAT1+28, CHKPAT1+33, CHKPAT1+34*, STOP+1, CHKDFN+19*, Q+1, Q1+3!, FIELDS+9*, RPCVIC~, RPCVIC+25
    , RPCVIC+26*, RPCVIC+27*, RPCVIC+28, RPCVIC+29*, RPCVIC+30*, RPCVIC+31*, RPCVIC+32
    DPTXX EN+1~, ASKPAT+5*, CHKPAT1+33, CHKPAT1+34*
    DPTZERO CHKDFN+11~*
    DR EN+1~
    DT ENR+23
    DTIME ASKPAT+4, STOP+3
    DTOUT EN2!, ASKPAT+2!, ASKPAT+5*, CHKPAT1+28, NOPAT+4
    DUOUT EN2!, ASKPAT+2!, ASKPAT+5*, CHKPAT1+28
    DUZ CHKPAT1+4, Q+2
    DUZ(2 Q+18, Q+19
    >> DX CHKDFN+6*
    >> DY CHKDFN+6*
    >> DZ CHKPAT+12*, CHKPAT+13, CHKPAT+19*
    EDIPI CACCARD+13~, CACCARD+14*, CACCARD+15, EDIPI~, EDIPI+3, EDIPI+5, EDIPI+6
    END TRACK~, TRACK+2
    FIELD FIELDS+2~, FIELDS+5*, FIELDS+6
    G Q1+1!
    GCHK ASKPAT+7~, MAG+9*
    I B32TO10+1~, B32TO10+3*
    IATA Q1+5!, IATA+14*, IATA+18*, IATA+20, IATA+27*, IATA+29, FIELDS~, FIELDS+1, FIELDS+5
    IORVOFF ENR+19~, ENR+22, ENR+23, ENR+24
    IORVON ENR+19~, ENR+22, ENR+23, ENR+24
    MAG ASKPAT+7~, ASKPAT+8*, ASKPAT+9*, ASKPAT+10, ASKPAT+13, ASKPAT+15, CHKPAT1+32, MAG+1, RPCVIC+23~, RPCVIC+24*
    , RPCVIC+29*, RPCVIC+30, RPCVIC+31
    RETURN RPCVIC~, RPCVIC+24*, RPCVIC+28*, RPCVIC+29, RPCVIC+30, RPCVIC+32*, RPCVIC+33*
    S B32TO10+1~*, B32TO10+3
    START TRACK~, TRACK+2
    U EN2*, EN2+1, CHKPAT1+35, CHKDFN+5, CHKDFN+11, CHKDFN+19, Q+2, Q+21, CV+3, CV+5
    VICFAC EDIPI+1~, EDIPI+4*, EDIPI+5, CARD+1~, CARD+2*, CARD+3
    X EN+2, EN2ASKPAT+4*, ASKPAT+5, ASKPAT+9*, ASKPAT+10*, ASKPAT+13*, CHKPAT1*, CHKPAT1+28, STOP+3*
    Q+1*, IATA~, IATA+15, IATA+16, IATA+18, IATA+22, IATA+24, TRACK~, TRACK+2, BARCODE~
    , BARCODE+14, CACCARD~, CACCARD+14, VIC40+2~, VIC40+6*, ENR+19~, ENR+20*, B32TO10~, B32TO10+2*, B32TO10+3
    X(1 ASKPAT+12*
    >> XQY0 CHKPAT1+32, MAG+4, NOPAT+3
    Y CHKPAT1+4*, CHKPAT1+5, CHKPAT1+6, CHKPAT1+9*, CHKPAT1+10, CHKPAT1+11, CHKPAT1+21*, CHKPAT1+22, CHKPAT1+23, CHKPAT1+28*
    CHKPAT1+34*, MAG+12, MAG+22*, MAG+23, NOPAT+4*, CHKDFN+5*, CHKDFN+18*, Q+1*, Q+2, Q+4
    Q+5, Q+6, Q+8, Q+10, Q+13, Q+19, B32TO10+1~*, B32TO10+3*, B32TO10+4
    Y(0 Q+2*

    Marked Items

    Name Field # of Occurrence
    $T(CARDPV^MPIFXMLS VIC40+5
    $T(PATIENT^MPIFXMLP CHKPAT1+32
    Info |  Source |  Call Graph |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  Used in RPC |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Naked Globals |  Local Variables |  Marked Items  | All