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
2c2b0d05
Commit
2c2b0d05
authored
Oct 03, 2023
by
Riri Novita
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update olpa
parent
c6c3bbc2
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
378 additions
and
201 deletions
+378
-201
OutlookPA.js
src/container/OutlookPA/OutlookPA.js
+2
-2
ProfitLossOLPA.js
src/container/OutlookPA/ProfitLossOLPA.js
+341
-165
TaxPlanningOLPA.js
src/container/OutlookPA/TaxPlanningOLPA.js
+35
-34
No files found.
src/container/OutlookPA/OutlookPA.js
View file @
2c2b0d05
...
...
@@ -1750,9 +1750,9 @@ export default class OutlookPA extends Component {
borderColor
:
'transparent'
}}
onClick
=
{()
=>
tableMeta
.
rowData
[
5
]
==
true
||
(
this
.
state
.
periode
.
periode
==
'2020'
&&
tableMeta
.
rowData
[
1
]
==
'Balance Sheet'
&&
tableMeta
.
rowData
[
3
]
==
'CLOSED'
)
?
//
tableMeta.rowData[5] == true || (this.state.periode.periode == '2020' && tableMeta.rowData[1] == 'Balance Sheet' && tableMeta.rowData[3] == 'CLOSED') ?
this
.
clickDetail
(
tableMeta
.
rowData
[
1
],
tableMeta
.
rowData
[
4
],
tableMeta
.
rowData
[
2
],
tableMeta
.
rowData
[
3
])
:
null
//
: null
}
>
{
/* {this.state.isApprover == true ?
...
...
src/container/OutlookPA/ProfitLossOLPA.js
View file @
2c2b0d05
...
...
@@ -66,7 +66,8 @@ export default class ProfitLossOLPA extends Component {
viewOnly
:
true
,
get_for
:
'view'
,
defaultCurrencyUpload
:
this
.
props
.
defaultCurrency
,
visibleAlertSave
:
false
visibleAlertSave
:
false
,
visibleButtonUpload
:
false
}
this
.
handleValue
=
this
.
handleValue
.
bind
(
this
)
this
.
fileHandler
=
this
.
fileHandler
.
bind
(
this
);
...
...
@@ -76,7 +77,7 @@ export default class ProfitLossOLPA extends Component {
componentDidMount
()
{
this
.
getItemHierarki
()
this
.
getLatestUpdate
()
this
.
handleViewOnly
()
//
this.handleViewOnly()
// console.log(this.props);
}
...
...
@@ -184,21 +185,21 @@ export default class ProfitLossOLPA extends Component {
item
.
description
,
item
.
profit_loss
.
notes
===
""
?
null
:
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
total_actual_before
===
null
?
"0.0"
:
item
.
profit_loss
.
total_actual_before
===
""
?
"0"
:
item
.
profit_loss
.
total_actual_before
,
Number
(
item
.
profit_loss
.
january
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
february
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
march
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
april
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
may
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
june
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
july
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
august
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
september
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
october
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
november
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
december
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
total_current_year
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
ytd_october
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
nov_dec
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
january
),
Number
(
item
.
profit_loss
.
february
),
Number
(
item
.
profit_loss
.
march
),
Number
(
item
.
profit_loss
.
april
),
Number
(
item
.
profit_loss
.
may
),
Number
(
item
.
profit_loss
.
june
),
Number
(
item
.
profit_loss
.
july
),
Number
(
item
.
profit_loss
.
august
),
Number
(
item
.
profit_loss
.
september
),
Number
(
item
.
profit_loss
.
october
),
Number
(
item
.
profit_loss
.
november
),
Number
(
item
.
profit_loss
.
december
),
Number
(
item
.
profit_loss
.
total_current_year
),
Number
(
item
.
profit_loss
.
ytd_october
),
Number
(
item
.
profit_loss
.
nov_dec
),
item
.
order
])
}
...
...
@@ -220,21 +221,21 @@ export default class ProfitLossOLPA extends Component {
item
.
description
,
item
.
profit_loss
.
notes
===
""
?
null
:
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
total_actual_before
===
null
?
"0.0"
:
item
.
profit_loss
.
total_actual_before
===
""
?
"0"
:
item
.
profit_loss
.
total_actual_before
,
Number
(
item
.
profit_loss
.
january
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
february
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
march
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
april
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
may
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
june
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
july
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
august
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
september
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
october
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
november
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
december
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
total_current_year
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
ytd_october
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
nov_dec
)
.
toFixed
(
1
)
,
Number
(
item
.
profit_loss
.
january
),
Number
(
item
.
profit_loss
.
february
),
Number
(
item
.
profit_loss
.
march
),
Number
(
item
.
profit_loss
.
april
),
Number
(
item
.
profit_loss
.
may
),
Number
(
item
.
profit_loss
.
june
),
Number
(
item
.
profit_loss
.
july
),
Number
(
item
.
profit_loss
.
august
),
Number
(
item
.
profit_loss
.
september
),
Number
(
item
.
profit_loss
.
october
),
Number
(
item
.
profit_loss
.
november
),
Number
(
item
.
profit_loss
.
december
),
Number
(
item
.
profit_loss
.
total_current_year
),
Number
(
item
.
profit_loss
.
ytd_october
),
Number
(
item
.
profit_loss
.
nov_dec
),
item
.
order
])
if
(
item
.
children
!==
null
)
{
...
...
@@ -295,22 +296,22 @@ export default class ProfitLossOLPA extends Component {
data
.
push
({
item_report_id
:
i
[
1
],
notes
:
i
[
6
]
==
null
||
i
[
6
]
==
""
?
""
:
String
(
i
[
6
]),
total_actual_before
:
String
(
Number
(
i
[
7
])
.
toFixed
(
1
)
),
january
:
String
(
Number
(
i
[
8
])
.
toFixed
(
1
)
),
february
:
String
(
Number
(
i
[
9
])
.
toFixed
(
1
)
),
march
:
String
(
Number
(
i
[
10
])
.
toFixed
(
1
)
),
april
:
String
(
Number
(
i
[
11
])
.
toFixed
(
1
)
),
may
:
String
(
Number
(
i
[
12
])
.
toFixed
(
1
)
),
june
:
String
(
Number
(
i
[
13
])
.
toFixed
(
1
)
),
july
:
String
(
Number
(
i
[
14
])
.
toFixed
(
1
)
),
august
:
String
(
Number
(
i
[
15
])
.
toFixed
(
1
)
),
september
:
String
(
Number
(
i
[
16
])
.
toFixed
(
1
)
),
october
:
String
(
Number
(
i
[
17
])
.
toFixed
(
1
)
),
november
:
String
(
Number
(
i
[
18
])
.
toFixed
(
1
)
),
december
:
String
(
Number
(
i
[
19
])
.
toFixed
(
1
)
),
total_current_year
:
String
(
Number
(
i
[
20
])
.
toFixed
(
1
)
),
ytd_october
:
String
(
Number
(
i
[
21
])
.
toFixed
(
1
)
),
nov_dec
:
String
(
Number
(
i
[
22
])
.
toFixed
(
1
)
),
total_actual_before
:
String
(
Number
(
i
[
7
])),
january
:
String
(
Number
(
i
[
8
])),
february
:
String
(
Number
(
i
[
9
])),
march
:
String
(
Number
(
i
[
10
])),
april
:
String
(
Number
(
i
[
11
])),
may
:
String
(
Number
(
i
[
12
])),
june
:
String
(
Number
(
i
[
13
])),
july
:
String
(
Number
(
i
[
14
])),
august
:
String
(
Number
(
i
[
15
])),
september
:
String
(
Number
(
i
[
16
])),
october
:
String
(
Number
(
i
[
17
])),
november
:
String
(
Number
(
i
[
18
])),
december
:
String
(
Number
(
i
[
19
])),
total_current_year
:
String
(
Number
(
i
[
20
])),
ytd_october
:
String
(
Number
(
i
[
21
])),
nov_dec
:
String
(
Number
(
i
[
22
])),
})
})
let
payload
=
{
...
...
@@ -499,14 +500,95 @@ export default class ProfitLossOLPA extends Component {
})
}
u
ploadSimulasi
()
{
checkU
ploadSimulasi
()
{
let
payload
=
{
...
this
.
state
.
payload
,
currency_id
:
this
.
state
.
defaultCurrencyUpload
?.
id
}
this
.
setState
({
loading
:
true
,
dataTable
:
[]
})
console
.
log
(
payload
)
api
.
create
().
uploadSimulasiOLPA
(
payload
).
then
(
response
=>
{
api
.
create
().
checkUploadOLPA
(
payload
).
then
(
response
=>
{
// console.log(JSON.stringify(this.state.payload));
console
.
log
(
response
)
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
'success'
)
{
this
.
setState
({
visibleUploadSimulasi
:
false
,
visibleProfitLoss
:
false
,
loading
:
true
,
visibleButtonUpload
:
true
})
let
dataTable
=
response
.
data
.
data
.
map
((
item
,
index
)
=>
{
return
[
item
.
type_report_id
,
item
.
item_report_id
,
item
.
parent
,
item
.
formula
,
item
.
level
,
item
.
item_report
,
item
.
notes
,
item
.
total_actual_before
,
item
.
january
,
item
.
february
,
item
.
march
,
item
.
april
,
item
.
may
,
item
.
june
,
item
.
july
,
item
.
august
,
item
.
september
,
item
.
october
,
item
.
november
,
item
.
december
,
item
.
total_current_year
,
item
.
ytd_october
,
item
.
nov_dec
,
item
.
orders
,
item
.
error
]
})
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
,
editable
:
true
},
()
=>
{
this
.
state
.
dataTable
.
map
(
item
=>
{
if
(
item
[
24
].
length
>
0
)
{
console
.
log
(
'masuk'
)
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
,
editable
:
true
})
}
})
// console.log(this.state.buttonError)
})
}
}
})
}
uploadSimulasi
(
type
)
{
let
data
=
[]
this
.
state
.
dataTable
.
map
(
i
=>
{
data
.
push
({
item_report_id
:
i
[
1
],
notes
:
String
(
i
[
6
]),
total_actual_before
:
String
(
Number
(
i
[
7
])),
january
:
String
(
Number
(
i
[
8
])),
february
:
String
(
Number
(
i
[
9
])),
march
:
String
(
Number
(
i
[
10
])),
april
:
String
(
Number
(
i
[
11
])),
may
:
String
(
Number
(
i
[
12
])),
june
:
String
(
Number
(
i
[
13
])),
july
:
String
(
Number
(
i
[
14
])),
august
:
String
(
Number
(
i
[
15
])),
september
:
String
(
Number
(
i
[
16
])),
october
:
String
(
Number
(
i
[
17
])),
november
:
String
(
Number
(
i
[
18
])),
december
:
String
(
Number
(
i
[
19
])),
total_current_year
:
String
(
Number
(
i
[
20
])),
ytd_october
:
String
(
Number
(
i
[
21
])),
nov_dec
:
String
(
Number
(
i
[
22
]))
})
})
let
body
=
{
outlook_pa_id
:
this
.
props
.
outlook_pa_id
,
company_id
:
this
.
props
.
company
.
company_id
,
periode
:
this
.
props
.
periode
,
report_id
:
this
.
props
.
report_id
,
currency_id
:
this
.
state
.
defaultCurrencyUpload
?.
id
,
profit_loss
:
data
,
status
:
type
}
console
.
log
(
JSON
.
stringify
(
body
));
api
.
create
().
uploadSimulasiOLPA
(
body
).
then
(
response
=>
{
console
.
log
(
response
)
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
...
...
@@ -1868,7 +1950,6 @@ export default class ProfitLossOLPA extends Component {
<
/div
>
<
div
style
=
{{
width
:
'50%'
}}
>
<
div
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
}}
>
<
ReactTooltip
border
=
{
true
}
id
=
"template"
place
=
"bottom"
type
=
"light"
effect
=
"solid"
/>
<
a
data
-
tip
=
{
'Upload Simulasi'
}
data
-
for
=
"upload"
>
<
button
style
=
{{
...
...
@@ -2105,6 +2186,101 @@ export default class ProfitLossOLPA extends Component {
<
/div
>
<
/Paper
>
:
this
.
state
.
visibleButtonUpload
===
true
?
<
Paper
style
=
{{
paddingTop
:
10
,
paddingBottom
:
20
}}
>
<
div
>
<
div
style
=
{{
padding
:
25
}}
>
<
div
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#4b4b4b'
}}
>
{
this
.
props
.
company
.
company_name
}
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#4b4b4b'
}}
>
Period
:
{
this
.
props
.
periode
}
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#4b4b4b'
}}
>
in
IDR
mn
<
/Typography
>
<
/div
>
{
this
.
state
.
dataLoaded
&&
(
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
}}
>
{
this
.
state
.
loading
&&
loadingComponent
}
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
<
MUIDataTable
data
=
{
dataTable2
}
columns
=
{
columns
}
options
=
{
options
}
/
>
<
/MuiThemeProvider
>
<
/div
>
)}
<
/div
>
<
div
className
=
"grid grid-2x"
style
=
{{
marginTop
:
20
}}
>
<
div
className
=
"col-1"
>
<
button
type
=
"button"
onClick
=
{()
=>
this
.
setState
({
loading
:
true
,
dataTable
:
[]
},
()
=>
{
setTimeout
(()
=>
{
this
.
getItemHierarki
()
},
100
);
})}
style
=
{{
marginRight
:
20
}}
>
<
div
style
=
{{
backgroundColor
:
'#019ce5'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Cancel
<
/Typography
>
<
/div
>
<
/button
>
<
/div
>
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
button
className
=
"button"
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
'pointer'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
marginRight
:
20
}}
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
,
dataTable
:
dataTable2
,
buttonDraft
:
false
},
()
=>
{
setTimeout
(()
=>
{
this
.
handleValidate
()
// this.setState({ loading: false, buttonError: this.state.errorPreview === true ? true : false, editable: false })
},
100
);
})
}}
>
<
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
type
=
"button"
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data is not complete !'
,
tipeAlert
:
'error'
})
:
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleDoubleClick
==
1
?
null
:
this
.
setState
({
handleDoubleClick
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadSimulasi
(
'submitted'
)
},
100
);
})
)
}
>
<
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
Data
<
/Typography
>
<
/div
>
<
/button
>
<
/div
>
<
/div
>
<
/div
>
<
/Paper
>
:
<
Paper
style
=
{{
paddingTop
:
10
,
paddingBottom
:
20
}}
>
<
div
>
<
div
style
=
{{
padding
:
25
}}
>
...
...
@@ -2299,7 +2475,7 @@ export default class ProfitLossOLPA extends Component {
}}
onUpload
=
{()
=>
{
String
(
this
.
state
.
judul
).
includes
(
"OUTLOOK"
)
&&
String
(
this
.
state
.
judul
).
includes
(
"PA"
)
&&
String
(
this
.
state
.
judul
).
includes
(
"PROFIT"
)
&&
String
(
this
.
state
.
judul
).
includes
(
"LOSS"
)
?
this
.
u
ploadSimulasi
()
:
this
.
checkU
ploadSimulasi
()
:
this
.
setState
({
alert
:
true
,
messageAlert
:
"Invalid Template"
,
tipeAlert
:
'warning'
})
}}
/
>
...
...
src/container/OutlookPA/TaxPlanningOLPA.js
View file @
2c2b0d05
...
...
@@ -54,7 +54,8 @@ export default class TaxPlanningOLPA extends Component {
get_for
:
"view"
,
viewOnly
:
true
,
defaultCurrencyUpload
:
this
.
props
.
defaultCurrency
,
visibleAlertSave
:
false
visibleAlertSave
:
false
,
visibleButtonUpload
:
false
}
this
.
handleValue
=
this
.
handleValue
.
bind
(
this
)
...
...
@@ -212,8 +213,8 @@ export default class TaxPlanningOLPA extends Component {
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbc
)
.
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbc
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
fcp
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
fcp
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbf
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbf
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbc
)
.
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbc
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
fcp
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
fcp
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbf
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbf
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbc
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbc
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
fcp
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
fcp
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbf
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbf
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbc
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbc
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
fcp
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
fcp
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbf
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbf
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbf
},
// {
// tbc: item.tax_planning.january !== null ? item.tax_planning.january !== "" ? item.tax_planning.january.tbc !== null ? item.tax_planning.january.tbc !== "" ? item.tax_planning.january.tbc : "0" : "0" : "0" : "0",
// fcp: item.tax_planning.january !== null ? item.tax_planning.january !== "" ? item.tax_planning.january.fcp !== null ? item.tax_planning.january.fcp !== "" ? item.tax_planning.january.fcp : "0" : "0" : "0" : "0",
...
...
@@ -317,8 +318,8 @@ export default class TaxPlanningOLPA extends Component {
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbc
)
.
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbc
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
fcp
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
fcp
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbf
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbf
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbc
)
.
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbc
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
fcp
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
fcp
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbf
).
toFixed
(
1
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbf
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbc
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbc
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
fcp
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
fcp
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
november
.
tbf
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
november
.
tbf
,
formula
:
item
.
tax_planning
.
november_formula
}
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbc
)
:
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbc
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbc
,
fcp
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
fcp
)
:
item
.
type_report_tax
.
value_fc
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_fc
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
fcp
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
fcp
,
tbf
:
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
tax_planning
.
december
.
tbf
)
:
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
5
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
6
||
item
.
type_report_tax
.
value_tbf
.
type_report_id
==
7
?
{
value
:
item
.
tax_planning
.
december
.
tbf
,
formula
:
item
.
tax_planning
.
december_formula
}
:
item
.
tax_planning
.
december
.
tbf
},
// {
// tbc: item.tax_planning.january !== null ? item.tax_planning.january !== "" ? item.tax_planning.january.tbc !== null ? item.tax_planning.january.tbc !== "" ? item.tax_planning.january.tbc : "0" : "0" : "0" : "0",
// fcp: item.tax_planning.january !== null ? item.tax_planning.january !== "" ? item.tax_planning.january.fcp !== null ? item.tax_planning.january.fcp !== "" ? item.tax_planning.january.fcp : "0" : "0" : "0" : "0",
...
...
@@ -452,52 +453,52 @@ export default class TaxPlanningOLPA extends Component {
january
:
{
// tbc: String(Number(i[9].tbc).toFixed(1)),
// fcp: String(Number(i[9].fcp).toFixed(1)),
tbf
:
String
(
Number
(
i
[
9
].
tbf
)
.
toFixed
(
1
)
)
tbf
:
String
(
Number
(
i
[
9
].
tbf
))
},
february
:
{
// tbc: String(Number(i[10].tbc)
.toFixed(1)
),
// fcp: String(Number(i[10].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
10
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[10].tbc)),
// fcp: String(Number(i[10].fcp)),
tbf
:
String
(
Number
(
i
[
10
].
tbf
))
},
march
:
{
// tbc: String(Number(i[11].tbc)
.toFixed(1)
),
// fcp: String(Number(i[11].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
11
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[11].tbc)),
// fcp: String(Number(i[11].fcp)),
tbf
:
String
(
Number
(
i
[
11
].
tbf
))
},
april
:
{
// tbc: String(Number(i[12].tbc)
.toFixed(1)
),
// fcp: String(Number(i[12].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
12
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[12].tbc)),
// fcp: String(Number(i[12].fcp)),
tbf
:
String
(
Number
(
i
[
12
].
tbf
))
},
may
:
{
// tbc: String(Number(i[13].tbc)
.toFixed(1)
),
// fcp: String(Number(i[13].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
13
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[13].tbc)),
// fcp: String(Number(i[13].fcp)),
tbf
:
String
(
Number
(
i
[
13
].
tbf
))
},
june
:
{
// tbc: String(Number(i[14].tbc)
.toFixed(1)
),
// fcp: String(Number(i[14].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
14
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[14].tbc)),
// fcp: String(Number(i[14].fcp)),
tbf
:
String
(
Number
(
i
[
14
].
tbf
))
},
july
:
{
// tbc: String(Number(i[15].tbc)
.toFixed(1)
),
// fcp: String(Number(i[15].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
15
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[15].tbc)),
// fcp: String(Number(i[15].fcp)),
tbf
:
String
(
Number
(
i
[
15
].
tbf
))
},
august
:
{
// tbc: String(Number(i[16].tbc)
.toFixed(1)
),
// fcp: String(Number(i[16].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
16
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[16].tbc)),
// fcp: String(Number(i[16].fcp)),
tbf
:
String
(
Number
(
i
[
16
].
tbf
))
},
september
:
{
// tbc: String(Number(i[17].tbc)
.toFixed(1)
),
// fcp: String(Number(i[17].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
17
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[17].tbc)),
// fcp: String(Number(i[17].fcp)),
tbf
:
String
(
Number
(
i
[
17
].
tbf
))
},
october
:
{
// tbc: String(Number(i[18].tbc)
.toFixed(1)
),
// fcp: String(Number(i[18].fcp)
.toFixed(1)
),
tbf
:
String
(
Number
(
i
[
18
].
tbf
)
.
toFixed
(
1
)
)
// tbc: String(Number(i[18].tbc)),
// fcp: String(Number(i[18].fcp)),
tbf
:
String
(
Number
(
i
[
18
].
tbf
))
},
november
:
{
tbc
:
i
[
1
]
===
3
&&
i
[
19
].
tbc
===
""
?
"0"
:
i
[
1
]
===
5
||
i
[
1
]
===
6
||
i
[
1
]
===
7
?
String
(
i
[
19
].
tbc
.
value
)
:
String
(
i
[
19
].
tbc
),
...
...
@@ -509,7 +510,7 @@ export default class TaxPlanningOLPA extends Component {
fcp
:
i
[
2
]
===
3
&&
i
[
20
].
fcp
===
""
?
"0"
:
i
[
2
]
===
5
||
i
[
2
]
===
6
||
i
[
2
]
===
7
?
String
(
i
[
20
].
fcp
.
value
)
:
String
(
i
[
20
].
fcp
),
tbf
:
i
[
3
]
===
3
&&
i
[
20
].
tbf
===
""
?
"0"
:
String
(
i
[
8
]).
toLocaleUpperCase
()
==
"CORPORATE INCOME TAX"
?
String
(
i
[
20
].
tbf
)
:
i
[
3
]
===
5
||
i
[
3
]
===
6
||
i
[
3
]
===
7
?
String
(
i
[
20
].
tbf
.
value
)
:
String
(
i
[
20
].
tbf
)
},
total_current_year
:
String
(
Number
(
i
[
21
])
.
toFixed
(
1
)
),
total_current_year
:
String
(
Number
(
i
[
21
])),
})
})
let
payload
=
{
...
...
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