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

ESPVNP.m

Go to the documentation of this file.
ESPVNP ;DALISC/CKA - PRINT VIOLATION NOTICE;12/92
 ;;1.0;POLICE & SECURITY;**5,12,14**;Mar 31, 1994
EN ;Prints Courtesy or U.S. District Court violations
VIO ;Entry point to print U.S. DISTRICT COURT VIOLATION NOTICES BY VIOLATION #.
 D DT^DICRW
NUM S DIC(0)="AEMZ",DIC("A")="VIOLATION #: ",DIC("S")="I $P(^(0),U,3)=""V""",DIC="^ESP(914,"
 D ^DIC G:$D(DTOUT)!($D(DUOUT)) EXIT G:Y<0 NUM
 S ESPID=+Y
Q S %ZIS="Q" D ^%ZIS G:POP EXIT I '$D(IO("Q")) U IO D START G EXIT
 S ZTRTN="START^ESPVNP",ZTSAVE("ESP*")="",ZTDESC="PRINT USDC VIOLATION NOTICE" D ^%ZTLOAD,HOME^%ZIS G EXIT
START ; BEGINS THE PRINT OF THIS VIOLATION NOTICE
 K ^UTILITY("DIQ1",$J) S TYPE=$P(^ESP(914,ESPID,0),U,3),(END,PAGE)=0 D HDR G:END EXIT
 S DIC="^ESP(914,",DA=ESPID,DR=".02;.04;.05;.06;.07;.08;.09;1.01;1.02;1.03;1.04;1.05;1.06;1.07;1.08;1.09;2.01;2.02;10",DIQ(0)="EI" D EN^DIQ1 I '$D(^UTILITY("DIQ1",$J,914,DA)) W !,"RECORD DOESN'T EXIST!" G EXIT
DTO W !,"DATE/TIME OF OFFENSE: ",$G(^UTILITY("DIQ1",$J,914,DA,.02,"E"))
OFF W !,"OFFENSE CHARGED: ",$G(^UTILITY("DIQ1",$J,914,DA,.04,"E"))
PO W !,"INVESTIGATING OFFICER: ",$G(^UTILITY("DIQ1",$J,914,DA,.06,"E"))
LOC W !,"LOCATION: ",$G(^UTILITY("DIQ1",$J,914,DA,.07,"E"))
DESC W !,"OFFENSE DESCRIPTION: ",$G(^UTILITY("DIQ1",$J,914,DA,.08,"E"))
NAM W !,"OFFENDER: ",$G(^UTILITY("DIQ1",$J,914,DA,.09,"E"))
 S ESPFN=$G(^UTILITY("DIQ1",$J,914,DA,.09,"I")) D:ESPFN
 .  S DIC="^ESP(910,",DA=ESPFN,DR=".03;.08;.09;.1;.11;1.01:1.06;3.01;3.02",DIQ(0)="E" D EN^DIQ1 I '$D(^UTILITY("DIQ1",$J,910,DA)) W !,"RECORD DOESN'T EXIST." Q
 .  W !,"DRIVER'S LICENSE #: ",$G(^UTILITY("DIQ1",$J,910,DA,.1,"E")),?40,"STATE: ",$G(^UTILITY("DIQ1",$J,910,DA,.11,"E"))
 .  W !,"HOME ADDRESS: ",$G(^UTILITY("DIQ1",$J,910,DA,1.01,"E"))
 .  I $G(^UTILITY("DIQ1",$J,910,DA,1.02,"E"))]"" W !?14,^("E")
 .  I $G(^UTILITY("DIQ1",$J,910,DA,1.03,"E"))]"" W !?14,^("E"),","
 .  W $G(^UTILITY("DIQ1",$J,910,DA,1.04,"E"))," ",$G(^UTILITY("DIQ1",$J,910,DA,1.05,"E"))
 .  Q:TYPE="C"
 .  W !,"HOME PHONE: ",$G(^UTILITY("DIQ1",$J,910,DA,1.06,"E"))
 .  W !,"BIRTH DATE: ",$G(^UTILITY("DIQ1",$J,910,DA,.03,"E"))
 .  W ?38,"SEX: ",$G(^UTILITY("DIQ1",$J,910,DA,.08,"E"))
 .  W !,"RACE: ",$G(^UTILITY("DIQ1",$J,910,DA,.09,"E"))
 .  W ?38,"HEIGHT: ",$G(^UTILITY("DIQ1",$J,910,DA,3.01,"E"))
 .  W ?55,"WEIGHT: ",$G(^UTILITY("DIQ1",$J,910,DA,3.02,"E"))
 S DA=ESPID
DEC W !,"DECAL # & COLOR: ",$G(^UTILITY("DIQ1",$J,914,DA,1.01,"E"))," ",$G(^UTILITY("DIQ1",$J,914,DA,1.02,"E"))
TAG W ?38,"TAG # & STATE: ",$G(^UTILITY("DIQ1",$J,914,DA,1.03,"E"))," ",$G(^UTILITY("DIQ1",$J,914,DA,1.04,"E"))
MAKE W !,"MAKE: ",$G(^UTILITY("DIQ1",$J,914,DA,1.05,"E"))
MOD W ?38,"MODEL: ",$G(^UTILITY("DIQ1",$J,914,DA,1.06,"E"))
STY W !,"STYLE: ",$G(^UTILITY("DIQ1",$J,914,DA,1.07,"E"))
VCOL W ?38,"VEHICLE COLOR: ",$G(^UTILITY("DIQ1",$J,914,DA,1.08,"E"))
YR W ?70,"YEAR: ",$G(^UTILITY("DIQ1",$J,914,DA,1.09,"E"))
 I TYPE="C" G EXIT
CRT W !,"COURT DATE: ",$G(^UTILITY("DIQ1",$J,914,DA,2.01,"E"))
REP W ?38,"DISPOSITION: ",$G(^UTILITY("DIQ1",$J,914,DA,2.02,"E"))
RMK K ^UTILITY($J,"W") S DIWL=3,DIWR=78,DIWF="W",IEN=0
 W !,"REMARKS: ",!
 F ESPN=1:1 S IEN=$O(^ESP(914,ESPID,10,IEN)) Q:IEN'>0  S X=^(IEN,0) D ^DIWP
 D ^DIWW
EXIT W:$D(DTOUT) $C(7)
 K %ZIS,DA,DIC,DIQ,DIR,DIRUT,DR,DTOUT,END,ESPDTR,ESPID,ESPN,ESPN1,IEN,PAGE,TYPE,X,Y,ZTDESC,ZTRTN,ZTSAVE
 K ^UTILITY("DIQ1",$J)
 D ^%ZISC
 QUIT
 ;
HDR ;PRINT HEADING
 I $E(IOST,1,2)="C-" S END=$$EOP^ESPUTIL() Q:END
 S PAGE=PAGE+1 W @IOF
 I TYPE="V" W !?26,"* * * VIOLATION NOTICE * * *",!
 W:TYPE="V" ?30,"VIOLATION #: ",$P(^ESP(914,ESPID,0),U,5)
 I TYPE="C" W !?21,"* * * COURTESY VIOLATION NOTICE * * *",?(IOM-10)
 W !
 QUIT
 ;
 ;ENTRY POINT CSY IS TO PRINT VIOLATIONS BY OFFENDER NAME
CSY S DIC(0)="AEMZ",DIC("A")="OFFENDER NAME: ",DIC="^ESP(914,"
 D ^DIC G:$D(DTOUT)!($D(DUOUT)) EXIT G:Y<0 CSY S ESPID=+Y
 D Q
 QUIT