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
4ac8e578
Commit
4ac8e578
authored
Dec 01, 2020
by
Faisal Hamdi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'faisal' into 'master'
update master bajet fam See merge request
!724
parents
9fdfcdef
5628b4d8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
149 additions
and
55 deletions
+149
-55
FixedAssetsMovement.js
src/container/BudgetTahunan/FixedAssetsMovement.js
+149
-55
No files found.
src/container/BudgetTahunan/FixedAssetsMovement.js
View file @
4ac8e578
...
...
@@ -105,21 +105,21 @@ export default class FixedAssetsMovement extends Component {
item
.
level
,
item
.
description
,
item
.
fixed_asset_movement
.
total_actual_before
===
null
?
"0"
:
item
.
fixed_asset_movement
.
total_actual_before
===
""
?
"0"
:
item
.
fixed_asset_movement
.
total_actual_before
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
january
,
formula
:
item
.
fixed_asset_movement
.
january_formula
}
:
item
.
fixed_asset_movement
.
january
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
february
,
formula
:
item
.
fixed_asset_movement
.
february_formula
}
:
item
.
fixed_asset_movement
.
february
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
march
,
formula
:
item
.
fixed_asset_movement
.
march_formula
}
:
item
.
fixed_asset_movement
.
march
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
april
,
formula
:
item
.
fixed_asset_movement
.
april_formula
}
:
item
.
fixed_asset_movement
.
april
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
may
,
formula
:
item
.
fixed_asset_movement
.
may_formula
}
:
item
.
fixed_asset_movement
.
may
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
june
,
formula
:
item
.
fixed_asset_movement
.
june_formula
}
:
item
.
fixed_asset_movement
.
june
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
july
,
formula
:
item
.
fixed_asset_movement
.
july_formula
}
:
item
.
fixed_asset_movement
.
july
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
august
,
formula
:
item
.
fixed_asset_movement
.
august_formula
}
:
item
.
fixed_asset_movement
.
august
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
september
,
formula
:
item
.
fixed_asset_movement
.
september_formula
}
:
item
.
fixed_asset_movement
.
september
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
october
,
formula
:
item
.
fixed_asset_movement
.
october_formula
}
:
item
.
fixed_asset_movement
.
october
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
november
,
formula
:
item
.
fixed_asset_movement
.
november_formula
}
:
item
.
fixed_asset_movement
.
november
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
december
,
formula
:
item
.
fixed_asset_movement
.
december_formula
}
:
item
.
fixed_asset_movement
.
december
,
item
.
fixed_asset_movement
.
total_current_year
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
0
:
item
.
fixed_asset_movement
.
total_next_year
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
0
:
item
.
fixed_asset_movement
.
total_more_year
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
january
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
january
,
formula
:
item
.
fixed_asset_movement
.
january_formula
}
:
Number
(
item
.
fixed_asset_movement
.
january
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
february
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
february
,
formula
:
item
.
fixed_asset_movement
.
february_formula
}
:
Number
(
item
.
fixed_asset_movement
.
february
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
march
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
march
,
formula
:
item
.
fixed_asset_movement
.
march_formula
}
:
Number
(
item
.
fixed_asset_movement
.
march
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
april
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
april
,
formula
:
item
.
fixed_asset_movement
.
april_formula
}
:
Number
(
item
.
fixed_asset_movement
.
april
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
may
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
may
,
formula
:
item
.
fixed_asset_movement
.
may_formula
}
:
Number
(
item
.
fixed_asset_movement
.
may
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
june
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
june
,
formula
:
item
.
fixed_asset_movement
.
june_formula
}
:
Number
(
item
.
fixed_asset_movement
.
june
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
july
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
july
,
formula
:
item
.
fixed_asset_movement
.
july_formula
}
:
Number
(
item
.
fixed_asset_movement
.
july
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
august
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
august
,
formula
:
item
.
fixed_asset_movement
.
august_formula
}
:
Number
(
item
.
fixed_asset_movement
.
august
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
september
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
september
,
formula
:
item
.
fixed_asset_movement
.
september_formula
}
:
Number
(
item
.
fixed_asset_movement
.
september
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
october
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
october
,
formula
:
item
.
fixed_asset_movement
.
october_formula
}
:
Number
(
item
.
fixed_asset_movement
.
october
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
november
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
november
,
formula
:
item
.
fixed_asset_movement
.
november_formula
}
:
Number
(
item
.
fixed_asset_movement
.
november
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
december
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
december
,
formula
:
item
.
fixed_asset_movement
.
december_formula
}
:
Number
(
item
.
fixed_asset_movement
.
december
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_current_year
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_next_year
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_more_year
).
toFixed
(
1
)
,
item
.
order
,
item
.
fixed_asset_movement
.
forecast_formula
,
item
.
fixed_asset_movement
.
before_formula
...
...
@@ -142,21 +142,21 @@ export default class FixedAssetsMovement extends Component {
item
.
level
,
item
.
description
,
item
.
fixed_asset_movement
.
total_actual_before
===
null
?
"0"
:
item
.
fixed_asset_movement
.
total_actual_before
===
""
?
"0"
:
item
.
fixed_asset_movement
.
total_actual_before
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
january
,
formula
:
item
.
fixed_asset_movement
.
january_formula
}
:
item
.
fixed_asset_movement
.
january
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
february
,
formula
:
item
.
fixed_asset_movement
.
february_formula
}
:
item
.
fixed_asset_movement
.
february
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
march
,
formula
:
item
.
fixed_asset_movement
.
march_formula
}
:
item
.
fixed_asset_movement
.
march
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
april
,
formula
:
item
.
fixed_asset_movement
.
april_formula
}
:
item
.
fixed_asset_movement
.
april
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
may
,
formula
:
item
.
fixed_asset_movement
.
may_formula
}
:
item
.
fixed_asset_movement
.
may
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
june
,
formula
:
item
.
fixed_asset_movement
.
june_formula
}
:
item
.
fixed_asset_movement
.
june
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
july
,
formula
:
item
.
fixed_asset_movement
.
july_formula
}
:
item
.
fixed_asset_movement
.
july
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
august
,
formula
:
item
.
fixed_asset_movement
.
august_formula
}
:
item
.
fixed_asset_movement
.
august
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
september
,
formula
:
item
.
fixed_asset_movement
.
september_formula
}
:
item
.
fixed_asset_movement
.
september
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
october
,
formula
:
item
.
fixed_asset_movement
.
october_formula
}
:
item
.
fixed_asset_movement
.
october
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
november
,
formula
:
item
.
fixed_asset_movement
.
november_formula
}
:
item
.
fixed_asset_movement
.
november
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
december
,
formula
:
item
.
fixed_asset_movement
.
december_formula
}
:
item
.
fixed_asset_movement
.
december
,
item
.
fixed_asset_movement
.
total_current_year
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
0
:
item
.
fixed_asset_movement
.
total_next_year
,
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
0
:
item
.
fixed_asset_movement
.
total_more_year
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
january
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
january
,
formula
:
item
.
fixed_asset_movement
.
january_formula
}
:
Number
(
item
.
fixed_asset_movement
.
january
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
february
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
february
,
formula
:
item
.
fixed_asset_movement
.
february_formula
}
:
Number
(
item
.
fixed_asset_movement
.
february
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
march
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
march
,
formula
:
item
.
fixed_asset_movement
.
march_formula
}
:
Number
(
item
.
fixed_asset_movement
.
march
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
april
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
april
,
formula
:
item
.
fixed_asset_movement
.
april_formula
}
:
Number
(
item
.
fixed_asset_movement
.
april
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
may
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
may
,
formula
:
item
.
fixed_asset_movement
.
may_formula
}
:
Number
(
item
.
fixed_asset_movement
.
may
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
june
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
june
,
formula
:
item
.
fixed_asset_movement
.
june_formula
}
:
Number
(
item
.
fixed_asset_movement
.
june
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
july
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
july
,
formula
:
item
.
fixed_asset_movement
.
july_formula
}
:
Number
(
item
.
fixed_asset_movement
.
july
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
august
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
august
,
formula
:
item
.
fixed_asset_movement
.
august_formula
}
:
Number
(
item
.
fixed_asset_movement
.
august
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
september
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
september
,
formula
:
item
.
fixed_asset_movement
.
september_formula
}
:
Number
(
item
.
fixed_asset_movement
.
september
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
october
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
october
,
formula
:
item
.
fixed_asset_movement
.
october_formula
}
:
Number
(
item
.
fixed_asset_movement
.
october
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
november
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
november
,
formula
:
item
.
fixed_asset_movement
.
november_formula
}
:
Number
(
item
.
fixed_asset_movement
.
november
).
toFixed
(
1
)
,
this
.
props
.
status
===
'CLOSED'
?
Number
(
item
.
fixed_asset_movement
.
december
).
toFixed
(
1
)
:
item
.
type_report_id
==
5
||
item
.
type_report_id
==
6
?
{
value
:
item
.
fixed_asset_movement
.
december
,
formula
:
item
.
fixed_asset_movement
.
december_formula
}
:
Number
(
item
.
fixed_asset_movement
.
december
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_current_year
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_next_year
).
toFixed
(
1
)
,
Number
(
item
.
fixed_asset_movement
.
total_more_year
).
toFixed
(
1
)
,
item
.
order
,
item
.
fixed_asset_movement
.
forecast_formula
,
item
.
fixed_asset_movement
.
before_formula
...
...
@@ -183,6 +183,8 @@ export default class FixedAssetsMovement extends Component {
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'error'
,
loading
:
false
})
}
console
.
log
(
dataTable
);
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
problem
,
tipeAlert
:
'error'
,
loading
:
false
})
}
...
...
@@ -683,9 +685,10 @@ export default class FixedAssetsMovement extends Component {
}
const
handleTotal
=
(
tableMeta
)
=>
{
let
total
=
0
// if (tableMeta.rowData[5] == 'Beginning balance') {
// // console.log(tableMeta.rowData)
// }
// console.log(tableMeta)
if
(
tableMeta
.
rowData
[
5
]
==
'Beginning balance'
)
{
console
.
log
(
tableMeta
.
rowData
)
}
if
(
String
(
tableMeta
.
rowData
[
5
]).
toLocaleLowerCase
()
==
'ending balance'
)
{
total
=
dataTable2
[
tableMeta
.
rowIndex
][
18
].
value
dataTable2
[
tableMeta
.
rowIndex
][
19
]
=
total
...
...
@@ -2242,28 +2245,119 @@ export default class FixedAssetsMovement extends Component {
customBodyRender
:
(
value
,
tableMeta
,
updateValue
)
=>
{
return
(
<
div
style
=
{{
width
:
96
,
textAlign
:
'right'
}}
>
{
tableMeta
.
rowData
[
0
]
===
1
||
tableMeta
.
rowData
[
0
]
===
4
?
null
:
tableMeta
.
rowData
[
0
]
===
2
?
<
span
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
}}
>
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleValue
(
tableMeta
)).
toFixed
(
1
)}
/
>
<
/span>
:
<
span
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
}}
>
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleTotal
(
tableMeta
)).
toFixed
(
1
)}
/
>
<
/span>
}
{
this
.
props
.
status
===
'CLOSED'
?
tableMeta
.
rowData
[
0
]
===
1
||
tableMeta
.
rowData
[
0
]
===
4
?
null
:
tableMeta
.
rowData
[
0
]
===
3
?
<
div
style
=
{{
flex
:
1
}}
>
<
FormControlLabel
style
=
{{
margin
:
0
}}
value
=
{
value
}
control
=
{
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
color
:
"#5198ea"
,
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
/
>
}
/
>
<
/div>
:
<
div
style
=
{{
flex
:
1
}}
>
<
FormControlLabel
style
=
{{
margin
:
0
}}
value
=
{
value
}
control
=
{
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
value
).
toFixed
(
1
)}
/
>
}
/
>
<
/div
>
:
tableMeta
.
rowData
[
0
]
===
3
?
<
div
style
=
{{
flex
:
1
}}
>
<
FormControlLabel
style
=
{{
margin
:
0
}}
value
=
{
value
}
control
=
{
<
NumberFormat
thousandSeparator
=
{
true
}
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
&&
(
this
.
props
.
status
===
'revision'
||
this
.
props
.
status
===
'not-yet'
||
this
.
props
.
status
===
'draft'
||
this
.
props
.
status
===
'submitted'
)
?
false
:
true
)}
value
=
{
Number
(
value
).
toFixed
(
1
)}
onBlur
=
{(
event
)
=>
{
// updateValue(event.target.value)
handleChange
(
event
.
target
.
value
,
tableMeta
)
// // console.log(dataTable2)
}}
/
>
}
/
>
<
/div>
:
tableMeta
.
rowData
[
0
]
===
5
?
<
span
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
}}
>
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleTotal
(
tableMeta
)).
toFixed
(
1
)}
/
>
<
/span
>
:
tableMeta
.
rowData
[
0
]
===
4
?
null
:
tableMeta
.
rowData
[
0
]
===
6
?
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleTotal
(
tableMeta
)).
toFixed
(
1
)}
/
>
:
tableMeta
.
rowData
[
0
]
===
1
?
null
:
null
// tableMeta.rowData[0] === 2 ?
// <span style={{ fontSize: 12, textAlign: 'right' }}>
// <NumberFormat
// thousandSeparator={true}
// style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
// type="text"
// placeholder=""
// disabled={true}
// value={Number(handleValue(tableMeta)).toFixed(1)}
// />
// </span>
// :
// <span style={{ fontSize: 12, textAlign: 'right' }}>
// <NumberFormat
// thousandSeparator={true}
// style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
// type="text"
// placeholder=""
// disabled={true}
// value={Number(handleTotal(tableMeta)).toFixed(1)}
// />
// </span>
}
<
/div
>
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment