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

GMRCPRP.m

Go to the documentation of this file.
GMRCPRP ;SLC/DCM - Set protocol information into ^TMP global for print and display by List Manager ;5/20/98  14:20
 ;;3.0;CONSULT/REQUEST TRACKING;**1**;DEC 27, 1997
ENL ;;List manager entry point
 W !,"Compiling Report: Please Wait..."
EN ;Entry point
 K ^TMP("GMRCR",$J,"PRL"),ERMSG
 S FILE="101",FIELDS=".01;1;1.1;1.11;3.5;4;6;10*;12",FLAGS="EZ",TARGET="TMP",MSG="ERROR",TAB="",$P(TAB," ",50)="",GMRCCT=1
 S GMRCBXRF="GMRC"
 F  S GMRCBXRF=$O(^ORD(101,"B",GMRCBXRF)) Q:GMRCBXRF'["GMRC"!(GMRCBXRF="")  W "." S IENS=0,IENS=$O(^ORD(101,"B",GMRCBXRF,IENS)) D GETS^DIQ(FILE,IENS,FIELDS,FLAGS,"TMP","ERMSG") D
 .S GMRCPRNM=$E(TMP(FILE,IENS_",",.01,"E"),1,39),GMRCTXT=$S($D(TMP(FILE,IENS_",",1,"E")):$E(TMP(FILE,IENS_",",1,"E"),1,39),1:"")
 .S GMRCSYN=$S($D(TMP(FILE,IENS_",",1.1,"E")):TMP(FILE,IENS_",",1.1,"E"),1:""),GMRCPKG=$S($D(TMP(FILE,IENS_",",12,"E")):TMP(FILE,IENS_",",12,"E"),1:"")
 .S GMRCTYP=$S($D(TMP(FILE,IENS_",",4,"E")):TMP(FILE,IENS_",",4,"E"),1:"")
 .S GMRCFILK=$S($D(TMP(FILE,IENS_",",6,"E")):TMP(FILE,IENS_",",6,"E"),1:"")
 .S GMRCNM=$S($D(TMP(FILE,IENS_",",1.11,"E")):TMP(FILE,IENS_",",1.11,"E"),1:"")
 .S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)=GMRCPRNM_$E(TAB,1,40-$L(GMRCPRNM))_$E(GMRCTXT,1,39),GMRCCT=GMRCCT+1,^TMP("GMRCR",$J,"PRL",GMRCCT,0)="Type:"_$E(TAB,1,8)_GMRCTYP_$E(TAB,1,27-$L(GMRCTYP))_"Print Name: "_GMRCNM,GMRCCT=GMRCCT+1
 .S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)="Package:"_$E(TAB,1,5)_GMRCPKG_$E(TAB,1,27-$L(GMRCPKG))_"File Link:   "_GMRCFILK,GMRCCT=GMRCCT+1
 .I $O(TMP(FILE,IENS_",",3.5,0))?1N.N S GLOB="TMP("_FILE_","""_IENS_","""_",3.5)" D
 ..S LINE="Description: " D WPSET^GMRCUTIL(GLOB,"^TMP(""GMRCR"",$J,""PRL"")",LINE,.GMRCCT,TAB,1)
 ..Q
 .I $O(TMP(FILE,IENS_",",3.5,0))="E" S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)="Description:",GMRCCT=GMRCCT+1
 .S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)="Synonyms:"_$E(TAB,1,13)_$S($D(TMP(FILE,IENS_",",1.1,"E")):TMP(FILE,IENS_",",1.1,"E"),1:""),GMRCCT=GMRCCT+1
 .I $O(TMP(FILE_".01",""))="" S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)="Menu Items:",GMRCCT=GMRCCT+1
 .I $O(TMP(FILE_".01",""))]"" S GMRCSUB="",GMRCITM="Menu Items:  " F  S GMRCSUB=$O(TMP(FILE_".01",GMRCSUB)) Q:GMRCSUB=""  D
 ..I $D(TMP(FILE_".01",GMRCSUB,.01,"E")) S GMRCITM=$S('$L(GMRCITM):$E(TAB,1,13)_GMRCITM,1:GMRCITM)_TMP(FILE_".01",GMRCSUB,.01,"E"),GMRCMNE=TMP(FILE_".01",GMRCSUB,2,"E"),GMRCNO=$J(TMP(FILE_".01",GMRCSUB,3,"E"),3,0)
 ..I '$D(TMP(FILE_".01",GMRCSUB,.01,"E")),$L($O(ERMSG(0))) S GMRCITM=$E(TAB,1,13)_"Deleted Protocol: "_$G(ERMSG("DIERR",2,"PARAM",1)) K ERRMSG
 ..S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)=$E(GMRCITM_TAB,1,45)_GMRCNO_"   "_GMRCMNE,GMRCCT=GMRCCT+1,GMRCITM=""
 ..Q
 .K TMP S ^TMP("GMRCR",$J,"PRL",GMRCCT,0)="",GMRCCT=GMRCCT+1
 .Q
 S GMRCCT=GMRCCT-1
QUIT ;Kill off local globals and exit
 K CNT,FLG,LNO,LN1,IENS,FILE,FLAGS,FIELDS,GLOB,LINE,ERMSG,GMRCNM,GMRCNO,GMRCND,GMRCSYN,GMRCITM,GMRCMNE,GMRCPKG,GMRCSUB,GMRCFILK,GMRCTXT,GMRCTYP,GMRDCFLN,GMRCBXRF,GMRCPRNM,TARGET
 Q