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
480e7a56
Commit
480e7a56
authored
Dec 10, 2020
by
d.arizona
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
uponuphill
parent
8d006290
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
141 additions
and
140 deletions
+141
-140
CorporateAnnualTarget.js
src/container/BudgetTahunan/CorporateAnnualTarget.js
+141
-140
No files found.
src/container/BudgetTahunan/CorporateAnnualTarget.js
View file @
480e7a56
...
...
@@ -94,8 +94,8 @@ export default class CorporateAnnualTarget extends Component {
this
.
getKPIType
()
this
.
getMaxAch
()
this
.
getLatestUpdate
()
// // console.log(this.props.status)
// // // console.log(this.props.lastStatus);
// //
//
console.log(this.props.status)
// // //
//
console.log(this.props.lastStatus);
}
...
...
@@ -108,7 +108,7 @@ export default class CorporateAnnualTarget extends Component {
"company_id"
:
this
.
props
.
company
.
company_id
,
"submission_id"
:
this
.
props
.
submissionID
}
// // console.log(JSON.stringify(payload))
// //
//
console.log(JSON.stringify(payload))
api
.
create
().
getDetailReportMB
(
payload
).
then
(
response
=>
{
let
dataTable
=
[]
let
dataCustomerPrs
=
[]
...
...
@@ -173,7 +173,7 @@ export default class CorporateAnnualTarget extends Component {
item
.
level
,
""
,
item
.
description
,
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
(
String
(
item
.
cat
.
weight
).
indexOf
(
"."
)
==
-
1
?
item
.
cat
.
weight
:
`
${
Number
(
item
.
weight
)
*
100
}
%`
),
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
(
String
(
Number
(
String
(
item
.
cat
.
weight
).
substr
(
0
,
String
(
item
.
cat
.
weight
).
length
-
1
)).
toFixed
(
1
))
+
'%'
),
parentTrue
?
item
.
cat
.
uom
:
item
.
uom
,
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
:
titleCase
(
item
.
cat
.
max_ach
)
}
:
item
.
max_ach
==
""
?
null
:
{
value
:
titleCase
(
item
.
max_ach
)
},
...
...
@@ -217,7 +217,7 @@ export default class CorporateAnnualTarget extends Component {
item
.
level
,
""
,
item
.
description
,
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
item
.
cat
.
weight
,
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
(
String
(
Number
(
String
(
item
.
cat
.
weight
).
substr
(
0
,
String
(
item
.
cat
.
weight
).
length
-
1
)).
toFixed
(
1
))
+
'%'
)
,
item
.
cat
.
uom
,
item
.
kpi_type
==
""
?
null
:
{
value
:
item
.
kpi_type
},
item
.
max_ach
==
""
?
null
:
{
value
:
titleCase
(
item
.
max_ach
)
},
...
...
@@ -251,9 +251,9 @@ export default class CorporateAnnualTarget extends Component {
}
}
})
// console.log(dataTable)
//
//
console.log(dataTable)
this
.
setState
({
dataTable
,
loading
:
false
,
dataReal
:
res
,
editable
:
true
,
dataCustomerPrs
,
dataInternalBsn
,
dataFin
,
dataLearn
},
()
=>
{
// // console.log(dataCustomerPrs)
// //
//
console.log(dataCustomerPrs)
})
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
loading
:
false
},
()
=>
{
...
...
@@ -281,7 +281,7 @@ export default class CorporateAnnualTarget extends Component {
`https://tia.eksad.com/tia-reporting-dev/public/transaction/master_budget/download_template?report_id=
${
this
.
props
.
report_id
}
&&company_id=
${
this
.
props
.
company
.
company_id
}
&&year=
${
this
.
props
.
periode
}
`
)
res
=
await
res
.
blob
()
// // // console.log(res)
// // //
//
console.log(res)
if
(
res
.
size
>
0
)
{
let
url
=
window
.
URL
.
createObjectURL
(
res
);
let
a
=
document
.
createElement
(
'a'
);
...
...
@@ -292,16 +292,16 @@ export default class CorporateAnnualTarget extends Component {
}
async
downloadAllData
()
{
// // // console.log('masuk')
// // //
//
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)
// // //
//
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
(
this
.
props
.
submissionID
==
null
?
resNull
:
resReal
)
res
=
await
res
.
blob
()
// // // console.log(res)
// // //
//
console.log(res)
this
.
setState
({
loading
:
false
})
if
(
res
.
size
>
0
)
{
let
url
=
window
.
URL
.
createObjectURL
(
res
);
...
...
@@ -315,13 +315,13 @@ export default class CorporateAnnualTarget extends Component {
fileHandler
=
(
event
)
=>
{
let
fileObj
=
event
ExcelRenderer
(
fileObj
,
(
err
,
resp
)
=>
{
// // // // console.log(resp)
// // // //
//
console.log(resp)
if
(
err
)
{
// // // console.log(err);
// // //
//
console.log(err);
}
else
{
let
isi
=
resp
.
rows
.
slice
(
3
)
// console.log(isi);
//
//
console.log(isi);
let
payload
=
[]
let
reg
=
/^
[
-+
]?(?:[
0-9
]
+,
)
*
[
0-9
]
+
(?:\.[
0-9
]
+
)?
$/
;
let
newValidate
=
false
...
...
@@ -358,7 +358,7 @@ export default class CorporateAnnualTarget extends Component {
payload
.
push
({
item_report_id
:
i
[
0
]
===
undefined
?
0
:
reg
.
test
(
String
(
i
[
0
]))
===
false
?
0
:
String
(
i
[
0
]).
trim
(),
item_report
:
i
[
1
]
===
undefined
?
""
:
String
(
i
[
1
]).
trim
(),
weight
:
i
[
2
]
===
undefined
?
""
:
(
String
(
i
[
2
]).
includes
(
'%'
)?
String
(
i
[
2
].
trim
())
:
(
String
(
Number
(
i
[
2
]
*
100
)).
length
>
3
?
String
(
Number
(
i
[
2
]
*
100
).
toFixed
(
0
)
+
'%'
)
:
String
(
Number
(
i
[
2
]
*
100
))
+
'%'
))
,
weight
:
i
[
2
]
===
undefined
?
""
:
String
(
Number
(
i
[
2
]
*
100
).
toFixed
(
1
))
+
'%'
,
uom
:
i
[
3
]
===
undefined
?
""
:
String
(
i
[
3
]).
trim
(),
kpi_type
:
i
[
4
]
===
undefined
?
""
:
String
(
i
[
4
]).
trim
(),
max_ach
:
i
[
5
]
===
undefined
?
""
:
String
(
i
[
5
]).
toLocaleLowerCase
()
!==
'unlimited'
?
(
String
(
i
[
5
]).
includes
(
'%'
)?
String
(
i
[
5
].
trim
())
:
String
(
Number
(
i
[
5
]
*
100
)
+
'%'
))
:
String
(
i
[
5
]).
trim
(),
...
...
@@ -387,7 +387,7 @@ export default class CorporateAnnualTarget extends Component {
payload
.
push
({
item_report_id
:
i
[
0
]
===
undefined
?
0
:
reg
.
test
(
String
(
i
[
0
]))
===
false
?
0
:
String
(
i
[
0
]).
trim
(),
item_report
:
i
[
1
]
===
undefined
?
""
:
String
(
i
[
1
]).
trim
(),
weight
:
i
[
2
]
===
undefined
?
""
:
(
String
(
i
[
2
]).
includes
(
'%'
)?
String
(
i
[
2
].
trim
())
:
(
String
(
Number
(
i
[
2
]
*
100
)).
length
>
3
?
String
(
Number
(
i
[
2
]
*
100
).
toFixed
(
0
)
+
'%'
)
:
String
(
Number
(
i
[
2
]
*
100
))
+
'%'
))
,
weight
:
i
[
2
]
===
undefined
?
""
:
String
(
Number
(
i
[
2
]
*
100
).
toFixed
(
1
))
+
'%'
,
uom
:
i
[
3
]
===
undefined
?
""
:
String
(
i
[
3
]).
trim
(),
kpi_type
:
i
[
4
]
===
undefined
?
""
:
String
(
i
[
4
]).
trim
(),
max_ach
:
i
[
5
]
===
undefined
?
""
:
String
(
i
[
5
]).
toLocaleLowerCase
()
!==
'unlimited'
?
(
String
(
i
[
5
]).
includes
(
'%'
)?
String
(
i
[
5
].
trim
())
:
String
(
Number
(
i
[
5
]
*
100
)
+
'%'
))
:
String
(
i
[
5
]).
trim
(),
...
...
@@ -412,14 +412,14 @@ export default class CorporateAnnualTarget extends Component {
pic
:
i
[
24
]
===
undefined
?
""
:
String
(
i
[
24
]).
trim
()
})
}
// console.log(i[2])
// // console.log(Number(i[2] * 100))
// // // // console.log(i[2] === undefined ? "" : String(Number(i[2]*100)).length > 3? String(Number(i[2]*100).toFixed(0) + '%') : String(Number(i[2]*100)) + '%')
//
//
console.log(i[2])
// //
//
console.log(Number(i[2] * 100))
// // // //
//
console.log(i[2] === undefined ? "" : String(Number(i[2]*100)).length > 3? String(Number(i[2]*100).toFixed(0) + '%') : String(Number(i[2]*100)) + '%')
}
})
// console.log(payload)
//
//
console.log(payload)
let
body
=
{
company_id
:
this
.
props
.
company
.
company_id
,
periode
:
this
.
props
.
periode
,
...
...
@@ -427,7 +427,7 @@ export default class CorporateAnnualTarget extends Component {
status
:
''
,
cat
:
payload
}
// // // console.log(body)
// // //
//
console.log(body)
this
.
setState
({
payload
:
body
,
judul
:
resp
.
rows
[
1
][
0
]
})
}
});
...
...
@@ -438,7 +438,7 @@ export default class CorporateAnnualTarget extends Component {
let
dataDelete
=
this
.
state
.
dataDelete
api
.
create
().
getIdDeleteFromExcel
(
this
.
state
.
payload
).
then
((
response
)
=>
{
if
(
response
.
data
)
{
// // // // console.log(response.data)
// // // //
//
console.log(response.data)
let
idDelete
=
response
.
data
.
data
.
item_report_id
if
(
idDelete
.
length
>
0
)
{
idDelete
.
map
((
item
,
index
)
=>
{
...
...
@@ -450,7 +450,7 @@ export default class CorporateAnnualTarget extends Component {
})
// console.log(this.state.payload)
api
.
create
().
checkUploadMB
(
this
.
state
.
payload
).
then
(
response
=>
{
// console.log(JSON.stringify(this.state.payload));
//
//
console.log(JSON.stringify(this.state.payload));
// console.log(response)
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
...
...
@@ -512,7 +512,7 @@ export default class CorporateAnnualTarget extends Component {
item
.
level
==
null
?
1
:
item
.
level
,
""
,
item
.
item_report
,
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
(
String
(
item
.
weight
)
.
indexOf
(
"."
)
==
-
1
?
item
.
weight
:
`
${
Number
(
item
.
weight
)
*
100
}
%`
),
item
.
type_report_id
==
1
?
`
${
Number
(
item
.
weight
)
*
100
}
%`
:
(
String
(
item
.
weight
)),
item
.
uom
,
item
.
kpi_type
==
""
||
item
.
kpi_type
==
null
?
null
:
{
value
:
item
.
kpi_type
},
item
.
max_ach
==
""
||
item
.
max_ach
==
null
?
null
:
{
value
:
titleCase
(
item
.
max_ach
)
},
...
...
@@ -547,17 +547,17 @@ export default class CorporateAnnualTarget extends Component {
if
(
checkDataFin
.
length
>
0
||
checkDataLearn
.
length
>
0
)
{
handleDataSalah
=
true
}
// console.log(indexCheck)
// // // console.log(this.state.buttonError)
// console.log(dataTable)
//
//
console.log(indexCheck)
// // //
//
console.log(this.state.buttonError)
//
//
console.log(dataTable)
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
,
editable
:
true
,
dataDelete
,
handleDataSalah
},
()
=>
{
this
.
state
.
dataTable
.
map
(
item
=>
{
if
(
item
[
30
].
length
>
0
)
{
// // // console.log('masuk')
// // //
//
console.log('masuk')
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
,
editable
:
true
})
}
})
// // // // console.log(this.state.dataTable);
// // // //
//
console.log(this.state.dataTable);
})
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
loading
:
false
},
()
=>
{
...
...
@@ -580,7 +580,7 @@ export default class CorporateAnnualTarget extends Component {
uploadCAT
(
type
)
{
// let dataDelete = this.state.dataDelete
// // // console.log(dataDelete)
// // //
//
console.log(dataDelete)
let
payload
=
{
"item_report_id"
:
this
.
state
.
dataDelete
}
if
(
this
.
state
.
dataDelete
.
length
>
0
)
{
api
.
create
().
deleteAllItemReport
(
payload
).
then
((
response
)
=>
{
...
...
@@ -595,7 +595,7 @@ export default class CorporateAnnualTarget extends Component {
functionUpload
(
type
)
{
let
data
=
[]
let
stateFR
=
false
// // console.log(this.state.dataTable)
// //
//
console.log(this.state.dataTable)
this
.
state
.
dataTable
.
map
(
i
=>
{
if
(
i
[
2
]
!==
null
)
{
let
indexID
=
this
.
state
.
dataTable
.
findIndex
((
val
)
=>
val
[
1
]
==
i
[
2
])
...
...
@@ -647,10 +647,10 @@ export default class CorporateAnnualTarget extends Component {
"status"
:
type
,
"cat"
:
data
}
// console.log(data);
// console.log(JSON.stringify(body))
//
//
console.log(data);
//
//
console.log(JSON.stringify(body))
api
.
create
(
'UPLOAD'
).
uploadMasterBudget
(
body
).
then
(
response
=>
{
// // // console.log(response);
// // //
//
console.log(response);
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
"success"
)
{
...
...
@@ -677,7 +677,7 @@ export default class CorporateAnnualTarget extends Component {
handleValidate
()
{
let
data
=
[]
// // console.log(this.state.dataTable)
// //
//
console.log(this.state.dataTable)
let
totalWeight
=
0
let
dataTableBaru
=
this
.
state
.
dataTable
let
dataTampung
=
[]
...
...
@@ -699,14 +699,14 @@ export default class CorporateAnnualTarget extends Component {
if
(
i
[
2
]
!==
null
)
{
let
indexID
=
this
.
state
.
dataTable
.
findIndex
((
val
)
=>
val
[
1
]
==
i
[
2
])
// // // console.log(indexID)
// // // console.log(i[2])
// // //
//
console.log(indexID)
// // //
//
console.log(i[2])
if
(
indexID
!==
-
1
)
{
// // // console.log(dataTableBaru[indexID][6])
// // //
//
console.log(dataTableBaru[indexID][6])
if
(
dataTableBaru
[
indexID
][
6
]
==
'INTERNAL BUSINESS PROCESS PERSPECTIVE'
||
dataTableBaru
[
indexID
][
6
]
==
'CUSTOMER PERSPECTIVE'
)
{
if
(
i
[
6
]
==
""
||
i
[
7
]
==
""
||
i
[
9
]
==
null
||
i
[
10
]
==
null
||
i
[
11
]
==
null
)
{
handleKosongKPIMAXYTD
=
true
// // // console.log(handleKosongKPIMAXYTD)
// // //
//
console.log(handleKosongKPIMAXYTD)
}
}
else
if
(
dataTableBaru
[
indexID
][
6
]
===
'FINANCIAL PERSPECTIVE'
)
{
stateFR
=
true
...
...
@@ -719,7 +719,7 @@ export default class CorporateAnnualTarget extends Component {
// if (i[0] == null && i[2] == null) {
// if (i[6] == "" || i[7] == "" || i[9] == null || i[10] == null || i[11] == null) {
// handleKosongKPIMAXYTD = true
// // // // console.log(handleKosongKPIMAXYTD)
// // // //
//
console.log(handleKosongKPIMAXYTD)
// }
// }
...
...
@@ -739,17 +739,18 @@ export default class CorporateAnnualTarget extends Component {
weightReal
=
i
[
7
]
dataTampung
[
indexID
].
valChild
=
dataTampung
[
indexID
].
valChild
+
Number
(
i
[
7
]
==
""
||
i
[
7
]
==
undefined
?
0
:
i
[
7
].
replace
(
'%'
,
''
))
}
// // // console.log(weightReal)
// // // console.log(dataTableBaru[index][7])
// // // console.log(dataTampung[indexID].valChild)
// // //
//
console.log(weightReal)
// // //
//
console.log(dataTableBaru[index][7])
// // //
//
console.log(dataTampung[indexID].valChild)
}
}
// // console.log(String(weightReal).substr(0,String(weightReal).length-1))
// // console.log(Number(String(weightReal).substr(0,String(weightReal).length-1)).toFixed(1));
data
.
push
({
"item_report_id"
:
i
[
1
]
==
""
||
i
[
1
]
==
null
?
0
:
i
[
1
],
"item_name"
:
String
(
i
[
6
]),
"parent"
:
i
[
2
]
==
""
?
null
:
i
[
2
],
"weight"
:
weightReal
==
null
?
String
(
i
[
7
])
:
weightReal
,
"weight"
:
weightReal
==
null
?
String
(
i
[
7
])
:
String
(
Number
(
String
(
weightReal
).
substr
(
0
,
String
(
weightReal
).
length
-
1
)).
toFixed
(
1
))
+
'%'
,
"uom"
:
String
(
i
[
8
]),
"kpi_type"
:
i
[
9
]
==
null
?
""
:
i
[
9
].
value
,
"max_ach"
:
i
[
10
]
==
null
?
""
:
i
[
10
].
value
,
...
...
@@ -775,8 +776,8 @@ export default class CorporateAnnualTarget extends Component {
})
})
// // // console.log(dataTableBaru)
// // // console.log(JSON.stringify(data))
// // //
//
console.log(dataTableBaru)
// // //
//
console.log(JSON.stringify(data))
let
payload
=
{
"submission_id"
:
this
.
props
.
submissionID
,
"company_id"
:
this
.
props
.
company
.
company_id
,
...
...
@@ -785,7 +786,7 @@ export default class CorporateAnnualTarget extends Component {
"status"
:
"submitted"
,
"cat"
:
data
}
// // // console.log(totalWeight)
// // //
//
console.log(totalWeight)
// this.setState({dataTable: dataTampung})
if
(
handleKosongKPIMAXYTD
)
{
this
.
setState
({
alert
:
true
,
messageAlert
:
'KPI / Weight / KPI Type / Max Ach / Formula YTD / Cannot be Empty'
,
tipeAlert
:
'warning'
,
loading
:
false
,
editable
:
true
})
...
...
@@ -793,7 +794,7 @@ export default class CorporateAnnualTarget extends Component {
this
.
setState
({
alert
:
true
,
messageAlert
:
'Total weight less than 100%'
,
tipeAlert
:
'warning'
,
loading
:
false
,
editable
:
true
})
}
else
{
api
.
create
().
validateSubmitReport
(
payload
).
then
((
response
)
=>
{
// // // console.log(response)
// // //
//
console.log(response)
if
(
response
.
data
.
data
.
result
)
{
this
.
setState
({
loading
:
false
,
buttonError
:
false
,
editable
:
false
,
buttonDraft
:
false
})
}
else
{
...
...
@@ -810,14 +811,14 @@ export default class CorporateAnnualTarget extends Component {
backToMasterBudget
(
type
)
{
let
data
=
[]
let
stateFR
=
false
// // console.log(this.state.dataTable)
// //
//
console.log(this.state.dataTable)
this
.
state
.
dataTable
.
map
(
i
=>
{
if
(
i
[
2
]
!==
null
)
{
let
indexID
=
this
.
state
.
dataTable
.
findIndex
((
val
)
=>
val
[
1
]
==
i
[
2
])
// // // console.log(indexID)
// // // console.log(i[2])
// // //
//
console.log(indexID)
// // //
//
console.log(i[2])
if
(
indexID
!==
-
1
)
{
// // // console.log(dataTableBaru[indexID][6])
// // //
//
console.log(dataTableBaru[indexID][6])
if
(
this
.
state
.
dataTable
[
indexID
][
6
]
===
'FINANCIAL PERSPECTIVE'
)
{
stateFR
=
true
}
else
{
...
...
@@ -827,7 +828,7 @@ export default class CorporateAnnualTarget extends Component {
}
else
{
stateFR
=
false
}
// // // // console.log(i[9] == null? "" : i[9].value)
// // // //
//
console.log(i[9] == null? "" : i[9].value)
data
.
push
({
"item_report_id"
:
i
[
1
]
==
""
||
i
[
1
]
==
null
?
0
:
i
[
1
],
"item_name"
:
String
(
i
[
6
]),
...
...
@@ -857,7 +858,7 @@ export default class CorporateAnnualTarget extends Component {
"pic"
:
String
(
i
[
29
])
})
})
// // console.log(JSON.stringify(data))
// //
//
console.log(JSON.stringify(data))
let
payload
=
{
"submission_id"
:
this
.
props
.
submissionID
,
"company_id"
:
this
.
props
.
company
.
company_id
,
...
...
@@ -866,7 +867,7 @@ export default class CorporateAnnualTarget extends Component {
"status"
:
type
,
"cat"
:
data
}
//
//
console.log(JSON.stringify(payload));
// console.log(JSON.stringify(payload));
this
.
deleteReport
(
payload
)
}
...
...
@@ -875,10 +876,10 @@ export default class CorporateAnnualTarget extends Component {
if
(
this
.
state
.
dataDelete
.
length
>
0
)
{
api
.
create
().
deleteAllItemReport
(
payload
).
then
((
response
)
=>
{
// // // console.log(response)
// // //
//
console.log(response)
// api.create().validateSubmitReport(payloadBro).then((response) => {
// // // // console.log(response)
// // // //
//
console.log(response)
// if (response.data.data.result) {
this
.
props
.
saveToMasterBudget
(
payloadBro
)
this
.
props
.
onClickClose
()
...
...
@@ -888,9 +889,9 @@ export default class CorporateAnnualTarget extends Component {
// })
})
}
else
{
// // // // console.log('sini jing')
// // // //
//
console.log('sini jing')
// api.create().validateSubmitReport(payloadBro).then((response) => {
// // // // console.log(response)
// // // //
//
console.log(response)
// if (response.data.data.result) {
this
.
props
.
saveToMasterBudget
(
payloadBro
)
this
.
props
.
onClickClose
()
...
...
@@ -909,12 +910,12 @@ export default class CorporateAnnualTarget extends Component {
type
:
'KPI_TYPE'
}
api
.
create
().
getAllSettingByType
(
body
).
then
(
response
=>
{
// // // // console.log(response)
// // // //
//
console.log(response)
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
'success'
)
{
let
data
=
response
.
data
.
data
// // // console.log(data)
// // //
//
console.log(data)
let
inputKPI
=
[]
data
.
map
((
item
)
=>
{
...
...
@@ -926,7 +927,7 @@ export default class CorporateAnnualTarget extends Component {
options
:
inputKPI
,
getOptionLabel
:
(
option
)
=>
titleCase
(
option
.
value
),
};
// // // console.log(defaultProps)
// // //
//
console.log(defaultProps)
this
.
setState
({
kpiTypeList
:
defaultProps
})
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
},
()
=>
{
...
...
@@ -1053,7 +1054,7 @@ export default class CorporateAnnualTarget extends Component {
let
columnEnd
=
24
let
month
=
column
-
1
let
total
=
0
// // console.log(formulaAwal)
// //
//
console.log(formulaAwal)
if
(
forecast
==
undefined
)
{
dataTable2
[
tableMeta
.
rowIndex
].
map
((
itemz
,
indexz
)
=>
{
if
(
indexz
>=
columnStart
&&
indexz
<=
columnStart
+
month
)
{
...
...
@@ -1090,10 +1091,10 @@ export default class CorporateAnnualTarget extends Component {
anjay
.
push
(
valuezz
==
""
?
0
:
valuezz
)
}
}
else
{
// // console.log(dataTable2[tableMeta.rowIndex][30])
// //
//
console.log(dataTable2[tableMeta.rowIndex][30])
let
array
=
dataTable2
[
tableMeta
.
rowIndex
][
30
].
filter
((
val
)
=>
val
.
periode
==
Number
(
column
))
let
valuezz
=
array
[
0
].
value
// // console.log(valuezz)
// //
//
console.log(valuezz)
anjay
.
push
(
valuezz
==
""
?
0
:
valuezz
)
// let indexID = dataTable2[tableMeta.rowIndex][30].findIndex((val) => val.periode == Number(this.props.periode))
// if (indexID !== -1) {
...
...
@@ -1251,21 +1252,21 @@ export default class CorporateAnnualTarget extends Component {
}
})
// if (dataTable2[tableMeta.rowIndex][6] == "NPAT" && forecast !== undefined) {
// // console.log(tableMeta.rowData[3])
// // console.log(splitFormula)
// // console.log(baru)
// // console.log(anjay)
// // // console.log(item1)
// // console.log(anjay2)
// // console.log(total)
// //
//
console.log(tableMeta.rowData[3])
// //
//
console.log(splitFormula)
// //
//
console.log(baru)
// //
//
console.log(anjay)
// // //
//
console.log(item1)
// //
//
console.log(anjay2)
// //
//
console.log(total)
// }
// // console.log(tableMeta.rowData[3])
// // console.log(splitFormula)
// // console.log(baru)
// // console.log(anjay)
// // console.log(item1)
// // console.log(anjay2)
// // console.log(total)
// //
//
console.log(tableMeta.rowData[3])
// //
//
console.log(splitFormula)
// //
//
console.log(baru)
// //
//
console.log(anjay)
// //
//
console.log(item1)
// //
//
console.log(anjay2)
// //
//
console.log(total)
total
=
dataTable2
[
tableMeta
.
rowIndex
][
6
]
==
"ROIC"
?
"0"
:
R
.
equals
(
total
,
NaN
)
?
"0.0"
:
total
if
(
dataTable2
[
tableMeta
.
rowIndex
][
6
]
==
"ROIC"
)
{
...
...
@@ -1383,7 +1384,7 @@ export default class CorporateAnnualTarget extends Component {
}
const
handleTambah
=
(
data
,
rowIndex
)
=>
{
// // console.log(dataTable2)
// //
//
console.log(dataTable2)
let
newData
=
[]
dataTable2
.
map
((
item
,
index
)
=>
{
newData
.
push
(
item
)
...
...
@@ -1427,7 +1428,7 @@ export default class CorporateAnnualTarget extends Component {
this
.
setState
({
dataTable
:
dataTable2
},
()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
loading
:
false
})
// // console.log(dataTable2)
// //
//
console.log(dataTable2)
},
500
)
})
}
...
...
@@ -1516,7 +1517,7 @@ export default class CorporateAnnualTarget extends Component {
cursor
:
'pointer'
,
borderColor
:
'transparent'
,
}}
// onClick={() => // // // console.log(tableMeta.rowData[1])}
// onClick={() => // // //
//
console.log(tableMeta.rowData[1])}
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
})
handleTambah
(
tableMeta
.
rowData
[
1
],
tableMeta
.
rowIndex
)
...
...
@@ -1572,9 +1573,9 @@ export default class CorporateAnnualTarget extends Component {
defaultValue
=
{
val
}
// disabled={!handleAction(tableMeta.rowData[2])}
onBlur
=
{(
event
)
=>
{
// // // console.log(event.target.value)
// // //
//
console.log(event.target.value)
handleChangeText
(
event
.
target
.
value
,
tableMeta
)
// // console.log(dataTable2)
// //
//
console.log(dataTable2)
}}
/
>
}
...
...
@@ -1689,10 +1690,10 @@ export default class CorporateAnnualTarget extends Component {
color
=
{
"#5198ea"
}
disabled
=
{
true
}
onBlur
=
{(
event
)
=>
{
// // // console.log(event.target.value)
// // //
//
console.log(event.target.value)
// updateValue(event.target.value)
handleChangeText
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(dataTable2)
// // //
//
console.log(dataTable2)
}}
/>
:
<
ThemeProvider
theme
=
{
theme
}
>
...
...
@@ -1705,10 +1706,10 @@ export default class CorporateAnnualTarget extends Component {
color
=
{
"#5198ea"
}
// 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)
// // //
//
console.log(event.target.value)
// updateValue(event.target.value)
handleChangeText
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(dataTable2)
// // //
//
console.log(dataTable2)
}}
/
>
<
/ThemeProvider
>
...
...
@@ -1855,7 +1856,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(dataTable2)
// // //
//
console.log(dataTable2)
}}
/
>
}
...
...
@@ -1875,7 +1876,7 @@ export default class CorporateAnnualTarget extends Component {
<
/TableCell
>
),
customBodyRender
:
(
value
,
tableMeta
)
=>
{
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
return
(
<
div
style
=
{{
width
:
96
}}
>
{
...
...
@@ -1894,7 +1895,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -1919,7 +1920,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -1942,7 +1943,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -1980,7 +1981,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2005,7 +2006,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2028,7 +2029,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2066,7 +2067,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2091,7 +2092,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2114,7 +2115,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2153,7 +2154,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2178,7 +2179,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2201,7 +2202,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2240,7 +2241,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2265,7 +2266,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2288,7 +2289,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2327,7 +2328,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2352,7 +2353,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2375,7 +2376,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2414,7 +2415,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2439,7 +2440,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2462,7 +2463,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2501,7 +2502,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2526,7 +2527,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2549,7 +2550,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2588,7 +2589,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2613,7 +2614,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2636,7 +2637,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2675,7 +2676,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2700,7 +2701,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2723,7 +2724,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2762,7 +2763,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2787,7 +2788,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2810,7 +2811,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2849,7 +2850,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2874,7 +2875,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2897,7 +2898,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2937,7 +2938,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2962,7 +2963,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -2985,7 +2986,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3024,7 +3025,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3049,7 +3050,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3072,7 +3073,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3111,7 +3112,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3136,7 +3137,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3159,7 +3160,7 @@ export default class CorporateAnnualTarget extends Component {
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(tableMeta.rowData[0])
// // //
//
console.log(tableMeta.rowData[0])
}}
/
>
}
...
...
@@ -3196,9 +3197,9 @@ export default class CorporateAnnualTarget extends Component {
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
&&
(
this
.
props
.
status
===
'revision'
||
this
.
props
.
status
===
'not-yet'
||
this
.
props
.
status
===
'draft'
||
this
.
props
.
status
===
'submitted'
)
?
false
:
true
)}
defaultValue
=
{
value
}
onBlur
=
{(
event
)
=>
{
// // // console.log(event.target.value)
// // //
//
console.log(event.target.value)
handleChangeText
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(dataTable2)
// // //
//
console.log(dataTable2)
}}
/
>
<
/ThemeProvider
>
...
...
@@ -3236,10 +3237,10 @@ export default class CorporateAnnualTarget extends Component {
disabled
=
{
this
.
props
.
isApprover
?
true
:
((
this
.
props
.
lastStatus
==
'SUBMIT'
||
this
.
props
.
lastStatus
==
'REVISION'
)
&&
this
.
props
.
prevRevision
===
false
&&
(
this
.
props
.
status
===
'revision'
||
this
.
props
.
status
===
'not-yet'
||
this
.
props
.
status
===
'draft'
||
this
.
props
.
status
===
'submitted'
)
?
false
:
true
)}
defaultValue
=
{
value
}
onBlur
=
{(
event
)
=>
{
// // // console.log(event.target.value)
// // //
//
console.log(event.target.value)
// updateValue(event.target.value)
handleChangeText
(
event
.
target
.
value
,
tableMeta
)
// // // console.log(dataTable2)
// // //
//
console.log(dataTable2)
}}
/
>
<
/ThemeProvider
>
...
...
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