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
072531b7
Commit
072531b7
authored
Apr 05, 2021
by
Riri Novita
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'riri' into 'master'
Riri See merge request
!1386
parents
d74bcebf
cca7fefd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
34 additions
and
71 deletions
+34
-71
ProfitLossRO.js
src/container/RollingOutlook/ProfitLossRO.js
+34
-71
No files found.
src/container/RollingOutlook/ProfitLossRO.js
View file @
072531b7
...
@@ -777,11 +777,27 @@ export default class ProfitLossROO extends Component {
...
@@ -777,11 +777,27 @@ export default class ProfitLossROO extends Component {
total
+=
Number
(
item
)
total
+=
Number
(
item
)
}
}
})
})
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
total
if
(
String
(
tableMeta
.
rowData
[
5
]).
toLocaleLowerCase
()
==
"sales price"
)
{
let
value
=
Number
(
dataTable2
[
tableMeta
.
rowIndex
-
2
][
20
])
/
Number
(
dataTable2
[
tableMeta
.
rowIndex
-
1
][
20
])
dataTable2
[
tableMeta
.
rowIndex
][
20
]
=
R
.
equals
(
value
,
NaN
)
?
"0.0"
:
(
R
.
equals
(
value
,
Infinity
)
?
"0.0"
:
(
value
==
"-Infinity"
?
"0.0"
:
value
))
return
R
.
equals
(
value
,
NaN
)
?
"0.0"
:
(
R
.
equals
(
value
,
Infinity
)
?
"0.0"
:
(
value
==
"-Infinity"
?
"0.0"
:
value
))
}
// else if (String(tableMeta.rowData[5]).toLocaleLowerCase() == "total man power") {
// let totalTMP = dataTable2[tableMeta.rowIndex][20] = dataTable2[tableMeta.rowIndex][19]
// return totalTMP
// } else if (indexParent !== -1 && String(dataTable2[indexParent][5]).toLocaleUpperCase() == "GROSS PROFIT MARGIN (% OF REVENUE)") {
// return handleFormula(0, tableMeta, 0)
// }
else
{
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
total
return
total
}
// dataTable2[tableMeta.rowIndex][tableMeta.columnIndex] = total
// if (String(tableMeta.rowData[5]).toLocaleLowerCase === "sales volume") {
// if (String(tableMeta.rowData[5]).toLocaleLowerCase === "sales volume") {
// console.log(total);
// console.log(total);
// }
// }
return
total
//
return total
}
}
let
columns
=
[
let
columns
=
[
...
@@ -2211,75 +2227,22 @@ export default class ProfitLossROO extends Component {
...
@@ -2211,75 +2227,22 @@ export default class ProfitLossROO extends Component {
value
=
{
Number
(
val
).
toFixed
(
1
)}
value
=
{
Number
(
val
).
toFixed
(
1
)}
/
>
/
>
:
:
// tableMeta.rowData[0] === 2 ?
<
div
style
=
{{
flex
:
1
}}
>
// <span style={{ fontSize: 12, textAlign: 'right' }}>
<
FormControlLabel
// <NumberFormat
style
=
{{
margin
:
0
}}
// thousandSeparator={true}
value
=
{
val
}
// style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
control
=
{
// type="text"
<
NumberFormat
// placeholder=""
thousandSeparator
=
{
true
}
// disabled={true}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
// // value={Number(val).toFixed(1)}
type
=
"text"
// value={Number(handleValue(val, tableMeta)).toFixed(1)}
placeholder
=
""
// />
disabled
=
{
true
}
// </span>
value
=
{
Number
(
handleTotal
(
val
,
tableMeta
)).
toFixed
(
1
)}
// :
/
>
// tableMeta.rowData[0] === 3 ?
}
// <div style={{ flex: 1 }}>
/
>
// <FormControlLabel
<
/div
>
// style={{ margin: 0 }}
// value={val}
// control={
// <NumberFormat
// thousandSeparator={true}
// style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
// type="text"
// placeholder=""
// // disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
// disabled={true}
// value={Number(handleTotal(val, tableMeta)).toFixed(1)}
// onBlur={(event) => {
// handleChange(event.target.value, tableMeta)
// }}
// />
// }
// />
// </div>
// :
// tableMeta.rowData[0] === 5 || tableMeta.rowData[0] === 6 ?
// <div style={{ flex: 1 }}>
// <FormControlLabel
// style={{ margin: 0 }}
// value={val}
// control={
// <NumberFormat
// thousandSeparator={true}
// style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
// type="text"
// placeholder=""
// disabled={true}
// value={Number(handleFormula(val, tableMeta, 1)).toFixed(1)}
// />
// }
// />
// </div>
// :
<
div
style
=
{{
flex
:
1
}}
>
<
FormControlLabel
style
=
{{
margin
:
0
}}
value
=
{
val
}
control
=
{
<
NumberFormat
thousandSeparator
=
{
true
}
style
=
{{
fontSize
:
12
,
textAlign
:
'right'
,
borderColor
:
'transparent'
,
margin
:
0
,
width
:
96
,
backgroundColor
:
'transparent'
}}
type
=
"text"
placeholder
=
""
disabled
=
{
true
}
value
=
{
Number
(
handleTotal
(
val
,
tableMeta
)).
toFixed
(
1
)}
/
>
}
/
>
<
/div
>
}
}
<
/div
>
<
/div
>
)
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment