- ESPMNI1 ;DALISC/CKA - MASTER NAME INPUT-PART 2;5/92
- ;;1.0;POLICE & SECURITY;**14**;Mar 31, 1994
- CONT ;CONTINUE MASTER NAME INPUT
- S ESPJ=1
- AKA S DIR(0)="910.01,.01" D ^DIR K DIR G:$D(DUOUT)!($D(DTOUT)) NOU G:$D(DIRUT)&($E(Y)'="^") REM S ESPAKA(ESPJ)=Y I Y["^" D NO G AKA
- YN S DIR(0)="Y",DIR("A")="Do you want to enter another AKA",DIR("B")="NO" D ^DIR K DIR
- G:$D(DTOUT) NOU
- I Y'=1&(Y'=0) W !!,$C(7),?5,"You must enter Yes or No." G YN
- I Y S ESPJ=ESPJ+1 G AKA
- REM W !,"REMARKS: " S DIC="^TMP("_$J_",""MNI""," D EN^DIWE
- ;DISPLAY INFO BEFORE UPDATE
- DISP W !!,"Name: ",ESPD(.01),?40,"SSN: ",$S(ESPD(.02,"P")]"":ESPD(.02,"P"),1:ESPD(.02)),!,"DOB: ",ESPD(.03,"P"),?25,"SEX: ",ESPD(.08),?35,"RACE: ",ESPD(.09,"P")
- W !,"Height: ",ESPD(3.01),?15,"Weight: ",ESPD(3.02)
- W !,"Hair Color: ",ESPD(3.03,"P"),?35,"Eye Color: ",ESPD(3.04,"P"),?60,"Skin Tone: ",ESPD(3.05,"P")
- W !,"Scars/Marks: ",ESPD(3.06)
- W !,"DL#: ",ESPD(.1),?25,"STATE: ",ESPD(.11,"P"),!,"CATEGORY: ",ESPD(.04,"P")
- I ESPD(.04)'="E" W !,"Place of Employment: ",ESPD(.06),!,"Work Address: ",ESPD(2.01),!,"Work Address [line 2]: ",ESPD(2.02),!,"City: ",ESPD(2.03),?25,"State: ",ESPD(2.04,"P"),?65,"Zip: ",ESPD(2.05)
- I ESPD(.04)="E" W !,"Service: ",ESPD(.05,"P"),?60,"ID: ",ESPD(.07)
- W !,"Office Phone: ",ESPD(2.06),!,"Home Address: ",ESPD(1.01),!,"Home Address [line 2]: ",ESPD(1.02),!,"City: ",ESPD(1.03),?25,"State: ",ESPD(1.04,"P"),?65,"Zip: ",ESPD(1.05),!,"Home Phone: ",ESPD(1.06)
- F ESPJ=1:1 Q:'$D(ESPAKA(ESPJ)) W !,"ALIAS ",ESPJ,": ",ESPAKA(ESPJ)
- K ^UTILITY($J,"W") S DIWL=10,DIWR=70,DIWF="W" W !,"REMARKS: "
- S IEN=0 F ESPJ=0:0 S IEN=$O(^TMP($J,"MNI",IEN)) Q:IEN'>0 S X=^(IEN,0) D ^DIWP
- D ^DIWW
- OK ;UPDATE WILL BEGIN NOW
- D:$D(XRTL) T0^%ZOSV ; START
- STUFF W !!!,"Updating",!! K DD,DO S DIC="^ESP(910,",DIC(0)="L",DLAYGO=910,X=ESPD(.01) D FILE^DICN S ESPFN=+Y I '$P(Y,U,3) W !,$C(7),"This entry already exists!" G NOU
- L +^ESP(910,ESPFN):1 I '$T W !,"Another user is editing this record!!" G NOU
- S ^ESP(910,ESPFN,0)=ESPD(.01)_"^"_ESPD(.02)_"^"_ESPD(.03)_"^"_ESPD(.04)_"^"_ESPD(.05)_"^"_ESPD(.06)_"^"_ESPD(.07)_"^"_ESPD(.08)_"^"_ESPD(.09)_"^"_ESPD(.1)_"^"_ESPD(.11)
- S ^ESP(910,ESPFN,1)=ESPD(1.01)_"^"_ESPD(1.02)_"^"_ESPD(1.03)_"^"_ESPD(1.04)_"^"_ESPD(1.05)_"^"_ESPD(1.06),^(2)=ESPD(2.01)_"^"_ESPD(2.02)_"^"_ESPD(2.03)_"^"_ESPD(2.04)_"^"_ESPD(2.05)_"^"_ESPD(2.06)
- S ^ESP(910,ESPFN,3)=ESPD(3.01)_"^"_ESPD(3.02)_"^"_ESPD(3.03)_"^"_ESPD(3.04)_"^"_ESPD(3.05)_"^"_ESPD(3.06)
- SAKA S:$O(ESPAKA(0)) ^ESP(910,ESPFN,10,0)="^910.01^" K DD,DO S DIC="^ESP(910,"_ESPFN_",10,",DIC(0)="L",DLAYGO=910,DA(1)=ESPFN F ESPJ=1:1 Q:'$D(ESPAKA(ESPJ)) S X=ESPAKA(ESPJ) D FILE^DICN
- SREM S %X="^TMP("_$J_",""MNI"",",%Y="^ESP(910,"_ESPFN_",20," D %XY^%RCR K ^TMP($J,"MNI")
- XR S DIK="^ESP(910,",DA=ESPFN D IX1^DIK K DIK,DA
- W !,"Done",!!
- L -^ESP(910,ESPFN)
- S:$D(XRT0) XRTN=$T(+0) D:$D(XRT0) T1^%ZOSV ; STOP
- D FDISP^ESPMNI2
- EXIT W:$D(DTOUT) $C(7)
- K %X,%Y,DA,DD,DIC,DIK,DIR,DIRUT,DIWF,DIWL,DIWR,DO,DUOUT,ESPAKA,ESPD,ESPDOB,ESPJ,ESPNO,IEN,X,Y,^TMP($J,"MNI")
- Q:$D(DTOUT)
- G:ESPVAR=1 EN^ESPMNI
- G:ESPVAR=2 NUM^ESPVREG
- D:ESPVAR=3 RET
- D:ESPVAR=4 RETV
- QUIT QUIT
- NOU W !!,$C(7),?20,"NO UPDATING HAS OCCURRED!!!",!! K ESPAKA,ESPD,^TMP($J,"MNI") G:$D(DTOUT) EXIT G EN^ESPMNI
- NO W $C(7),!!?5,"NO ^'S ALLOWED!",!! Q
- RETV W !,"Now returning to the Violation Notice!"
- Q
- RET W !,"Now returning to the Offense Report!"
- Q
- --- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HESPMNI1 3410 printed Mar 13, 2025@21:34:47 Page 2
- ESPMNI1 ;DALISC/CKA - MASTER NAME INPUT-PART 2;5/92
- +1 ;;1.0;POLICE & SECURITY;**14**;Mar 31, 1994
- CONT ;CONTINUE MASTER NAME INPUT
- +1 SET ESPJ=1
- AKA SET DIR(0)="910.01,.01"
- DO ^DIR
- KILL DIR
- if $DATA(DUOUT)!($DATA(DTOUT))
- GOTO NOU
- if $DATA(DIRUT)&($EXTRACT(Y)'="^")
- GOTO REM
- SET ESPAKA(ESPJ)=Y
- IF Y["^"
- DO NO
- GOTO AKA
- YN SET DIR(0)="Y"
- SET DIR("A")="Do you want to enter another AKA"
- SET DIR("B")="NO"
- DO ^DIR
- KILL DIR
- +1 if $DATA(DTOUT)
- GOTO NOU
- +2 IF Y'=1&(Y'=0)
- WRITE !!,$CHAR(7),?5,"You must enter Yes or No."
- GOTO YN
- +3 IF Y
- SET ESPJ=ESPJ+1
- GOTO AKA
- REM WRITE !,"REMARKS: "
- SET DIC="^TMP("_$JOB_",""MNI"","
- DO EN^DIWE
- +1 ;DISPLAY INFO BEFORE UPDATE
- DISP WRITE !!,"Name: ",ESPD(.01),?40,"SSN: ",$SELECT(ESPD(.02,"P")]"":ESPD(.02,"P"),1:ESPD(.02)),!,"DOB: ",ESPD(.03,"P"),?25,"SEX: ",ESPD(.08),?35,"RACE: ",ESPD(.09,"P")
- +1 WRITE !,"Height: ",ESPD(3.01),?15,"Weight: ",ESPD(3.02)
- +2 WRITE !,"Hair Color: ",ESPD(3.03,"P"),?35,"Eye Color: ",ESPD(3.04,"P"),?60,"Skin Tone: ",ESPD(3.05,"P")
- +3 WRITE !,"Scars/Marks: ",ESPD(3.06)
- +4 WRITE !,"DL#: ",ESPD(.1),?25,"STATE: ",ESPD(.11,"P"),!,"CATEGORY: ",ESPD(.04,"P")
- +5 IF ESPD(.04)'="E"
- WRITE !,"Place of Employment: ",ESPD(.06),!,"Work Address: ",ESPD(2.01),!,"Work Address [line 2]: ",ESPD(2.02),!,"City: ",ESPD(2.03),?25,"State: ",ESPD(2.04,"P"),?65,"Zip: ",ESPD(2.05)
- +6 IF ESPD(.04)="E"
- WRITE !,"Service: ",ESPD(.05,"P"),?60,"ID: ",ESPD(.07)
- +7 WRITE !,"Office Phone: ",ESPD(2.06),!,"Home Address: ",ESPD(1.01),!,"Home Address [line 2]: ",ESPD(1.02),!,"City: ",ESPD(1.03),?25,"State: ",ESPD(1.04,"P"),?65,"Zip: ",ESPD(1.05),!,"Home Phone: ",ESPD(1.06)
- +8 FOR ESPJ=1:1
- if '$DATA(ESPAKA(ESPJ))
- QUIT
- WRITE !,"ALIAS ",ESPJ,": ",ESPAKA(ESPJ)
- +9 KILL ^UTILITY($JOB,"W")
- SET DIWL=10
- SET DIWR=70
- SET DIWF="W"
- WRITE !,"REMARKS: "
- +10 SET IEN=0
- FOR ESPJ=0:0
- SET IEN=$ORDER(^TMP($JOB,"MNI",IEN))
- if IEN'>0
- QUIT
- SET X=^(IEN,0)
- DO ^DIWP
- +11 DO ^DIWW
- OK ;UPDATE WILL BEGIN NOW
- +1 ; START
- if $DATA(XRTL)
- DO T0^%ZOSV
- STUFF WRITE !!!,"Updating",!!
- KILL DD,DO
- SET DIC="^ESP(910,"
- SET DIC(0)="L"
- SET DLAYGO=910
- SET X=ESPD(.01)
- DO FILE^DICN
- SET ESPFN=+Y
- IF '$PIECE(Y,U,3)
- WRITE !,$CHAR(7),"This entry already exists!"
- GOTO NOU
- +1 LOCK +^ESP(910,ESPFN):1
- IF '$TEST
- WRITE !,"Another user is editing this record!!"
- GOTO NOU
- +2 SET ^ESP(910,ESPFN,0)=ESPD(.01)_"^"_ESPD(.02)_"^"_ESPD(.03)_"^"_ESPD(.04)_"^"_ESPD(.05)_"^"_ESPD(.06)_"^"_ESPD(.07)_"^"_ESPD(.08)_"^"_ESPD(.09)_"^"_ESPD(.1)_"^"_ESPD(.11)
- +3 SET ^ESP(910,ESPFN,1)=ESPD(1.01)_"^"_ESPD(1.02)_"^"_ESPD(1.03)_"^"_ESPD(1.04)_"^"_ESPD(1.05)_"^"_ESPD(1.06)
- SET ^(2)=ESPD(2.01)_"^"_ESPD(2.02)_"^"_ESPD(2.03)_"^"_ESPD(2.04)_"^"_ESPD(2.05)_"^"_ESPD(2.06)
- +4 SET ^ESP(910,ESPFN,3)=ESPD(3.01)_"^"_ESPD(3.02)_"^"_ESPD(3.03)_"^"_ESPD(3.04)_"^"_ESPD(3.05)_"^"_ESPD(3.06)
- SAKA if $ORDER(ESPAKA(0))
- SET ^ESP(910,ESPFN,10,0)="^910.01^"
- KILL DD,DO
- SET DIC="^ESP(910,"_ESPFN_",10,"
- SET DIC(0)="L"
- SET DLAYGO=910
- SET DA(1)=ESPFN
- FOR ESPJ=1:1
- if '$DATA(ESPAKA(ESPJ))
- QUIT
- SET X=ESPAKA(ESPJ)
- DO FILE^DICN
- SREM SET %X="^TMP("_$JOB_",""MNI"","
- SET %Y="^ESP(910,"_ESPFN_",20,"
- DO %XY^%RCR
- KILL ^TMP($JOB,"MNI")
- XR SET DIK="^ESP(910,"
- SET DA=ESPFN
- DO IX1^DIK
- KILL DIK,DA
- +1 WRITE !,"Done",!!
- +2 LOCK -^ESP(910,ESPFN)
- +3 ; STOP
- if $DATA(XRT0)
- SET XRTN=$TEXT(+0)
- if $DATA(XRT0)
- DO T1^%ZOSV
- +4 DO FDISP^ESPMNI2
- EXIT if $DATA(DTOUT)
- WRITE $CHAR(7)
- +1 KILL %X,%Y,DA,DD,DIC,DIK,DIR,DIRUT,DIWF,DIWL,DIWR,DO,DUOUT,ESPAKA,ESPD,ESPDOB,ESPJ,ESPNO,IEN,X,Y,^TMP($JOB,"MNI")
- +2 if $DATA(DTOUT)
- QUIT
- +3 if ESPVAR=1
- GOTO EN^ESPMNI
- +4 if ESPVAR=2
- GOTO NUM^ESPVREG
- +5 if ESPVAR=3
- DO RET
- +6 if ESPVAR=4
- DO RETV
- QUIT QUIT
- NOU WRITE !!,$CHAR(7),?20,"NO UPDATING HAS OCCURRED!!!",!!
- KILL ESPAKA,ESPD,^TMP($JOB,"MNI")
- if $DATA(DTOUT)
- GOTO EXIT
- GOTO EN^ESPMNI
- NO WRITE $CHAR(7),!!?5,"NO ^'S ALLOWED!",!!
- QUIT
- RETV WRITE !,"Now returning to the Violation Notice!"
- +1 QUIT
- RET WRITE !,"Now returning to the Offense Report!"
- +1 QUIT