ACR101 ; GENERATED FROM 'ACR SF-44 DISPLAY' PRINT TEMPLATE (#3890) ; 09/30/09 ; (FILE 9002196, MARGIN=80)
G BEGIN
N W !
T W:$X ! I '$D(DIOT(2)),DN,$D(IOSL),$S('$D(DIWF):1,$P(DIWF,"B",2):$P(DIWF,"B",2),1:1)+$Y'<IOSL,$D(^UTILITY($J,1))#2,^(1)?1U1P1E.E X ^(1)
S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
Q
DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
I Y W $P("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$E(Y,4,5))_" " W:Y#100 $J(Y#100\1,2)_"," W Y\10000+1700 W:Y#1 " "_$E(Y_0,9,10)_":"_$E(Y_"000",11,12) Q
W Y Q
M D @DIXX
Q
BEGIN ;
S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
I $D(DXS)<9 M DXS=^DIPT(3890,"DXS")
S I(0)="^ACRDOC(",J(0)=9002196
W ?0 D ^ACRFDAP K DIP K:DN Y
D N:$X>19 Q:'DN W ?19 W "REQUESTED BY.......:"
W ?41 W:$D(ACRX(12,1)) "#" K DIP K:DN Y
S X=$G(^ACRDOC(D0,"REQ")) S Y=$P(X,U,12) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "FUNDS CERTIFICATION:"
W ?41 W:$D(ACRX("FA",1)) "#" K DIP K:DN Y
S X=$G(^ACRDOC(D0,"FA")) S Y=$P(X,U,1) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "RECOMMENDED BY.....:"
W ?41 W:$D(ACRX(13,1)) "#" K DIP K:DN Y
S X=$G(^ACRDOC(D0,"REQ")) S Y=$P(X,U,13) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "APPROVED BY........:"
W ?41 W:$D(ACRX(14,1)) "#" K DIP K:DN Y
S X=$G(^ACRDOC(D0,"REQ")) S Y=$P(X,U,14) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "FINANCE............:"
S X=$G(^ACRDOC(D0,"REQ1")) W ?41 S Y=$P(X,U,14) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "PROPERTY MANAGEMENT:"
S X=$G(^ACRDOC(D0,"REQ")) W ?41 S Y=$P(X,U,15) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D N:$X>19 Q:'DN W ?19 W "RECEIVING OFFICIAL.:"
S X=$G(^ACRDOC(D0,"REQ1")) W ?41 S Y=$P(X,U,6) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,30)
D T Q:'DN D N D N:$X>0 Q:'DN W ?0 W "[1 ]*TO.........:"
S X=$G(^ACRDOC(D0,"REQ")) W ?19 S Y=$P(X,U,1) S Y=$S(Y="":Y,$D(^AUTTPRG(Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,20)
D N:$X>40 Q:'DN W ?40 W "[8 ]*REFERENCE..:"
W ?59 S Y=$P(X,U,7) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,20)
D N:$X>0 Q:'DN W ?0 W "[2 ]*REQUEST FOR:"
S X=$G(^ACRDOC(D0,"REQ")) W ?19 S Y=$P(X,U,2) W:Y]"" $S($D(DXS(3,Y)):DXS(3,Y),1:Y)
D N:$X>40 Q:'DN W ?40 W "[9 ]*TELEPHONE #:"
W ?59,$E($P(X,U,8),1,12)
D N:$X>0 Q:'DN W ?0 W "[3 ]*REQSTNG ORG:"
W ?19 S Y=$P(X,U,3) S Y=$S(Y="":Y,$D(^AUTTPRG(Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,20)
D N:$X>40 Q:'DN W ?40 W "[10] DELIVER TO.:"
S X=$G(^ACRDOC(D0,"REQ1")) W ?59 S Y=$P(X,U,1) S Y=$S(Y="":Y,$D(^AUTTPRG(Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,20)
D N:$X>0 Q:'DN W ?0 W "[4 ]*CUST AREA..:"
S X=$G(^ACRDOC(D0,"REQ")) W ?19 S Y=$P(X,U,4) S Y=$S(Y="":Y,$D(^AUTTLCOD(Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,30)
X DXS(1,9.2) S X=$P(DIP(101),U,2) S D0=I(0,0) K DIP K:DN Y W X
W " "
X DXS(2,9.2) S X=$P(DIP(101),U,2) S D0=I(0,0) K DIP K:DN Y W $E(X,1,9)
D N:$X>40 Q:'DN W ?40 W "[11] RQSD VENDER:"
S X=$G(^ACRDOC(D0,"PO")) W ?59 S Y=$P(X,U,5) S Y=$S(Y="":Y,$D(^AUTTVNDR(Y,0))#2:$P(^(0),U),1:Y) W $E(Y,1,20)
D N:$X>0 Q:'DN W ?0 W "[5 ]*DATE OF REQ:"
S X=$G(^ACRDOC(D0,"REQ")) W ?19 S Y=$P(X,U,5) D DT
D N:$X>40 Q:'DN W ?40 W "[12]*IDENTIFIER.:"
S X=$G(^ACRDOC(D0,0)) W ?59,$E($P(X,U,14),1,16)
D N:$X>0 Q:'DN W ?0 W "[6 ]*DATE REQRED:"
S X=$G(^ACRDOC(D0,"REQ")) W ?19 S Y=$P(X,U,11) D DT
D N:$X>40 Q:'DN W ?40 W "[13] DEPT PRIOR.:"
S X=$G(^ACRDOC(D0,"REQ2")) W ?59 S Y=$P(X,U,6) W:Y]"" $J(Y,2,0)
D N:$X>0 Q:'DN W ?0 W "[7 ] PRIORITY...:"
S X=$G(^ACRDOC(D0,"DT")) W ?19 S Y=$P(X,U,4) W:Y]"" $S($D(DXS(4,Y)):DXS(4,Y),1:Y)
D N:$X>40 Q:'DN W ?40 W "[14]*INITIATOR..:"
S X=$G(^ACRDOC(D0,"REQ2")) W ?59 S Y=$P(X,U,8) S Y(0)=Y S Y=$$NAME2^ACRFUTL1(Y) W $E(Y,1,20)
D N:$X>40 Q:'DN W ?40 W "[15]*REQST TYPE.:"
W ?59 S DIP(1)=$S($D(^ACRDOC(D0,0)):^(0),1:"") S X=$S('$D(^ACRTXTYP(+$P(DIP(1),U,4),0)):"",1:$P(^(0),U,1)),DIP(2)=X S X=9,DIP(3)=X S X=29,X=$E(DIP(2),DIP(3),X) K DIP K:DN Y W X
K Y
Q
HEAD ;
W !,"--------------------------------------------------------------------------------",!!
ACR101 ; GENERATED FROM 'ACR SF-44 DISPLAY' PRINT TEMPLATE (#3890) ; 09/30/09 ; (FILE 9002196, MARGIN=80)
+1 GOTO BEGIN
N WRITE !
T IF $X
WRITE !
IF '$DATA(DIOT(2))
IF DN
IF $DATA(IOSL)
IF $SELECT('$DATA(DIWF):1,$PIECE(DIWF,"B",2):$PIECE(DIWF,"B",2),1:1)+$Y'<IOSL
IF $DATA(^UTILITY($JOB,1))#2
IF ^(1)?1U1P1E.E
XECUTE ^(1)
+1 SET DISTP=DISTP+1
SET DILCT=DILCT+1
IF '(DISTP#100)
DO CSTP^DIO2
+2 QUIT
DT IF $GET(DUZ("LANG"))>1
IF Y
WRITE $$OUT^DIALOGU(Y,"DD")
QUIT
+1 IF Y
WRITE $PIECE("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$EXTRACT(Y,4,5))_" "
IF Y#100
WRITE $JUSTIFY(Y#100\1,2)_","
WRITE Y\10000+1700
IF Y#1
WRITE " "_$EXTRACT(Y_0,9,10)_":"_$EXTRACT(Y_"000",11,12)
QUIT
+2 WRITE Y
QUIT
M DO @DIXX
+1 QUIT
BEGIN ;
+1 IF '$DATA(DN)
SET DN=1
SET DISTP=$GET(DISTP)
SET DILCT=$GET(DILCT)
+2 IF $DATA(DXS)<9
MERGE DXS=^DIPT(3890,"DXS")
+3 SET I(0)="^ACRDOC("
SET J(0)=9002196
+4 WRITE ?0
DO ^ACRFDAP
KILL DIP
IF DN
KILL Y
+5 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "REQUESTED BY.......:"
+6 WRITE ?41
IF $DATA(ACRX(12,1))
WRITE "#"
KILL DIP
IF DN
KILL Y
+7 SET X=$GET(^ACRDOC(D0,"REQ"))
SET Y=$PIECE(X,U,12)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+8 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "FUNDS CERTIFICATION:"
+9 WRITE ?41
IF $DATA(ACRX("FA",1))
WRITE "#"
KILL DIP
IF DN
KILL Y
+10 SET X=$GET(^ACRDOC(D0,"FA"))
SET Y=$PIECE(X,U,1)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+11 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "RECOMMENDED BY.....:"
+12 WRITE ?41
IF $DATA(ACRX(13,1))
WRITE "#"
KILL DIP
IF DN
KILL Y
+13 SET X=$GET(^ACRDOC(D0,"REQ"))
SET Y=$PIECE(X,U,13)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+14 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "APPROVED BY........:"
+15 WRITE ?41
IF $DATA(ACRX(14,1))
WRITE "#"
KILL DIP
IF DN
KILL Y
+16 SET X=$GET(^ACRDOC(D0,"REQ"))
SET Y=$PIECE(X,U,14)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+17 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "FINANCE............:"
+18 SET X=$GET(^ACRDOC(D0,"REQ1"))
WRITE ?41
SET Y=$PIECE(X,U,14)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+19 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "PROPERTY MANAGEMENT:"
+20 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?41
SET Y=$PIECE(X,U,15)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+21 IF $X>19
DO N
IF 'DN
QUIT
WRITE ?19
WRITE "RECEIVING OFFICIAL.:"
+22 SET X=$GET(^ACRDOC(D0,"REQ1"))
WRITE ?41
SET Y=$PIECE(X,U,6)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,30)
+23 DO T
IF 'DN
QUIT
DO N
IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[1 ]*TO.........:"
+24 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?19
SET Y=$PIECE(X,U,1)
SET Y=$SELECT(Y="":Y,$DATA(^AUTTPRG(Y,0))#2:$PIECE(^(0),U),1:Y)
WRITE $EXTRACT(Y,1,20)
+25 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[8 ]*REFERENCE..:"
+26 WRITE ?59
SET Y=$PIECE(X,U,7)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,20)
+27 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[2 ]*REQUEST FOR:"
+28 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?19
SET Y=$PIECE(X,U,2)
IF Y]""
WRITE $SELECT($DATA(DXS(3,Y)):DXS(3,Y),1:Y)
+29 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[9 ]*TELEPHONE #:"
+30 WRITE ?59,$EXTRACT($PIECE(X,U,8),1,12)
+31 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[3 ]*REQSTNG ORG:"
+32 WRITE ?19
SET Y=$PIECE(X,U,3)
SET Y=$SELECT(Y="":Y,$DATA(^AUTTPRG(Y,0))#2:$PIECE(^(0),U),1:Y)
WRITE $EXTRACT(Y,1,20)
+33 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[10] DELIVER TO.:"
+34 SET X=$GET(^ACRDOC(D0,"REQ1"))
WRITE ?59
SET Y=$PIECE(X,U,1)
SET Y=$SELECT(Y="":Y,$DATA(^AUTTPRG(Y,0))#2:$PIECE(^(0),U),1:Y)
WRITE $EXTRACT(Y,1,20)
+35 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[4 ]*CUST AREA..:"
+36 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?19
SET Y=$PIECE(X,U,4)
SET Y=$SELECT(Y="":Y,$DATA(^AUTTLCOD(Y,0))#2:$PIECE(^(0),U),1:Y)
WRITE $EXTRACT(Y,1,30)
+37 XECUTE DXS(1,9.2)
SET X=$PIECE(DIP(101),U,2)
SET D0=I(0,0)
KILL DIP
IF DN
KILL Y
WRITE X
+38 WRITE " "
+39 XECUTE DXS(2,9.2)
SET X=$PIECE(DIP(101),U,2)
SET D0=I(0,0)
KILL DIP
IF DN
KILL Y
WRITE $EXTRACT(X,1,9)
+40 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[11] RQSD VENDER:"
+41 SET X=$GET(^ACRDOC(D0,"PO"))
WRITE ?59
SET Y=$PIECE(X,U,5)
SET Y=$SELECT(Y="":Y,$DATA(^AUTTVNDR(Y,0))#2:$PIECE(^(0),U),1:Y)
WRITE $EXTRACT(Y,1,20)
+42 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[5 ]*DATE OF REQ:"
+43 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?19
SET Y=$PIECE(X,U,5)
DO DT
+44 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[12]*IDENTIFIER.:"
+45 SET X=$GET(^ACRDOC(D0,0))
WRITE ?59,$EXTRACT($PIECE(X,U,14),1,16)
+46 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[6 ]*DATE REQRED:"
+47 SET X=$GET(^ACRDOC(D0,"REQ"))
WRITE ?19
SET Y=$PIECE(X,U,11)
DO DT
+48 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[13] DEPT PRIOR.:"
+49 SET X=$GET(^ACRDOC(D0,"REQ2"))
WRITE ?59
SET Y=$PIECE(X,U,6)
IF Y]""
WRITE $JUSTIFY(Y,2,0)
+50 IF $X>0
DO N
IF 'DN
QUIT
WRITE ?0
WRITE "[7 ] PRIORITY...:"
+51 SET X=$GET(^ACRDOC(D0,"DT"))
WRITE ?19
SET Y=$PIECE(X,U,4)
IF Y]""
WRITE $SELECT($DATA(DXS(4,Y)):DXS(4,Y),1:Y)
+52 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[14]*INITIATOR..:"
+53 SET X=$GET(^ACRDOC(D0,"REQ2"))
WRITE ?59
SET Y=$PIECE(X,U,8)
SET Y(0)=Y
SET Y=$$NAME2^ACRFUTL1(Y)
WRITE $EXTRACT(Y,1,20)
+54 IF $X>40
DO N
IF 'DN
QUIT
WRITE ?40
WRITE "[15]*REQST TYPE.:"
+55 WRITE ?59
SET DIP(1)=$SELECT($DATA(^ACRDOC(D0,0)):^(0),1:"")
SET X=$SELECT('$DATA(^ACRTXTYP(+$PIECE(DIP(1),U,4),0)):"",1:$PIECE(^(0),U,1))
SET DIP(2)=X
SET X=9
SET DIP(3)=X
SET X=29
SET X=$EXTRACT(DIP(2),DIP(3),X)
KILL DIP
IF DN
KILL Y
WRITE X
+56 KILL Y
+57 QUIT
HEAD ;
+1 WRITE !,"--------------------------------------------------------------------------------",!!