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

DGRP.m

Go to the documentation of this file.
  1. DGRP ;ALB/MRL - REGISTRATION ENTRY POINT ;06 JUN 88@2300
  1. ;;5.3;Registration;**108,114,250,1040**;Aug 13, 1993;Build 15
  1. ;
  1. EN W ! S DIC="^DPT(",DIC(0)="AEQMZ" S:$S(('$D(DGRPV)#2):0,DGRPV:0,1:1) DIC(0)=DIC(0)_"L" D ^DIC
  1. I +Y'>0 D QQ^DGRPP Q
  1. K DIRUT,DUOUT,DTOUT
  1. S DFN=+Y I $P(Y,"^",3) D NEW
  1. K DA,DIC
  1. Q
  1. ;
  1. ; The following tags are used by external packages. Input DFN as
  1. ; IEN of PATIENT file. Consistency checker is automatically called.
  1. ; Screen edit allowed if DGRPV=0
  1. ;
  1. ENED S DGRPV=0
  1. EN1 I $G(DGRPV)=0 L +^DPT(DFN):3 E D MSG Q
  1. D ^DGRPV
  1. I $G(DGRPV)=0 L -^DPT(DFN)
  1. EN2 I $G(DGRPV)=0 L +^DPT(DFN):3 E D MSG Q
  1. D ^DGRP1
  1. ; DG*5.3*1040 - Display MT info, if no timeout
  1. I '+$G(DGRPOUT) D DISPMAS^DGMTCOU1(DFN) ;DIPLAY MT FILE CP STATUS
  1. I $G(DGRPV)=0 L -^DPT(DFN)
  1. Q
  1. ;
  1. VIEW S DGRPV=1 D EN Q:$S(('$D(Y)#2):1,Y'>0:1,1:0) D EN1 G VIEW
  1. ELV S DGRPV=1,DGELVER=1 D EN Q:$S(('$D(Y)#2):1,Y'>0:1,1:0) D G ELV
  1. . L +^DPT(DFN):3 E D MSG Q
  1. . D ENED
  1. . L -^DPT(DFN)
  1. ELVD Q:'$D(DFN)#2 S DGELVER=1,DGRPV=0 D EN1 Q
  1. ;
  1. NEW ;if new patient xecute new patient dr string (from patient type)
  1. ;called from DG10, DGPMV, DGRPTU and DGREG
  1. ;
  1. ;use DGRPX as scratch variable
  1. I $D(^DPT(DFN,"TYPE")),$D(^DG(391,+^("TYPE"),"DR")),^("DR")]"" X ^("DR") S DIE="^DPT(",DA=DFN D ^DIE
  1. K DGRPX Q
  1. ;
  1. MSG ;If lock fails:
  1. W *7,!!,"Patient is being edited. Try again later."
  1. Q
  1. ;
  1. ;
  1. RTNS ;The following is the numbering scheme for the DGRP routines
  1. ;
  1. ; DGRP : routine driver for registration screens
  1. ; DGRP_n : routine for screen n where 1<=n<=15
  1. ; DGRPE* : screen edit routines where line tag xy contains the
  1. ; DR string to edit. x = screen number, y = edit item
  1. ; DGRPH : help processor to display editable screens/data elements
  1. ; DGRPP : screen processor (controls display of high intensity, etc)
  1. ; DGRPU : utility routine (contains screen header, etc.)
  1. ; DGRPV : defines variables necessary for registration screens
  1. ;
  1. ; DGRPC* : consistency checker
  1. ; DGRPD* : data displays (pt inquiries)
  1. ;
  1. ;Variables set:
  1. ;
  1. ; DGRPV : 0 allows edit of data ; 1 for view
  1. ; DGELVER : 1 if eligibility verification ; '$D otherwise
  1. ;
  1. ;
  1. ;
  1. FILE ; The following are the numbering schemes for fields in the
  1. ; TYPE OF PATIENT file
  1. ;
  1. ; Fields 1-15 will be a set of codes denoting whether or not a certain
  1. ; screen is on or off for that type of patient. Only certain
  1. ; screens can be turned off, so not all field numbers will be
  1. ; taken.
  1. ;
  1. ; Data from these fields can be found on node S in the same
  1. ; piece position as the field number.
  1. ;
  1. ; Fields 11-149 will be a set of codes denoting whether a certain data
  1. ; element is on or off for editing. The field number is equal
  1. ; to SCREEN #_ITEM #.
  1. ;
  1. ; Items in these field numbers are on the E node in the same
  1. ; piece position as the field number.
  1. ;
  1. ; note: because fileman does not take more than 100 pieces on
  1. ; a node, items on screen 10 or higher were put on node
  1. ; E10 on piece SCREEN#_ITEM#-100.
  1. ;
  1. Q