ACRFSS3 ;IHS/OIRM/DSD/THL,AEF - EDIT TRAVEL OR TRAINING EXPENSES; [ 02/02/2005 10:23 AM ]
;;2.1;ADMIN RESOURCE MGT SYSTEM;**16**;NOV 05, 2001
;;CONTINUATION OF ACRFSS
;;EDIT TRAVEL OR TRAINING EXPENSES
TO F D EN1 Q:$D(ACRQUIT)!$D(ACROUT)
EXIT K ACRX,ACRQUIT,ACRPF,ACRI,ACRALTOT,ACRSS
Q
EN1 S ACRTXDA=$P(ACRDOC0,U,4)
I ACRREF=600!(ACRREF=130) D ^ACRFSS4 I $D(ACRREV) S ACRQUIT="" Q
Q:$D(ACROUT)
I $D(ACRNEWOB),$D(^ACRSS("E",ACRDOCDA)),ACRREF=130!(ACRREF=600) D UP
W !!,$S(ACRREF=130:"TRAVEL ORDER",ACRREF=600:"TRAVEL VOUCHER",1:"TRAINING REQUEST")," BEING PROCESSED."
W !
F ACRI=1:1:$S(ACRREF=130!(ACRREF=600):4,1:2) D ADD
I $D(ACRQUIT) Q
F D EN2 Q:$D(ACRQUIT)!$D(ACROUT)
Q
EN2 ;EP
D DISPLAY
D EDIT
S ACRQUIT=""
Q
DISPLAY I $E(IOST,1,2)="C-",'$D(ACRPRT) D
.W @IOF
.W !?10,@ACRON,$S(ACRREF=130!(ACRREF=600):"TRAVEL",1:"TRAINING")," EXPENSES"
.W @ACROF," FOR DOCUMENT: ",@ACRON,ACRDOC,@ACROF
.D OBJ
W !!,"ITEM"
W ?6,"TYPE OF"
W:'$D(ACRPRT) ?22,"OBJ"
W ?42,"ESTIMATED"
W !," NO."
W ?6,"EXPENSE"
I '$D(ACRPRT) D
.W ?22,"CODE"
.W ?28,"CAN NO."
W ?42,"EXPENSE"
W !,"----"
W ?6,"--------------"
I '$D(ACRPRT) D
.W ?22,"----"
.W ?28,"-------"
W ?42,"----------"
S ACRSSDA="",(ACRSSTOT,ACRJ)=0
I ACRREF=130!(ACRREF=600) F ACRI=1:1:4 D
.S ACRSSDA=$O(^ACRSS("E",ACRDOCDA,ACRI,0))
.Q:'ACRSSDA
.S ACRJ=ACRJ+1
.D DISP1
I ACRREF=148 F ACRI=1,2 D
.S ACRSSDA=$O(^ACRSS("E",ACRDOCDA,ACRI,ACRSSDA))
.Q:'ACRSSDA
.S ACRJ=ACRJ+1
.D DISP1
W !?42,"----------"
W !?34,"TOTAL"
W ?42,$J($FN(ACRSSTOT,"P",2),11)
I $D(ACRPRT),$E(IOST,1,2)["C-" D PAUSE^ACRFWARN W @IOF
Q
DISP1 S ACRSS=ACRSSDA_"^"_^ACRSS(ACRSSDA,0),ACRSS1=$P($G(^ACRSS(ACRSSDA,"DT")),U,4),ACRITEM=$P(ACRSS,U,2),ACRSSITM=$P($G(^ACRSS(ACRSSDA,"NMS")),U,5),ACRSS(ACRJ)=ACRSS,ACROBJDA=$P(ACRSS,U,5),ACRSSCAN=$P(ACRSS,U,6)
S ACRCAN=$P($G(^AUTTCAN(+ACRSSCAN,0)),U),ACROBJ=$P($G(^AUTTOBJC(+ACROBJDA,0)),U)
S:ACRSS1'["." ACRSS1=ACRSS1_".00"
S:$L($P(ACRSS1,".",2))=1 ACRSS1=ACRSS1_"0"
S ACRSSTOT=ACRSSTOT+ACRSS1
S:ACRITEM'=ACRJ&(ACRITEM'=999) $P(^ACRSS(ACRSSDA,0),U)=ACRJ
W !,$J(ACRJ,3)
W ?6,ACRSSITM
I '$D(ACRPRT) D
.W ?22,$S(ACROBJ]"":ACROBJ,1:"****")
.W ?28,ACRCAN
W ?42,$J(ACRSS1,10)
Q
ADD I $D(^ACRSS("E",ACRDOCDA,ACRI)) D ADD1:ACRREF'=148 Q
S X=ACRI
S DIC(0)="L"
S DIC="^ACRSS("
I ACRREF=130!(ACRREF=600) S Y(0)=$S(X=1:"Travel-DHHS",X=2:"Per Diem-DHHS",X=3:"Other Exp-DHHS",X=4:"Travel-OTHER",X=5:"Per Diem-OTHER",1:"Other Exp-OTHER")
E S Y(0)=$S(X=1:"Tuition & Fees",1:"Books & Other")
I ACRREF=130!(ACRREF=600),X=4 S Y(0)="Travel Mgt Fee"
S ACRCANDA=$O(^AUTTCAN("B",ACRFDNCA,0))
S DIC("DR")=".02////"_$G(ACRDOCDA)_";.03////"_$G(ACRDOCDA)_";.05////"_$G(ACRCANDA)_";.06////"_$G(ACRLBDA)_";5////"_$G(Y(0))
I ACRI<5,ACRREF=130!(ACRREF=600) S DIC("DR")=DIC("DR")_";13////"_$S(ACRI=1:+$G(ACRALTOT),ACRI=2:$G(ACRPD)+$G(ACRLDG),ACRI=3:$G(ACROTHT)+$G(ACRRC)+$G(ACR4P),ACRI=4&($D(^ACRAL("E",ACRDOCDA))):$P($G(^ACRSYS(1,400)),U),1:0)
E S DIC("DR")=DIC("DR")_";13////0"
I $G(Y(0))="Travel Mgt Fee" D
. S DIC("DR")=DIC("DR")_";.04////"_$S($P($G(^ACRSYS(1,400)),U,2)]"":$P($G(^ACRSYS(1,400)),U,2),$G(ACROBJ)]"":ACROBJ,+$O(^AUTTOBJC("B",2121_" ",0)):$O(^AUTTOBJC("B",2121_" ",0)),1:"")
D FILE^ACRFDIC
S ACRSSDA=+Y
Q
ADD1 S DA=$O(^ACRSS("E",ACRDOCDA,ACRI,0))
S DIE="^ACRSS("
Q:'DA
;I ACRREF=130!(ACRREF=600),$P($G(^ACRSS(DA,"DT")),U,4)=$S(ACRI=1:$G(ACRALTOT),ACRI=2:$G(ACRPD)+$G(ACRLDG),ACRI=3:$G(ACROTHT)+$G(ACRRC)+$G(ACR4P),1:0) Q ;ACR*2.1*16.09 IM13605
S ACRALTOT=$G(ACRALTOT) ;ACR*2.1*16.09 IM13605
S ACRPD=$G(ACRPD) ;ACR*2.1*16.09 IM13605
S ACRLDG=$G(ACRLDG) ;ACR*2.1*16.09 IM13605
S ACROTHT=$G(ACROTHT) ;ACR*2.1*16.09 IM13605
S ACRRC=$G(ACRRC) ;ACR*2.1*16.09 IM13605
S ACR4P=$G(ACR4P) ;ACR*2.1*16.09 IM13605
I ACRREF=130!(ACRREF=600),$P($G(^ACRSS(DA,"DT")),U,4)=$S(ACRI=1:+ACRALTOT,ACRI=2:ACRPD+ACRLDG,ACRI=3:ACROTHT+ACRRC+ACR4P,1:0) Q ;ACR*2.1*16.09 IM13605
I ACRREF=130!(ACRREF=600) Q:ACRI=4&(+$$TMFEE^ACRFSS42(ACRDOCDA))
I ACRI<5,ACRREF=130!(ACRREF=600) S DR="13////"_$S(ACRI=1:+ACRALTOT,ACRI=2:ACRPD+ACRLDG,ACRI=3:ACROTHT+ACRRC+ACR4P,ACRI=4&($D(^ACRAL("E",ACRDOCDA))):$P($G(^ACRSYS(1,400)),U),1:0)
E S DR="13////0"
I ACRI=4,ACRREF=130!(ACRREF=600) S DR=DR_";4////"_$S($P($G(^ACRSYS(1,400)),U,2):$P($G(^ACRSYS(1,400)),U,2),1:$O(^AUTTOBJC("B",2121_" ",0)))
Q:ACRREF=148
D DIE^ACRFDIC
Q
EDIT ;
I $G(ACRREF)=148,$P($G(^ACROBL(ACRDOCDA,"APV")),U)="A" Q ;PREVENT EDITING EXPENSES ON APPROVED TRAINING REQUEST
S DIR(0)="LOA^1:"_$S(ACRREF=130!(ACRREF=600):4,1:2)
S DIR("A")="Item NO(s). ==> "
I ACRREF=600 S DIR("B")=4
W !
K ACRQUIT
D DIR^ACRFDIC
Q:$D(ACRQUIT)!$D(ACROUT)!'+Y
I ACRREF=600 Q:+Y'=4
F ACRI=1:1 S X=$P(ACRY,",",ACRI) Q:'X D:+$G(ACRSS(X)) E1
Q
E1 W !!?22,"Item No. ",X
S (DA,ACRSSDA)=+ACRSS(X)
S DIE="^ACRSS("
S DR="S DIE(""NO^"")="""";.05T//"_$S($L($G(ACRFDNCA))=7:ACRFDNCA,$L($G(ACRCAN))=7:ACRCAN,1:"")_";.04T"_$S(ACRREF'=148:"",X=1:";13TUITION & FEES......",X=2:";13BOOKS & OTHER.......",1:"")
I $P($G(^ACRSS(ACRSSDA,"NMS")),U,5)="Travel Mgt Fee" S DR=DR_";13T"
D DIE^ACRFDIC
Q
COURSE ;EP;TO EDIT TRAINING NEED
N DXS,DIP,DC,DN
S (D0,DA)=ACRDOCDA
S DIE="^ACRDOC("
S DR="[ACR TRAINING NEED]"
D DDS^ACRFDIC
Q:'$D(ACRSCREN)
K ACRSCREN
D ^ACR148A
I $D(^ACRDOC(ACRDOCDA,"TRNGND1")) D I Y'=1 S ACRQUIT="" Q
.S DIR(0)="YO"
.S DIR("A")=" Edit this data"
.S DIR("B")="NO"
.W !
.D DIR^ACRFDIC
D DIE^ACRFDIC
Q
UP ;EP;TO UPDATE REQUEST AMOUNT
Q:$P(^ACRDOC(ACRDOCDA,0),U,14)["CANCELLED"
S ACRSSDA=0
F ACRI=1:1:3 D:$D(^ACRSS("E",ACRDOCDA,ACRI))
.S ACRSSDA=$O(^ACRSS("E",ACRDOCDA,ACRI,ACRSSDA))
.S DA=ACRSSDA
.S DIE="^ACRSS("
.S DR="13////"_$S(ACRI=1:+$G(ACRALTOT),ACRI=2:ACRPD+ACRLDG,1:ACROTHT+ACRRC+ACR4P)
.D DIE^ACRFDIC
Q
OBJ ;
Q:$P($G(^ACROBL(ACRDOCDA,"APV")),U)="A" ;PREVENT EDITING OF OBJECT CLASS CODE ON APPROVED REQUEST
I "^130^148^"[(U_ACRREF_U),$G(ACRDOCDA),$D(^ACRSS("C",ACRDOCDA)) S (ACRSSDA,DA)=$O(^ACRSS("C",ACRDOCDA,0)) I DA,$D(^ACRSS(DA,0)) S ACROBJ=$P(^(0),U,4) D
.S DIE="^ACRSS(",DR="S DIE(""NO^"")="""";.04"_$S(ACRREF=130:"THIS TRAVEL ORDER",1:"THIS TRAINING REQUEST")_"//"_$S(ACRREF=130:"2121",1:"252W")
.W !!,"OBJECT CODE FOR"
.D DIE^ACRFDIC
.Q:ACROBJ=$P(^ACRSS(ACRSSDA,0),U,4)
.S ACROBJ=$P(^ACRSS(ACRSSDA,0),U,4)
.F S ACRSSDA=$O(^ACRSS("C",ACRDOCDA,ACRSSDA)) Q:'ACRSSDA D
..Q:$P(^ACRSS(ACRSSDA,0),U,4)=ACROBJ
..S DA=ACRSSDA
..S DIE="^ACRSS("
. . S DR=".04////"_$S($P($G(^ACRSS(ACRSSDA,"NMS")),U,5)="Travel Mgt Fee":$P($G(^ACRSYS(1,400)),U,2),1:ACROBJ)
..D DIE^ACRFDIC
D PUT($G(ACROBJ),$G(ACRDOCDA))
Q
PUT(ACROBJ,ACRDOCDA) ;
;----- PUT OCC INTO OCC FIELD OF FMS DOCUMENT FILE
;
; ACROBJ = INTERNAL OBJECT CLASS CODE
; ACRDOCDA = INTERNAL DOCUMENT NUMBER
;
I $G(ACROBJ),$G(ACRDOCDA) D
. S DIE="^ACRDOC("
. S DA=ACRDOCDA
. S DR="113060////"_ACROBJ
. D ^DIE
Q
ACRFSS3 ;IHS/OIRM/DSD/THL,AEF - EDIT TRAVEL OR TRAINING EXPENSES; [ 02/02/2005 10:23 AM ]
+1 ;;2.1;ADMIN RESOURCE MGT SYSTEM;**16**;NOV 05, 2001
+2 ;;CONTINUATION OF ACRFSS
+3 ;;EDIT TRAVEL OR TRAINING EXPENSES
TO FOR
DO EN1
IF $DATA(ACRQUIT)!$DATA(ACROUT)
QUIT
EXIT KILL ACRX,ACRQUIT,ACRPF,ACRI,ACRALTOT,ACRSS
+1 QUIT
EN1 SET ACRTXDA=$PIECE(ACRDOC0,U,4)
+1 IF ACRREF=600!(ACRREF=130)
DO ^ACRFSS4
IF $DATA(ACRREV)
SET ACRQUIT=""
QUIT
+2 IF $DATA(ACROUT)
QUIT
+3 IF $DATA(ACRNEWOB)
IF $DATA(^ACRSS("E",ACRDOCDA))
IF ACRREF=130!(ACRREF=600)
DO UP
+4 WRITE !!,$SELECT(ACRREF=130:"TRAVEL ORDER",ACRREF=600:"TRAVEL VOUCHER",1:"TRAINING REQUEST")," BEING PROCESSED."
+5 WRITE !
+6 FOR ACRI=1:1:$SELECT(ACRREF=130!(ACRREF=600):4,1:2)
DO ADD
+7 IF $DATA(ACRQUIT)
QUIT
+8 FOR
DO EN2
IF $DATA(ACRQUIT)!$DATA(ACROUT)
QUIT
+9 QUIT
EN2 ;EP
+1 DO DISPLAY
+2 DO EDIT
+3 SET ACRQUIT=""
+4 QUIT
DISPLAY IF $EXTRACT(IOST,1,2)="C-"
IF '$DATA(ACRPRT)
Begin DoDot:1
+1 WRITE @IOF
+2 WRITE !?10,@ACRON,$SELECT(ACRREF=130!(ACRREF=600):"TRAVEL",1:"TRAINING")," EXPENSES"
+3 WRITE @ACROF," FOR DOCUMENT: ",@ACRON,ACRDOC,@ACROF
+4 DO OBJ
End DoDot:1
+5 WRITE !!,"ITEM"
+6 WRITE ?6,"TYPE OF"
+7 IF '$DATA(ACRPRT)
WRITE ?22,"OBJ"
+8 WRITE ?42,"ESTIMATED"
+9 WRITE !," NO."
+10 WRITE ?6,"EXPENSE"
+11 IF '$DATA(ACRPRT)
Begin DoDot:1
+12 WRITE ?22,"CODE"
+13 WRITE ?28,"CAN NO."
End DoDot:1
+14 WRITE ?42,"EXPENSE"
+15 WRITE !,"----"
+16 WRITE ?6,"--------------"
+17 IF '$DATA(ACRPRT)
Begin DoDot:1
+18 WRITE ?22,"----"
+19 WRITE ?28,"-------"
End DoDot:1
+20 WRITE ?42,"----------"
+21 SET ACRSSDA=""
SET (ACRSSTOT,ACRJ)=0
+22 IF ACRREF=130!(ACRREF=600)
FOR ACRI=1:1:4
Begin DoDot:1
+23 SET ACRSSDA=$ORDER(^ACRSS("E",ACRDOCDA,ACRI,0))
+24 IF 'ACRSSDA
QUIT
+25 SET ACRJ=ACRJ+1
+26 DO DISP1
End DoDot:1
+27 IF ACRREF=148
FOR ACRI=1,2
Begin DoDot:1
+28 SET ACRSSDA=$ORDER(^ACRSS("E",ACRDOCDA,ACRI,ACRSSDA))
+29 IF 'ACRSSDA
QUIT
+30 SET ACRJ=ACRJ+1
+31 DO DISP1
End DoDot:1
+32 WRITE !?42,"----------"
+33 WRITE !?34,"TOTAL"
+34 WRITE ?42,$JUSTIFY($FNUMBER(ACRSSTOT,"P",2),11)
+35 IF $DATA(ACRPRT)
IF $EXTRACT(IOST,1,2)["C-"
DO PAUSE^ACRFWARN
WRITE @IOF
+36 QUIT
DISP1 SET ACRSS=ACRSSDA_"^"_^ACRSS(ACRSSDA,0)
SET ACRSS1=$PIECE($GET(^ACRSS(ACRSSDA,"DT")),U,4)
SET ACRITEM=$PIECE(ACRSS,U,2)
SET ACRSSITM=$PIECE($GET(^ACRSS(ACRSSDA,"NMS")),U,5)
SET ACRSS(ACRJ)=ACRSS
SET ACROBJDA=$PIECE(ACRSS,U,5)
SET ACRSSCAN=$PIECE(ACRSS,U,6)
+1 SET ACRCAN=$PIECE($GET(^AUTTCAN(+ACRSSCAN,0)),U)
SET ACROBJ=$PIECE($GET(^AUTTOBJC(+ACROBJDA,0)),U)
+2 IF ACRSS1'["."
SET ACRSS1=ACRSS1_".00"
+3 IF $LENGTH($PIECE(ACRSS1,".",2))=1
SET ACRSS1=ACRSS1_"0"
+4 SET ACRSSTOT=ACRSSTOT+ACRSS1
+5 IF ACRITEM'=ACRJ&(ACRITEM'=999)
SET $PIECE(^ACRSS(ACRSSDA,0),U)=ACRJ
+6 WRITE !,$JUSTIFY(ACRJ,3)
+7 WRITE ?6,ACRSSITM
+8 IF '$DATA(ACRPRT)
Begin DoDot:1
+9 WRITE ?22,$SELECT(ACROBJ]"":ACROBJ,1:"****")
+10 WRITE ?28,ACRCAN
End DoDot:1
+11 WRITE ?42,$JUSTIFY(ACRSS1,10)
+12 QUIT
ADD IF $DATA(^ACRSS("E",ACRDOCDA,ACRI))
IF ACRREF'=148
DO ADD1
QUIT
+1 SET X=ACRI
+2 SET DIC(0)="L"
+3 SET DIC="^ACRSS("
+4 IF ACRREF=130!(ACRREF=600)
SET Y(0)=$SELECT(X=1:"Travel-DHHS",X=2:"Per Diem-DHHS",X=3:"Other Exp-DHHS",X=4:"Travel-OTHER",X=5:"Per Diem-OTHER",1:"Other Exp-OTHER")
+5 IF '$TEST
SET Y(0)=$SELECT(X=1:"Tuition & Fees",1:"Books & Other")
+6 IF ACRREF=130!(ACRREF=600)
IF X=4
SET Y(0)="Travel Mgt Fee"
+7 SET ACRCANDA=$ORDER(^AUTTCAN("B",ACRFDNCA,0))
+8 SET DIC("DR")=".02////"_$GET(ACRDOCDA)_";.03////"_$GET(ACRDOCDA)_";.05////"_$GET(ACRCANDA)_";.06////"_$GET(ACRLBDA)_";5////"_$GET(Y(0))
+9 IF ACRI<5
IF ACRREF=130!(ACRREF=600)
SET DIC("DR")=DIC("DR")_";13////"_$SELECT(ACRI=1:+$GET(ACRALTOT),ACRI=2:$GET(ACRPD)+$GET(ACRLDG),ACRI=3:$GET(ACROTHT)+$GET(ACRRC)+$GET(ACR4P),ACRI=4&($DATA(^ACRAL("E",ACRDOCDA))):$PIECE($GET(^ACRSYS(1,400)),U),1:0)
+10 IF '$TEST
SET DIC("DR")=DIC("DR")_";13////0"
+11 IF $GET(Y(0))="Travel Mgt Fee"
Begin DoDot:1
+12 SET DIC("DR")=DIC("DR")_";.04////"_$SELECT($PIECE($GET(^ACRSYS(1,400)),U,2)]"":$PIECE($GET(^ACRSYS(1,400)),U,2),$GET(ACROBJ)]"":ACROBJ,+$ORDER(^AUTTOBJC("B",2121_" ",0)):$ORDER(^AUTTOBJC("B",2121_" ",0)),1:"")
End DoDot:1
+13 DO FILE^ACRFDIC
+14 SET ACRSSDA=+Y
+15 QUIT
ADD1 SET DA=$ORDER(^ACRSS("E",ACRDOCDA,ACRI,0))
+1 SET DIE="^ACRSS("
+2 IF 'DA
QUIT
+3 ;I ACRREF=130!(ACRREF=600),$P($G(^ACRSS(DA,"DT")),U,4)=$S(ACRI=1:$G(ACRALTOT),ACRI=2:$G(ACRPD)+$G(ACRLDG),ACRI=3:$G(ACROTHT)+$G(ACRRC)+$G(ACR4P),1:0) Q ;ACR*2.1*16.09 IM13605
+4 ;ACR*2.1*16.09 IM13605
SET ACRALTOT=$GET(ACRALTOT)
+5 ;ACR*2.1*16.09 IM13605
SET ACRPD=$GET(ACRPD)
+6 ;ACR*2.1*16.09 IM13605
SET ACRLDG=$GET(ACRLDG)
+7 ;ACR*2.1*16.09 IM13605
SET ACROTHT=$GET(ACROTHT)
+8 ;ACR*2.1*16.09 IM13605
SET ACRRC=$GET(ACRRC)
+9 ;ACR*2.1*16.09 IM13605
SET ACR4P=$GET(ACR4P)
+10 ;ACR*2.1*16.09 IM13605
IF ACRREF=130!(ACRREF=600)
IF $PIECE($GET(^ACRSS(DA,"DT")),U,4)=$SELECT(ACRI=1:+ACRALTOT,ACRI=2:ACRPD+ACRLDG,ACRI=3:ACROTHT+ACRRC+ACR4P,1:0)
QUIT
+11 IF ACRREF=130!(ACRREF=600)
IF ACRI=4&(+$$TMFEE^ACRFSS42(ACRDOCDA))
QUIT
+12 IF ACRI<5
IF ACRREF=130!(ACRREF=600)
SET DR="13////"_$SELECT(ACRI=1:+ACRALTOT,ACRI=2:ACRPD+ACRLDG,ACRI=3:ACROTHT+ACRRC+ACR4P,ACRI=4&($DATA(^ACRAL("E",ACRDOCDA))):$PIECE($GET(^ACRSYS(1,400)),U),1:0)
+13 IF '$TEST
SET DR="13////0"
+14 IF ACRI=4
IF ACRREF=130!(ACRREF=600)
SET DR=DR_";4////"_$SELECT($PIECE($GET(^ACRSYS(1,400)),U,2):$PIECE($GET(^ACRSYS(1,400)),U,2),1:$ORDER(^AUTTOBJC("B",2121_" ",0)))
+15 IF ACRREF=148
QUIT
+16 DO DIE^ACRFDIC
+17 QUIT
EDIT ;
+1 ;PREVENT EDITING EXPENSES ON APPROVED TRAINING REQUEST
IF $GET(ACRREF)=148
IF $PIECE($GET(^ACROBL(ACRDOCDA,"APV")),U)="A"
QUIT
+2 SET DIR(0)="LOA^1:"_$SELECT(ACRREF=130!(ACRREF=600):4,1:2)
+3 SET DIR("A")="Item NO(s). ==> "
+4 IF ACRREF=600
SET DIR("B")=4
+5 WRITE !
+6 KILL ACRQUIT
+7 DO DIR^ACRFDIC
+8 IF $DATA(ACRQUIT)!$DATA(ACROUT)!'+Y
QUIT
+9 IF ACRREF=600
IF +Y'=4
QUIT
+10 FOR ACRI=1:1
SET X=$PIECE(ACRY,",",ACRI)
IF 'X
QUIT
IF +$GET(ACRSS(X))
DO E1
+11 QUIT
E1 WRITE !!?22,"Item No. ",X
+1 SET (DA,ACRSSDA)=+ACRSS(X)
+2 SET DIE="^ACRSS("
+3 SET DR="S DIE(""NO^"")="""";.05T//"_$SELECT($LENGTH($GET(ACRFDNCA))=7:ACRFDNCA,$LENGTH($GET(ACRCAN))=7:ACRCAN,1:"")_";.04T"_$SELECT(ACRREF'=148:"",X=1:";13TUITION & FEES......",X=2:";13BOOKS & OTHER.......",1:"")
+4 IF $PIECE($GET(^ACRSS(ACRSSDA,"NMS")),U,5)="Travel Mgt Fee"
SET DR=DR_";13T"
+5 DO DIE^ACRFDIC
+6 QUIT
COURSE ;EP;TO EDIT TRAINING NEED
+1 NEW DXS,DIP,DC,DN
+2 SET (D0,DA)=ACRDOCDA
+3 SET DIE="^ACRDOC("
+4 SET DR="[ACR TRAINING NEED]"
+5 DO DDS^ACRFDIC
+6 IF '$DATA(ACRSCREN)
QUIT
+7 KILL ACRSCREN
+8 DO ^ACR148A
+9 IF $DATA(^ACRDOC(ACRDOCDA,"TRNGND1"))
Begin DoDot:1
+10 SET DIR(0)="YO"
+11 SET DIR("A")=" Edit this data"
+12 SET DIR("B")="NO"
+13 WRITE !
+14 DO DIR^ACRFDIC
End DoDot:1
IF Y'=1
SET ACRQUIT=""
QUIT
+15 DO DIE^ACRFDIC
+16 QUIT
UP ;EP;TO UPDATE REQUEST AMOUNT
+1 IF $PIECE(^ACRDOC(ACRDOCDA,0),U,14)["CANCELLED"
QUIT
+2 SET ACRSSDA=0
+3 FOR ACRI=1:1:3
IF $DATA(^ACRSS("E",ACRDOCDA,ACRI))
Begin DoDot:1
+4 SET ACRSSDA=$ORDER(^ACRSS("E",ACRDOCDA,ACRI,ACRSSDA))
+5 SET DA=ACRSSDA
+6 SET DIE="^ACRSS("
+7 SET DR="13////"_$SELECT(ACRI=1:+$GET(ACRALTOT),ACRI=2:ACRPD+ACRLDG,1:ACROTHT+ACRRC+ACR4P)
+8 DO DIE^ACRFDIC
End DoDot:1
+9 QUIT
OBJ ;
+1 ;PREVENT EDITING OF OBJECT CLASS CODE ON APPROVED REQUEST
IF $PIECE($GET(^ACROBL(ACRDOCDA,"APV")),U)="A"
QUIT
+2 IF "^130^148^"[(U_ACRREF_U)
IF $GET(ACRDOCDA)
IF $DATA(^ACRSS("C",ACRDOCDA))
SET (ACRSSDA,DA)=$ORDER(^ACRSS("C",ACRDOCDA,0))
IF DA
IF $DATA(^ACRSS(DA,0))
SET ACROBJ=$PIECE(^(0),U,4)
Begin DoDot:1
+3 SET DIE="^ACRSS("
SET DR="S DIE(""NO^"")="""";.04"_$SELECT(ACRREF=130:"THIS TRAVEL ORDER",1:"THIS TRAINING REQUEST")_"//"_$SELECT(ACRREF=130:"2121",1:"252W")
+4 WRITE !!,"OBJECT CODE FOR"
+5 DO DIE^ACRFDIC
+6 IF ACROBJ=$PIECE(^ACRSS(ACRSSDA,0),U,4)
QUIT
+7 SET ACROBJ=$PIECE(^ACRSS(ACRSSDA,0),U,4)
+8 FOR
SET ACRSSDA=$ORDER(^ACRSS("C",ACRDOCDA,ACRSSDA))
IF 'ACRSSDA
QUIT
Begin DoDot:2
+9 IF $PIECE(^ACRSS(ACRSSDA,0),U,4)=ACROBJ
QUIT
+10 SET DA=ACRSSDA
+11 SET DIE="^ACRSS("
+12 SET DR=".04////"_$SELECT($PIECE($GET(^ACRSS(ACRSSDA,"NMS")),U,5)="Travel Mgt Fee":$PIECE($GET(^ACRSYS(1,400)),U,2),1:ACROBJ)
+13 DO DIE^ACRFDIC
End DoDot:2
End DoDot:1
+14 DO PUT($GET(ACROBJ),$GET(ACRDOCDA))
+15 QUIT
PUT(ACROBJ,ACRDOCDA) ;
+1 ;----- PUT OCC INTO OCC FIELD OF FMS DOCUMENT FILE
+2 ;
+3 ; ACROBJ = INTERNAL OBJECT CLASS CODE
+4 ; ACRDOCDA = INTERNAL DOCUMENT NUMBER
+5 ;
+6 IF $GET(ACROBJ)
IF $GET(ACRDOCDA)
Begin DoDot:1
+7 SET DIE="^ACRDOC("
+8 SET DA=ACRDOCDA
+9 SET DR="113060////"_ACROBJ
+10 DO ^DIE
End DoDot:1
+11 QUIT