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
64a6d12d
Commit
64a6d12d
authored
Oct 02, 2020
by
Deni Rinaldi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://103.44.149.204/d.arizona/tia-dev
into deni-dev(pc)
parents
0dbefb51
39b813fa
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
102 additions
and
96 deletions
+102
-96
BudgetTahunan.js
src/container/BudgetTahunan.js
+6
-1
CorporateAnnualTarget.js
src/container/BudgetTahunan/CorporateAnnualTarget.js
+42
-41
FixedAssetsMovement.js
src/container/BudgetTahunan/FixedAssetsMovement.js
+15
-15
ProfitLoss.js
src/container/BudgetTahunan/ProfitLoss.js
+38
-38
OperatingIndicator.js
src/container/OprIndicator/OperatingIndicator.js
+1
-1
No files found.
src/container/BudgetTahunan.js
View file @
64a6d12d
...
...
@@ -231,7 +231,7 @@ export default class BudgetTahunan extends Component {
getOptionLabel
:
(
option
)
=>
titleCase
(
option
.
company_name
),
};
let
index
=
arrayBaru
.
findIndex
((
val
)
=>
val
.
company_id
==
comID
)
this
.
setState
({
listCompany
:
defaultProps
,
company
:
index
==
-
1
?
arrayBaru
[
0
]
:
arrayBaru
[
index
]
},
()
=>
{
this
.
setState
({
listCompany
:
defaultProps
,
company
:
arrayBaru
.
length
<
1
?
companyData
[
0
]
:
(
index
==
-
1
?
arrayBaru
[
0
]
:
arrayBaru
[
index
])
},
()
=>
{
this
.
getLastPeriod
()
})
}
else
{
...
...
@@ -1173,6 +1173,7 @@ export default class BudgetTahunan extends Component {
status
=
{
this
.
state
.
status
}
isApprover
=
{
this
.
state
.
isApprover
}
lastStatus
=
{
this
.
state
.
lastStatus
}
prevRevision
=
{
this
.
state
.
prevRevision
}
/
>
)}
...
...
@@ -1192,6 +1193,7 @@ export default class BudgetTahunan extends Component {
status
=
{
this
.
state
.
status
}
isApprover
=
{
this
.
state
.
isApprover
}
lastStatus
=
{
this
.
state
.
lastStatus
}
prevRevision
=
{
this
.
state
.
prevRevision
}
/
>
)}
{
this
.
state
.
visibleFAM
&&
(
...
...
@@ -1210,6 +1212,7 @@ export default class BudgetTahunan extends Component {
status
=
{
this
.
state
.
status
}
isApprover
=
{
this
.
state
.
isApprover
}
lastStatus
=
{
this
.
state
.
lastStatus
}
prevRevision
=
{
this
.
state
.
prevRevision
}
/
>
)}
{
this
.
state
.
visibleCAT
&&
(
...
...
@@ -1227,6 +1230,7 @@ export default class BudgetTahunan extends Component {
getReport
=
{
this
.
getSubmission
.
bind
(
this
)}
isApprover
=
{
this
.
state
.
isApprover
}
lastStatus
=
{
this
.
state
.
lastStatus
}
prevRevision
=
{
this
.
state
.
prevRevision
}
/
>
)}
{
this
.
state
.
visibleCF
&&
(
...
...
@@ -1242,6 +1246,7 @@ export default class BudgetTahunan extends Component {
saveToMasterBudget
=
{
this
.
saveToMasterBudget
.
bind
(
this
)}
onClickClose
=
{()
=>
this
.
setState
({
visibleCF
:
false
,
visibleBudgetTahunan
:
true
})}
getReport
=
{
this
.
getSubmission
.
bind
(
this
)}
prevRevision
=
{
this
.
state
.
prevRevision
}
/
>
)}
...
...
src/container/BudgetTahunan/CorporateAnnualTarget.js
View file @
64a6d12d
...
...
@@ -87,7 +87,7 @@ export default class CorporateAnnualTarget extends Component {
componentDidMount
()
{
this
.
getItemHierarki
()
this
.
getLatestUpdate
()
console
.
log
(
this
.
props
);
console
.
log
(
this
.
props
.
lastStatus
);
this
.
getKPIType
()
this
.
getMaxAch
()
...
...
@@ -121,9 +121,9 @@ export default class CorporateAnnualTarget extends Component {
item
.
description
,
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
item
.
cat
.
weight
,
parentTrue
?
item
.
cat
.
uom
:
item
.
uom
,
item
.
cat
.
kpi_type
==
""
?
null
:
{
value
:
item
.
cat
.
kpi_type
},
item
.
cat
.
max_ach
==
""
?
null
:
{
value
:
item
.
cat
.
max_ach
},
item
.
cat
.
formula
==
""
?
null
:
{
value
:
item
.
cat
.
formula
},
parentTrue
?
item
.
cat
.
kpi_type
==
""
?
null
:
{
value
:
item
.
cat
.
kpi_type
}
:
item
.
kpi_type
==
""
?
null
:
{
value
:
item
.
kpi_type
},
parentTrue
?
item
.
cat
.
max_ach
==
""
?
null
:
{
value
:
item
.
cat
.
max_ach
}
:
item
.
max_ach
==
""
?
null
:
{
value
:
item
.
max_ach
},
parentTrue
?
item
.
cat
.
formula
==
""
?
null
:
{
value
:
item
.
cat
.
formula
}:
item
.
formula_ytd
==
""
?
null
:
{
value
:
item
.
formula_ytd
},
item
.
cat
.
total_actual_before
==
""
?
item
.
cat
.
total_actual_before
:
String
(
item
.
cat
.
total_actual_before
).
indexOf
(
"."
)
==
-
1
?
Number
(
item
.
cat
.
total_actual_before
)
:
Number
(
item
.
cat
.
total_actual_before
).
toFixed
(
1
),
item
.
cat
.
january
==
""
?
item
.
cat
.
january
:
String
(
item
.
cat
.
january
).
indexOf
(
"."
)
==
-
1
?
Number
(
item
.
cat
.
january
)
:
Number
(
item
.
cat
.
january
).
toFixed
(
1
),
item
.
cat
.
february
==
""
?
item
.
cat
.
february
:
String
(
item
.
cat
.
february
).
indexOf
(
"."
)
==
-
1
?
Number
(
item
.
cat
.
february
)
:
Number
(
item
.
cat
.
february
).
toFixed
(
1
),
...
...
@@ -216,10 +216,11 @@ export default class CorporateAnnualTarget extends Component {
console
.
log
(
'masuk'
)
let
bram
=
[
this
.
props
.
submissionID
,
this
.
props
.
report_id
,
this
.
props
.
company
.
company_id
,
this
.
props
.
periode
,
this
.
props
.
revision
]
console
.
log
(
bram
)
let
resReal
=
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
let
resNull
=
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
let
res
=
await
fetch
(
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
this
.
props
.
submissionID
==
null
?
resNull
:
resReal
)
res
=
await
res
.
blob
()
console
.
log
(
res
)
this
.
setState
({
loading
:
false
})
...
...
@@ -1078,7 +1079,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
value
}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
maxLength
=
{
4
}
onBlur
=
{(
event
)
=>
{
// updateValue(some)
...
...
@@ -1118,7 +1119,7 @@ export default class CorporateAnnualTarget extends Component {
placeholder
=
""
defaultValue
=
{
value
}
color
=
{
"#5198ea"
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
!
handleAction
(
tableMeta
.
rowData
[
2
]
)}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
!
handleAction
(
tableMeta
.
rowData
[
2
])
)}
onBlur
=
{(
event
)
=>
{
console
.
log
(
event
.
target
.
value
)
// updateValue(event.target.value)
...
...
@@ -1134,7 +1135,7 @@ export default class CorporateAnnualTarget extends Component {
placeholder
=
""
defaultValue
=
{
value
}
color
=
{
"#5198ea"
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
!
handleAction
(
tableMeta
.
rowData
[
2
]
)}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
!
handleAction
(
tableMeta
.
rowData
[
2
])
)}
onBlur
=
{(
event
)
=>
{
console
.
log
(
event
.
target
.
value
)
// updateValue(event.target.value)
...
...
@@ -1169,7 +1170,7 @@ export default class CorporateAnnualTarget extends Component {
onChange
=
{(
event
,
newInputValue
)
=>
handleChangeDropdown
(
newInputValue
,
tableMeta
)}
debug
disableClearable
disabled
=
{
this
.
props
.
isApprover
?
true
:
!
handleAction
(
tableMeta
.
rowData
[
2
]
)}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
!
handleAction
(
tableMeta
.
rowData
[
2
])
)}
value
=
{
val
}
style
=
{{
padding
:
0
,
margin
:
0
}}
renderInput
=
{(
params
)
=>
...
...
@@ -1205,7 +1206,7 @@ export default class CorporateAnnualTarget extends Component {
disableClearable
value
=
{
val
}
style
=
{{
padding
:
0
,
margin
:
0
}}
disabled
=
{
this
.
props
.
isApprover
?
true
:
!
handleAction
(
tableMeta
.
rowData
[
2
]
)}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
!
handleAction
(
tableMeta
.
rowData
[
2
])
)}
renderInput
=
{(
params
)
=>
<
div
ref
=
{
params
.
InputProps
.
ref
}
style
=
{{
padding
:
0
,
margin
:
0
}}
>
<
input
style
=
{{
borderColor
:
'white'
,
width
:
96
,
textAlign
:
'center'
,
padding
:
0
,
margin
:
0
,
color
:
handleAction
(
tableMeta
.
rowData
[
2
])
?
"#5198ea"
:
"black"
}}
type
=
"text"
{...
params
.
inputProps
}
/
>
...
...
@@ -1242,7 +1243,7 @@ export default class CorporateAnnualTarget extends Component {
debug
disableClearable
value
=
{
val
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
!
handleAction
(
tableMeta
.
rowData
[
2
]
)}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
!
handleAction
(
tableMeta
.
rowData
[
2
])
)}
style
=
{{
padding
:
0
,
margin
:
0
}}
renderInput
=
{(
params
)
=>
<
div
ref
=
{
params
.
InputProps
.
ref
}
style
=
{{
padding
:
0
,
margin
:
0
}}
>
...
...
@@ -1281,7 +1282,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1322,7 +1323,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1363,7 +1364,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1405,7 +1406,7 @@ export default class CorporateAnnualTarget extends Component {
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
decimalScale
=
{
1
}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
...
...
@@ -1445,7 +1446,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1485,7 +1486,7 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
...
...
@@ -1526,7 +1527,7 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
...
...
@@ -1568,7 +1569,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1608,8 +1609,8 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)}
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1649,7 +1650,7 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
...
...
@@ -1691,7 +1692,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1732,7 +1733,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1773,7 +1774,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1852,7 +1853,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1893,7 +1894,7 @@ export default class CorporateAnnualTarget extends Component {
type
=
"text"
placeholder
=
""
value
=
{
Number
(
value
).
toFixed
(
1
)}
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
decimalScale
=
{
1
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1931,7 +1932,7 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
fontSize
:
12
,
textAlign
:
'center'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
,
marginBottom
:
-
5
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
defaultValue
=
{
value
}
onBlur
=
{(
event
)
=>
{
console
.
log
(
event
.
target
.
value
)
...
...
@@ -1971,7 +1972,7 @@ export default class CorporateAnnualTarget extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'center'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
,
marginBottom
:
-
5
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
}
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
)
}
defaultValue
=
{
value
}
onBlur
=
{(
event
)
=>
{
console
.
log
(
event
.
target
.
value
)
...
...
@@ -2041,7 +2042,7 @@ export default class CorporateAnnualTarget extends Component {
<
/button
>
<
/a
>
<
ReactTooltip
border
=
{
true
}
id
=
"template"
place
=
"bottom"
type
=
"light"
effect
=
"solid"
/>
<
a
data
-
tip
=
{
'Upload'
}
data
-
for
=
"upload"
>
{((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
)
&&
<
a
data
-
tip
=
{
'Upload'
}
data
-
for
=
"upload"
>
<
button
style
=
{{
backgroundColor
:
'transparent'
,
...
...
@@ -2053,7 +2054,7 @@ export default class CorporateAnnualTarget extends Component {
>
<
img
src
=
{
Images
.
upload
}
/
>
<
/button
>
<
/a
>
<
/a>
}
<
ReactTooltip
border
=
{
true
}
id
=
"upload"
place
=
"bottom"
type
=
"light"
effect
=
"solid"
/>
<
a
data
-
tip
=
{
'Download'
}
data
-
for
=
"download"
>
<
button
...
...
@@ -2135,7 +2136,7 @@ export default class CorporateAnnualTarget extends Component {
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#354960'
,
textAlign
:
'center'
}}
>
Calculate
<
/Typography
>
<
/div
>
<
/button
>
<
button
{((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
)
&&
<
button
className
=
"button"
type
=
"button"
style
=
{{
...
...
@@ -2158,8 +2159,8 @@ export default class CorporateAnnualTarget extends Component {
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
/div
>
<
/button
>
<
button
<
/button>
}
{((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
)
&&
<
button
type
=
"button"
// disabled={this.state.buttonError}
onClick
=
{()
=>
this
.
state
.
buttonError
?
...
...
@@ -2179,7 +2180,7 @@ export default class CorporateAnnualTarget extends Component {
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
&
Complete
<
/Typography
>
<
/div
>
<
/button
>
<
/button>
}
<
/div>
}
<
/div
>
<
/Paper
>
...
...
@@ -2228,7 +2229,7 @@ export default class CorporateAnnualTarget extends Component {
<
/button
>
<
/div
>
{
!
this
.
props
.
isApprover
&&
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
button
{
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
&&
<
button
type
=
"button"
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
{
...
...
@@ -2242,8 +2243,8 @@ export default class CorporateAnnualTarget extends Component {
<
div
style
=
{{
backgroundColor
:
'#fff'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
,
border
:
'solid 1px #354960'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#354960'
,
textAlign
:
'center'
}}
>
Calculate
<
/Typography
>
<
/div
>
<
/button
>
<
button
<
/button>
}
{
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
&&
<
button
className
=
"button"
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
...
...
@@ -2268,8 +2269,8 @@ export default class CorporateAnnualTarget extends Component {
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
/div
>
<
/button
>
<
button
<
/button>
}
{
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
&&
<
button
type
=
"button"
style
=
{{
backgroundColor
:
'transparent'
,
...
...
@@ -2292,7 +2293,7 @@ export default class CorporateAnnualTarget extends Component {
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
&
Complete
<
/Typography
>
<
/div
>
<
/button
>
<
/button>
}
<
/div>
}
<
/div
>
<
/div
>
...
...
src/container/BudgetTahunan/FixedAssetsMovement.js
View file @
64a6d12d
...
...
@@ -396,7 +396,7 @@ export default class FixedAssetsMovement extends Component {
let
url
=
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
console
.
log
(
url
);
let
res
=
await
fetch
(
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
)
res
=
await
res
.
blob
()
this
.
setState
({
loading
:
false
})
...
...
@@ -726,7 +726,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
handleChange
(
event
.
target
.
value
,
tableMeta
)
...
...
@@ -814,7 +814,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -903,7 +903,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -992,7 +992,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1081,7 +1081,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1170,7 +1170,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1259,7 +1259,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1348,7 +1348,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1437,7 +1437,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1526,7 +1526,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1615,7 +1615,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1704,7 +1704,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1831,7 +1831,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1920,7 +1920,7 @@ export default class FixedAssetsMovement extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
src/container/BudgetTahunan/ProfitLoss.js
View file @
64a6d12d
...
...
@@ -408,9 +408,10 @@ export default class ProfitLoss extends Component {
async
downloadAllData
()
{
let
url
=
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
let
sub_null
=
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
console
.
log
(
url
);
let
res
=
await
fetch
(
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/export_master_budget?submission_id=
${
this
.
props
.
submissionID
}
&&report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
&&revision=
${
this
.
props
.
revision
}
`
this
.
props
.
submissionID
==
null
?
sub_null
:
url
)
res
=
await
res
.
blob
()
this
.
setState
({
loading
:
false
})
...
...
@@ -504,7 +505,6 @@ export default class ProfitLoss extends Component {
dataTable2
[
tableMeta
.
rowIndex
][
20
]
=
R
.
equals
(
value
,
NaN
)
?
"0.0"
:
value
return
R
.
equals
(
value
,
NaN
)
?
"0.0"
:
value
}
else
if
(
indexParent
!==
-
1
&&
String
(
dataTable2
[
indexParent
][
5
]).
toLocaleUpperCase
()
==
"GROSS PROFIT MARGIN (% OF REVENUE)"
)
{
// console.log("oke")
return
handleFormula
(
0
,
tableMeta
,
0
)
}
else
{
...
...
@@ -662,7 +662,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'left'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
defaultValue
=
{
value
}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -737,7 +737,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
handleChange
(
event
.
target
.
value
,
tableMeta
)
...
...
@@ -826,7 +826,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -916,7 +916,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1006,7 +1006,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1096,7 +1096,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1186,7 +1186,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1276,7 +1276,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1366,7 +1366,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1456,7 +1456,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1546,7 +1546,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1636,7 +1636,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1726,7 +1726,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1863,7 +1863,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1901,15 +1901,15 @@ export default class ProfitLoss extends Component {
// null
:
tableMeta
.
rowData
[
0
]
===
5
?
//
<NumberFormat
//
thousandSeparator={true}
//
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
//
type="text"
//
placeholder=""
//
disabled={true}
// val
ue={handleFormula(value, tableMeta)}
/
/ /
>
null
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleFormula
(
value
,
tableMeta
,
13
)).
toFixed
(
1
)}
ue
=
{
handleFormula
(
value
,
tableMeta
)}
/
>
//
null
:
tableMeta
.
rowData
[
0
]
===
1
?
// value === "" ?
...
...
@@ -1953,7 +1953,7 @@ export default class ProfitLoss extends Component {
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
false
:
true
}
disabled
=
{
this
.
props
.
isApprover
==
true
?
true
:
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
false
:
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
...
...
@@ -1991,15 +1991,15 @@ export default class ProfitLoss extends Component {
// null
:
tableMeta
.
rowData
[
0
]
===
5
?
//
<NumberFormat
//
thousandSeparator={true}
//
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
//
type="text"
//
placeholder=""
//
disabled={true}
// val
ue={handleFormula(value, tableMeta)}
/
/ /
>
null
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleFormula
(
value
,
tableMeta
,
14
)).
toFixed
(
1
)}
ue
=
{
handleFormula
(
value
,
tableMeta
)}
/
>
//
null
:
tableMeta
.
rowData
[
0
]
===
1
?
// value === "" ?
...
...
@@ -2072,7 +2072,7 @@ export default class ProfitLoss extends Component {
<
div
style
=
{{
width
:
'50%'
}}
>
{
this
.
props
.
isApprover
==
true
||
this
.
state
.
dataTable
.
length
==
0
?
null
:
<
div
style
=
{{
justifyContent
:
'flex-end'
,
display
:
'flex'
,
flexFlow
:
'wrap'
}}
>
{(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
(
{(
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
)
&&
(
<
div
>
<
a
data
-
tip
=
{
'Download Template'
}
data
-
for
=
"template"
>
<
button
...
...
@@ -2090,7 +2090,7 @@ export default class ProfitLoss extends Component {
<
ReactTooltip
border
=
{
true
}
id
=
"template"
place
=
"bottom"
type
=
"light"
effect
=
"solid"
/>
<
/div
>
)}
{(
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
)
&&
(
{(
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
)
&&
(
<
div
>
<
a
data
-
tip
=
{
'Upload'
}
data
-
for
=
"upload"
>
<
button
...
...
@@ -2166,7 +2166,7 @@ export default class ProfitLoss extends Component {
<
/button
>
<
/div
>
{
this
.
props
.
isApprover
===
true
||
this
.
state
.
dataTable
.
length
==
0
?
null
:
this
.
props
.
lastStatus
===
'SUBMIT'
||
this
.
props
.
lastStatus
===
'REVISION'
?
(
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
?
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
button
className
=
"button"
...
...
src/container/OprIndicator/OperatingIndicator.js
View file @
64a6d12d
...
...
@@ -128,7 +128,7 @@ export default class OperatingIndicator extends Component {
getOptionLabel
:
(
option
)
=>
titleCase
(
option
.
company_name
),
};
this
.
setState
({
listCompany
:
defaultProps
,
company
:
arrayBaru
[
0
]
},
()
=>
{
this
.
setState
({
listCompany
:
defaultProps
,
company
:
arrayBaru
.
length
<
1
?
companyData
[
0
]
:
arrayBaru
[
0
]
},
()
=>
{
this
.
getPeriode
()
})
}
else
{
...
...
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