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

IBDF16.m

Go to the documentation of this file.
  1. IBDF16 ;ALB/CJM - ENCOUNTER FORM - (edit Package Interfaces, Marking Areas) ;Jul 23,1993
  1. ;;3.0;AUTOMATED INFO COLLECTION SYS;;APR 24, 1997
  1. ;
  1. EDIT ;allows the user to create/edit/delete Package Interaces of type
  1. ;OUTPUT or SELECTION
  1. ;does not allow Package Interfaces that are part of the toolkit
  1. N IBTYPE S IBTYPE=""
  1. W @IOF
  1. D WARNING,PAUSE^IBDFU5
  1. W @IOF
  1. D TYPE
  1. D:IBTYPE INTRFACE
  1. Q
  1. TYPE ;asks the user what type of interface he wants to edit
  1. W !!,"OUTPUT interfaces are used to obtain data from other packages that will be",!,"displayed to DATA FIELDS."
  1. W !!,"SELECTION interfaces are used to obtain data from other packages that will be",!,"displayed to SELECTION LISTS."
  1. K DIR S DIR(0)="S^1:OUTPUT;2:SELECTION;"
  1. S DIR("A")="SELECT THE TYPE OF PACKAGE INTERFACE TO EDIT"
  1. S DIR("B")=1
  1. D ^DIR K DIR
  1. Q:$D(DIRUT)
  1. Q:'Y
  1. S IBTYPE=Y+1
  1. Q
  1. INTRFACE ;edit package interface
  1. ;IBTYPE=3 if type=selection interface
  1. ;IBTYPE=2 if type=output interface
  1. N REPORT,IBDELETE,IBNEW,INTRFACE,IBACTION,DLAYGO
  1. I $G(IBTYPE)'=2,$G(IBTYPE)'=3 Q
  1. S IBDELETE=1
  1. K DIC S DIC=357.6,DIC(0)="AELMQ",DIC("S")="I $P($G(^(0)),U,6)="_IBTYPE_",'$P($G(^(0)),U,12)"
  1. S D="E^D^B"
  1. S DIC("DR")="06////"_IBTYPE
  1. S DIC("A")="Select a PACKAGE INTERFACE: "
  1. S DLAYGO=357.6
  1. D MIX^DIC1 K DIC,D,DA
  1. Q:+Y<0
  1. S INTRFACE=+Y,IBNEW=$P(Y,"^",3)
  1. S IBDELETE=$S(IBNEW:1,1:0)
  1. S DA=INTRFACE
  1. K DIE,DR S DIE=357.6,DR="[IBDF EDIT OUTPUT/SELECTION RTN]",DIE("NO^")="BACKOUTOK"
  1. D ^DIE K DIE,DR,DA
  1. I IBDELETE K DA S DIK="^IBE(357.6,",DA=INTRFACE D ^DIK K DIK,DA
  1. Q
  1. LOOKUP ;additional help for the USER LOOKUP field
  1. W !!,"You can enter a list of words with which to index this interface. You will",!,"then be able to look up this interface by entering any word on the list."
  1. W !,"Each word should be at least 3 characters long, and words must be separated",!,"by a space.",!
  1. Q
  1. WARNING ;warns the user to lookup in the technical doc how to write Package Interfaces
  1. W !!,"You can write your own Package Interfaces to obtain data not available"
  1. W !,"through the Toolkit. Before you do so, however, please consult the technical",!,"documentation for the guidelines that must be followed. In particular, you"
  1. W !,"must know where the data should be placed and what format must be used.",!
  1. Q
  1. MARKING ;allows the user to create/edit/delete marking areas not in the toolkit
  1. N MARK,DLAYGO
  1. W @IOF,!!!!!
  1. W "You can create your own MARKING AREAS to supplement those that come with the",!,"toolkit. Marking areas are the areas on a selection list that the user",!,"marks to indicate selections from the list.",!!!!!
  1. D PAUSE^IBDFU5
  1. W @IOF
  1. K DIC S DIC=357.91,DIC(0)="AELMQ",DIC("S")="I '$P($G(^(0)),U,3)"
  1. ;S DIC("A")="Select "_$S(IBTYPE=2:"an output interface",3:"a selection interface")_": "
  1. S DLAYGO=357.91
  1. D ^DIC K DIC,D,DA
  1. Q:+Y<0
  1. S MARK=+Y,IBNEW=$P(Y,"^",3)
  1. S IBDELETE=$S(IBNEW:1,1:0)
  1. S DA=MARK
  1. K DIE,DR S DIE=357.91,DR="[IBDF EDIT MARKING AREA]",DIE("NO^")="BACKOUTOK"
  1. D ^DIE K DIE,DR,DA
  1. I IBDELETE K DA S DIK="^IBE(357.91,",DA=MARK D ^DIK K DIK,DA
  1. I IBNEW,'IBDELETE W !!,"New marking area created!"
  1. Q