[613] | 1 | TIUSRVE ; SLC/JER - Get Upload Events for Display ;21-OCT-1999 10:54:57
|
---|
| 2 | ;;1.0;TEXT INTEGRATION UTILITIES;**56,81**;Jun 20, 1997
|
---|
| 3 | GET(TIUDA,HUSH) ; Build ^TMP("TIUEVENT",$J,
|
---|
| 4 | N TIUI,TIUJ,TIUL,TIUREC,X S TIUI=0,HUSH=+$G(HUSH)
|
---|
| 5 | N DA,DIC,DIQ,DR,TIUNAME K ^TMP("TIUEVENT",$J)
|
---|
| 6 | I '$D(IOINORM) S X="IOINORM;IOIHI;IORVON;IORVOFF;IOUON;IOUOFF;IOBON;IOBOFF" D ENDR^%ZISS
|
---|
| 7 | S:'$D(VALMAR) VALMAR="^TMP(""TIUEVENT"",$J)"
|
---|
| 8 | S VALMEVL=+$G(VALMEVL)
|
---|
| 9 | I '$D(^TIU(8925.4,+TIUDA,0)) S VALMQUIT=1 Q
|
---|
| 10 | S DIC=8925.4,DIQ="TIUREC(",DA=TIUDA
|
---|
| 11 | S DR=".01:.08"
|
---|
| 12 | D EN^DIQ1
|
---|
| 13 | S TIUI="" F S TIUI=$O(TIUREC(8925.4,+TIUDA,TIUI)) Q:+TIUI'>0 D
|
---|
| 14 | . I $G(TIUREC(8925.4,+TIUDA,TIUI))']"" S TIUREC(8925.4,+TIUDA,TIUI)="None"
|
---|
| 15 | I $D(TIUREC)>9 D
|
---|
| 16 | . S ^TMP("TIUEVENT",$J,0)=$G(TIUREC(8925.4,TIUDA,.08))
|
---|
| 17 | . D EVENT(.TIUREC,HUSH),FIELDS(TIUDA,.VALMCNT),HEADER(TIUDA,.VALMCNT)
|
---|
| 18 | ; The following line was Removed with TIU*1*56
|
---|
| 19 | ;S:+$G(VALMCNT)<$G(VALM("LINES")) VALMCNT=$G(VALM("LINES"))
|
---|
| 20 | Q
|
---|
| 21 | EVENT(TIUREC,HUSH) ; Load Source Information
|
---|
| 22 | N OFFSET,START
|
---|
| 23 | S OFFSET=2,START=1
|
---|
| 24 | W:'+$G(HUSH) !!,"Opening "_TIUREC(8925.4,+TIUDA,.08)_" record for review..."
|
---|
| 25 | D SET(START,OFFSET," Event Description ",IORVON,IORVOFF)
|
---|
| 26 | D SET(START+1,OFFSET,$G(TIUREC(8925.4,TIUDA,.04)))
|
---|
| 27 | D SET(START+2,OFFSET," Event Date/time: "_$G(TIUREC(8925.4,TIUDA,.01)))
|
---|
| 28 | D SET(START+3,OFFSET," User Name: "_$G(TIUREC(8925.4,TIUDA,.02)))
|
---|
| 29 | D SET(START+4,OFFSET," Event Type: "_$G(TIUREC(8925.4,TIUDA,.08)))
|
---|
| 30 | D SET(START+5,OFFSET," Document Type: "_$G(TIUREC(8925.4,TIUDA,.03)))
|
---|
| 31 | D SET(START+6,OFFSET,"Resolution Status: "_$G(TIUREC(8925.4,TIUDA,.06)))
|
---|
| 32 | D SET(START+7,OFFSET," Resolution Date: "_$G(TIUREC(8925.4,TIUDA,.07)))
|
---|
| 33 | S VALMCNT=7
|
---|
| 34 | Q
|
---|
| 35 | FIELDS(TIUDA,TIUJ) ; Get missing fields
|
---|
| 36 | N TIUK,TIUFLD S TIUK=0
|
---|
| 37 | S TIUJ=+$G(TIUJ)+1
|
---|
| 38 | D BLANK(TIUJ) S TIUJ=+$G(TIUJ)+1
|
---|
| 39 | D SET(TIUJ,2," Missing Fields ",IORVON,IORVOFF) S TIUJ=TIUJ+1
|
---|
| 40 | D BLANK(TIUJ)
|
---|
| 41 | F S TIUK=$O(^TIU(8925.4,+TIUDA,1,TIUK)) Q:+TIUK'>0 D
|
---|
| 42 | . N DIC,DIQ,DA,DR S DA=TIUK,DIC="^TIU(8925.4,"_+TIUDA_",1,"
|
---|
| 43 | . S DR=".01:.04",DIQ="TIUFLD(" D EN^DIQ1 Q:$D(TIUFLD)'>9
|
---|
| 44 | . I $$FIXED^TIUPEVN1(8925,+$G(TIUFLD(8925.42,DA,.02)),+$G(TIUFLD(8925.42,DA,.03)))=1 Q ; P81, don't display fixed missing flds; moved from TIUPEVNT
|
---|
| 45 | . S TIUJ=+$G(TIUJ)+1
|
---|
| 46 | . D SET(TIUJ,2," File Number: "_$G(TIUFLD(8925.42,DA,.01)))
|
---|
| 47 | . D SET(TIUJ,40,"Record Number: "_$G(TIUFLD(8925.42,DA,.02)))
|
---|
| 48 | . S TIUJ=+$G(TIUJ)+1
|
---|
| 49 | . D SET(TIUJ,2," Field Number: "_$G(TIUFLD(8925.42,DA,.03)))
|
---|
| 50 | . D SET(TIUJ,40," Failed Value: "_$G(TIUFLD(8925.42,DA,.04)))
|
---|
| 51 | Q
|
---|
| 52 | HEADER(TIUDA,TIUJ) ; Get body of document
|
---|
| 53 | S TIUJ=+$G(TIUJ)+1
|
---|
| 54 | D BLANK(TIUJ) S TIUJ=+$G(TIUJ)+1
|
---|
| 55 | D SET(TIUJ,2," Header Text ",IORVON,IORVOFF)
|
---|
| 56 | ; D BLANK(TIUJ) S TIUJ=TIUJ+1
|
---|
| 57 | D HDRTEXT(TIUDA,.TIUJ)
|
---|
| 58 | Q
|
---|
| 59 | HDRTEXT(TIUDA,TIUJ) ; Get Header Text for filing errors
|
---|
| 60 | N TIUKID,TIUDADT,TIUI S TIUI=0
|
---|
| 61 | F S TIUI=$O(^TIU(8925.4,+TIUDA,"HEAD",TIUI)) Q:+TIUI'>0 D
|
---|
| 62 | . S TIUJ=+$G(TIUJ)+1
|
---|
| 63 | . D SET(TIUJ,2,$G(^TIU(8925.4,+TIUDA,"HEAD",+TIUI,0)))
|
---|
| 64 | Q
|
---|
| 65 | SET(LINE,COL,TEXT,ON,OFF) ; -- set display info in array
|
---|
| 66 | D:'$D(@VALMAR@(LINE,0)) BLANK(.LINE)
|
---|
| 67 | D SET^VALM10(.LINE,$$SETSTR^VALM1(.TEXT,@VALMAR@(LINE,0),.COL,$L(TEXT)))
|
---|
| 68 | D:$G(ON)]""!($G(OFF)]"") CNTRL^VALM10(.LINE,.COL,$L(TEXT),$G(ON),$G(OFF))
|
---|
| 69 | W:'(LINE#5)&'+$G(HUSH) "."
|
---|
| 70 | Q
|
---|
| 71 | ;
|
---|
| 72 | BLANK(LINE) ; -- build blank line
|
---|
| 73 | D SET^VALM10(.LINE,$J("",80))
|
---|
| 74 | Q
|
---|