Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
Tia-dev
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dida Adams Arizona
Tia-dev
Commits
4555699a
Commit
4555699a
authored
Feb 06, 2026
by
ardiansyah
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ENV-DEV' into 'ENV-DEPLOYMENT'
Fix history master budget See merge request
!2392
parents
defb414a
e03d5af3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
45 additions
and
5 deletions
+45
-5
BudgetTahunan.js
src/container/BudgetTahunan/BudgetTahunan.js
+45
-5
No files found.
src/container/BudgetTahunan/BudgetTahunan.js
View file @
4555699a
...
...
@@ -2178,9 +2178,8 @@ export default class BudgetTahunan extends Component {
master_report_type_id
}
api
.
create
().
historyApproval
(
body
).
then
(
response
=>
{
// // // console.log(response);
if
(
response
.
data
.
data
.
length
>
0
)
{
const
dataTable
=
response
.
data
.
data
.
forEach
(
item
=>
{
const
dataTable
=
response
.
data
.
data
.
map
(
item
=>
{
let
indexC
=
String
(
item
.
status_approval
).
toLocaleUpperCase
().
indexOf
(
'C'
)
let
status_approv
=
''
if
(
String
(
item
.
status_approval
).
toLocaleUpperCase
().
includes
(
'CC'
))
{
...
...
@@ -2971,9 +2970,46 @@ export default class BudgetTahunan extends Component {
)
}
renderHistoryInfo
=
(
master_report_type_id
)
=>
{
const
obj
=
this
.
getSubmissionObj
(
master_report_type_id
)
return
(
this
.
state
.
checkApprover
===
true
?
obj
.
lastStatus
===
'WAITING FOR REVIEW'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
obj
.
lastStatus
}
<
/span
>
<
/div> : obj.lastStatus === 'WAITING FOR YOUR APPROVAL'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
obj
.
lastStatus
}
<
/span
>
<
/div> : obj.lastStatus === 'WAITING FOR APPROVAL'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
`
${
obj
.
lastStatus
}
-
${
this
.
state
.
pic
}
`
}
<
/span
>
<
/div> : obj.lastStatus === 'APPROVED'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
`
${
obj
.
lastStatus
}
`
}
<
/span
>
<
/div> : nul
l
:
obj
.
lastStatus
===
'SUBMITTED'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
obj
.
lastStatus
}
<
/span
>
<
/div>
:
obj
.
lastStatus
===
'WAITING FOR APPROVAL'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
{
`
${
obj
.
lastStatus
}
-
${
this
.
state
.
pic
}
`
}
<
/span
>
<
/div>
:
obj
.
lastStatus
===
'REVISION'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
NEED
REVISION
<
/span
>
<
/div>
:
obj
.
lastStatus
===
'APPROVED'
?
<
div
style
=
{{
width
:
'100%'
,
padding
:
'10px 20px'
,
backgroundColor
:
'yellow'
,
textAlign
:
'center'
,
marginTop
:
20
}}
>
<
span
>
APPROVED
<
/span
>
<
/div> : nul
l
)
}
renderBtnSubmit
=
(
master_report_type_id
)
=>
{
const
obj
=
this
.
getSubmissionObj
(
master_report_type_id
)
console
.
log
(
obj
,
master_report_type_id
)
return
(
this
.
state
.
isAdmin
&&
obj
.
lastStatus
==
'APPROVED'
?
<
div
className
=
"grid grid-2x"
style
=
{{
borderTop
:
'solid 1px #c4c4c4'
,
padding
:
10
,
backgroundColor
:
'#f5f5f5'
,
width
:
'100%'
,
}}
>
...
...
@@ -3409,6 +3445,8 @@ export default class BudgetTahunan extends Component {
/
>
<
/div
>
);
const
mstIdFinance
=
this
.
state
?.
rowDataFinance
?.
length
>
0
&&
this
.
state
.
rowDataFinance
[
0
]?.
master_report_type_id
const
mstIdCAT
=
this
.
state
?.
rowDataCAT
?.
length
>
0
&&
this
.
state
.
rowDataCAT
[
0
]?.
master_report_type_id
return
(
<
div
style
=
{{
flex
:
1
,
backgroundColor
:
'#f8f8f8'
}}
>
<
Snackbar
open
=
{
this
.
state
.
alert
}
autoHideDuration
=
{
6000
}
onClose
=
{()
=>
this
.
closeAlert
()}
>
...
...
@@ -3475,6 +3513,7 @@ export default class BudgetTahunan extends Component {
<
/MuiThemeProvider
>
<
/div
>
{
this
.
renderAttachment
()}
{
this
.
renderHistoryInfo
(
mstIdFinance
)}
{
this
.
state
.
visibleTableHistory
&&
(
<
div
style
=
{{
marginTop
:
20
}}
>
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
...
...
@@ -3487,7 +3526,7 @@ export default class BudgetTahunan extends Component {
<
/div
>
)}
<
/div
>
{
this
.
state
.
checkApprover
&&
this
.
state
.
isApproverFinance
&&
this
.
renderBtnSubmit
(
this
.
state
?.
rowDataFinance
?.
length
>
0
&&
this
.
state
.
rowDataFinance
[
0
]?.
master_report_type_id
)}
{
this
.
state
.
checkApprover
&&
this
.
state
.
isApproverFinance
&&
this
.
renderBtnSubmit
(
mstIdFinance
)}
<
div
style
=
{{
padding
:
'0 20px 20px'
}}
>
<
div
style
=
{{
display
:
'flex'
,
justifyContent
:
'space-between'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'16px'
,
color
:
'#4b4b4b'
,
fontWeight
:
'bold'
}}
>
Report
CAT
<
/Typography
>
...
...
@@ -3516,6 +3555,7 @@ export default class BudgetTahunan extends Component {
/
>
<
/MuiThemeProvider
>
{
this
.
renderAttachment
()}
{
this
.
renderHistoryInfo
(
mstIdCAT
)}
{
this
.
state
.
visibleTableHistoryCAT
&&
(
<
div
style
=
{{
marginTop
:
20
}}
>
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
...
...
@@ -3528,7 +3568,7 @@ export default class BudgetTahunan extends Component {
<
/div
>
)}
<
/div
>
{
this
.
state
.
checkApprover
&&
this
.
state
.
isApproverCAT
&&
this
.
renderBtnSubmit
(
this
.
state
?.
rowDataCAT
?.
length
>
0
&&
this
.
state
.
rowDataCAT
[
0
]?.
master_report_type_id
)}
{
this
.
state
.
checkApprover
&&
this
.
state
.
isApproverCAT
&&
this
.
renderBtnSubmit
(
mstIdCAT
)}
<
/Paper
>
<
/div
>
<
/div
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment