source: WorldVistAEHR/trunk/r/CONTROLLED_SUBSTANCES-PSD/PSDPATI.m@ 660

Last change on this file since 660 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 911 bytes
Line 
1PSDPATI ;B'ham ISC/BJW - Patient/Location Inquiry ; 11 Feb 98
2 ;;3.0; CONTROLLED SUBSTANCES ;**8**;13 Feb 97
3 ;**Y2K compliance**,"P" added to date input string
4 I '$D(PSDSITE) D ^PSDSET Q:'$D(PSDSITE)
5 I '$D(^XUSEC("PSD ERROR",DUZ)) W $C(7),!!,"Contact your Pharmacy Coordinator for access to display the",!,"Patient/Location data.",!!,"PSD ERROR security key required.",! Q
6PAT ;ask patient
7 K DA,DIC S DIC=2,DIC(0)="QEAMZ",DIC("A")="Select Patient Name: "
8 D ^DIC K DIC G:Y<0 END S DFN=+Y,PSDPAT=$P(Y,"^",2)
9DATE ;ask date
10 K DA,%DT S %DT="AEPT",%DT("A")="Enter Date of Stay: "
11 D ^%DT K %DT G:Y<0 END S VAINDT=+Y X ^DD("DD") S PSDT=Y
12INQ ;patient inquire
13 D INP^VADPT W @IOF,?15,"Patient Inquiry",!!,"Patient: ",PSDPAT,!,"Date of Stay: ",PSDT,!,"Ward Location: ",$P(VAIN(4),"^",2),!,"Room-Bed: ",$P(VAIN(5),"^"),!
14 D KVAR^VADPT K VA
15 G PAT
16END ;kills variables
17 K %DT,DA,DIC,DTOUT,DUOUT,PSDT,PSDPAT,X,Y
18 Q
Note: See TracBrowser for help on using the repository browser.