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
6bceff12
Commit
6bceff12
authored
Sep 09, 2020
by
Dida Adams Arizona
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'riri' into 'master'
update list See merge request
!270
parents
ca0cef43
5db044ca
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
90 additions
and
77 deletions
+90
-77
ProfitLoss.js
src/container/BudgetTahunan/ProfitLoss.js
+43
-66
ReportItems.js
src/container/MasterData/ReportItems.js
+47
-11
No files found.
src/container/BudgetTahunan/ProfitLoss.js
View file @
6bceff12
...
...
@@ -7,14 +7,14 @@ import AddIcon from '@material-ui/icons/Add';
import
{
values
}
from
'ramda'
;
var
ct
=
require
(
"../../library/CustomTable"
);
const
getMuiTheme
=
()
=>
createMuiTheme
(
ct
.
customTable
());
const
getMuiTheme
=
()
=>
createMuiTheme
(
ct
.
customTable
3
());
const
options
=
ct
.
customOptionsFixedColumn
();
const
style
=
{
position
:
"sticky"
,
left
:
0
,
background
:
"white"
,
zIndex
:
101
,
background
:
"white"
,
};
const
style2
=
{
position
:
"sticky"
,
...
...
@@ -68,7 +68,6 @@ export default class ProfitLoss extends Component {
item
.
formula
,
item
.
level
,
item
.
description
,
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
total_actual_before
,
item
.
profit_loss
.
january
,
item
.
profit_loss
.
february
,
...
...
@@ -96,7 +95,6 @@ export default class ProfitLoss extends Component {
i
.
formula
,
i
.
level
,
i
.
description
,
i
.
profit_loss
.
notes
,
i
.
profit_loss
.
total_actual_before
,
i
.
profit_loss
.
january
,
i
.
profit_loss
.
february
,
...
...
@@ -123,7 +121,6 @@ export default class ProfitLoss extends Component {
val
.
formula
,
val
.
level
,
val
.
description
,
val
.
profit_loss
.
notes
,
val
.
profit_loss
.
total_actual_before
,
val
.
profit_loss
.
january
,
val
.
profit_loss
.
february
,
...
...
@@ -150,7 +147,6 @@ export default class ProfitLoss extends Component {
items
.
formula
,
items
.
level
,
items
.
description
,
items
.
profit_loss
.
notes
,
items
.
profit_loss
.
total_actual_before
,
items
.
profit_loss
.
january
,
items
.
profit_loss
.
february
,
...
...
@@ -177,7 +173,6 @@ export default class ProfitLoss extends Component {
itemss
.
formula
,
itemss
.
level
,
itemss
.
description
,
itemss
.
profit_loss
.
notes
,
itemss
.
profit_loss
.
total_actual_before
,
itemss
.
profit_loss
.
january
,
itemss
.
profit_loss
.
february
,
...
...
@@ -204,7 +199,6 @@ export default class ProfitLoss extends Component {
item1
.
formula
,
item1
.
level
,
item1
.
description
,
item1
.
profit_loss
.
notes
,
item1
.
profit_loss
.
total_actual_before
,
item1
.
profit_loss
.
january
,
item1
.
profit_loss
.
february
,
...
...
@@ -231,7 +225,6 @@ export default class ProfitLoss extends Component {
item2
.
formula
,
item2
.
level
,
item2
.
description
,
item2
.
profit_loss
.
notes
,
item2
.
profit_loss
.
total_actual_before
,
item2
.
profit_loss
.
january
,
item2
.
profit_loss
.
february
,
...
...
@@ -258,7 +251,6 @@ export default class ProfitLoss extends Component {
item3
.
formula
,
item3
.
level
,
item3
.
description
,
item3
.
profit_loss
.
notes
,
item3
.
profit_loss
.
total_actual_before
,
item3
.
profit_loss
.
january
,
item3
.
profit_loss
.
february
,
...
...
@@ -285,7 +277,6 @@ export default class ProfitLoss extends Component {
item4
.
formula
,
item4
.
level
,
item4
.
description
,
item4
.
profit_loss
.
notes
,
item4
.
profit_loss
.
total_actual_before
,
item4
.
profit_loss
.
january
,
item4
.
profit_loss
.
february
,
...
...
@@ -312,7 +303,6 @@ export default class ProfitLoss extends Component {
item5
.
formula
,
item5
.
level
,
item5
.
description
,
item5
.
profit_loss
.
notes
,
item5
.
profit_loss
.
total_actual_before
,
item5
.
profit_loss
.
january
,
item5
.
profit_loss
.
february
,
...
...
@@ -339,7 +329,6 @@ export default class ProfitLoss extends Component {
item6
.
formula
,
item6
.
level
,
item6
.
description
,
item6
.
profit_loss
.
notes
,
item6
.
profit_loss
.
total_actual_before
,
item6
.
profit_loss
.
january
,
item6
.
profit_loss
.
february
,
...
...
@@ -365,7 +354,6 @@ export default class ProfitLoss extends Component {
item6
.
formula
,
item6
.
level
,
item6
.
description
,
item6
.
profit_loss
.
notes
,
item6
.
profit_loss
.
total_actual_before
,
item6
.
profit_loss
.
january
,
item6
.
profit_loss
.
february
,
...
...
@@ -393,7 +381,6 @@ export default class ProfitLoss extends Component {
item5
.
formula
,
item5
.
level
,
item5
.
description
,
item5
.
profit_loss
.
notes
,
item5
.
profit_loss
.
total_actual_before
,
item5
.
profit_loss
.
january
,
item5
.
profit_loss
.
february
,
...
...
@@ -421,7 +408,6 @@ export default class ProfitLoss extends Component {
item4
.
formula
,
item4
.
level
,
item4
.
description
,
item4
.
profit_loss
.
notes
,
item4
.
profit_loss
.
total_actual_before
,
item4
.
profit_loss
.
january
,
item4
.
profit_loss
.
february
,
...
...
@@ -449,7 +435,6 @@ export default class ProfitLoss extends Component {
item3
.
formula
,
item3
.
level
,
item3
.
description
,
item3
.
profit_loss
.
notes
,
item3
.
profit_loss
.
total_actual_before
,
item3
.
profit_loss
.
january
,
item3
.
profit_loss
.
february
,
...
...
@@ -477,7 +462,6 @@ export default class ProfitLoss extends Component {
item2
.
formula
,
item2
.
level
,
item2
.
description
,
item2
.
profit_loss
.
notes
,
item2
.
profit_loss
.
total_actual_before
,
item2
.
profit_loss
.
january
,
item2
.
profit_loss
.
february
,
...
...
@@ -505,7 +489,6 @@ export default class ProfitLoss extends Component {
item1
.
formula
,
item1
.
level
,
item1
.
description
,
item1
.
profit_loss
.
notes
,
item1
.
profit_loss
.
total_actual_before
,
item1
.
profit_loss
.
january
,
item1
.
profit_loss
.
february
,
...
...
@@ -533,7 +516,6 @@ export default class ProfitLoss extends Component {
itemss
.
formula
,
itemss
.
level
,
itemss
.
description
,
itemss
.
profit_loss
.
notes
,
itemss
.
profit_loss
.
total_actual_before
,
itemss
.
profit_loss
.
january
,
itemss
.
profit_loss
.
february
,
...
...
@@ -561,7 +543,6 @@ export default class ProfitLoss extends Component {
items
.
formula
,
items
.
level
,
items
.
description
,
items
.
profit_loss
.
notes
,
items
.
profit_loss
.
total_actual_before
,
items
.
profit_loss
.
january
,
items
.
profit_loss
.
february
,
...
...
@@ -589,7 +570,6 @@ export default class ProfitLoss extends Component {
val
.
formula
,
val
.
level
,
val
.
description
,
val
.
profit_loss
.
notes
,
val
.
profit_loss
.
total_actual_before
,
val
.
profit_loss
.
january
,
val
.
profit_loss
.
february
,
...
...
@@ -617,7 +597,6 @@ export default class ProfitLoss extends Component {
i
.
formula
,
i
.
level
,
i
.
description
,
i
.
profit_loss
.
notes
,
i
.
profit_loss
.
total_actual_before
,
i
.
profit_loss
.
january
,
i
.
profit_loss
.
february
,
...
...
@@ -644,7 +623,6 @@ export default class ProfitLoss extends Component {
i
.
formula
,
i
.
level
,
i
.
description
,
i
.
profit_loss
.
notes
,
i
.
profit_loss
.
total_actual_before
,
i
.
profit_loss
.
january
,
i
.
profit_loss
.
february
,
...
...
@@ -672,7 +650,6 @@ export default class ProfitLoss extends Component {
item
.
formula
,
item
.
level
,
item
.
description
,
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
total_actual_before
,
item
.
profit_loss
.
january
,
item
.
profit_loss
.
february
,
...
...
@@ -787,31 +764,31 @@ export default class ProfitLoss extends Component {
name
:
"Account"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
key
=
{
columnMeta
.
index
}
style
=
{{
...
style
,
top
:
0
,
zIndex
:
102
,
backgroundColor
:
'#
354960'
,
width
:
388
}}
>
<
TableCell
key
=
{
columnMeta
.
index
}
style
=
{{
...
style
,
top
:
0
,
zIndex
:
102
,
backgroundColor
:
'#
1c71b8'
,
width
:
300
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'left'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
setCellProps
:
()
=>
({
style
}),
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
width
:
3
88
}}
>
<
div
style
=
{{
width
:
3
00
}}
>
{
tableMeta
.
rowData
[
4
]
==
0
?
<
span
style
=
{{
fontSize
:
12
,
fontWeight
:
'bold'
}}
>
{
String
(
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
).
toUpperCase
()}
<
/span
>
:
tableMeta
.
rowData
[
4
]
===
1
?
<
span
style
=
{{
fontSize
:
12
,
marginLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
{
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
}
<
/span>
:
<
span
style
=
{{
fontSize
:
12
,
marginLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
{
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
}
<
/span
>
<
div
style
=
{{
paddingLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
<
span
style
=
{{
fontSize
:
12
}}
>
{
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
}
<
/span
>
<
/div
>
}
<
/div
>
)
}
}
},
{
name
:
"31
Dec 2020 Actual
"
,
name
:
"31
-Dec-2020 OL PA
"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
54960
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
white
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
7b5e6
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
black
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
setCellProps
:
()
=>
({
style2
}),
...
...
@@ -879,10 +856,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Jan
uary
2021"
,
name
:
"Jan 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -951,10 +928,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Feb
ruary
2021"
,
name
:
"Feb 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1023,10 +1000,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Mar
ch
2021"
,
name
:
"Mar 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1095,10 +1072,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Apr
il
2021"
,
name
:
"Apr 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1170,7 +1147,7 @@ export default class ProfitLoss extends Component {
name
:
"May 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1239,10 +1216,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Jun
e
2021"
,
name
:
"Jun 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1311,10 +1288,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Jul
y
2021"
,
name
:
"Jul 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1383,10 +1360,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Aug
ust
2021"
,
name
:
"Aug 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1455,10 +1432,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Sep
tember
2021"
,
name
:
"Sep 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1527,10 +1504,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Oct
ober
2021"
,
name
:
"Oct 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1599,10 +1576,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Nov
ember
2021"
,
name
:
"Nov 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1671,10 +1648,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"Dec
ember
2021"
,
name
:
"Dec 2021"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1743,10 +1720,10 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"
Current Total
"
,
name
:
"
31-Dec-21 MB
"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
354960
'
,
width
:
96
}}
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#
1c71b8
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'white'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
...
...
@@ -1815,11 +1792,11 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"31
Dec 2022 Total
"
,
name
:
"31
-Dec-22 Forcast
"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
54960
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
white
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
7b5e6
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
black
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
setCellProps
:
()
=>
({
style2
}),
...
...
@@ -1887,11 +1864,11 @@ export default class ProfitLoss extends Component {
}
}
},
{
name
:
"31
Dec 2023 Total
"
,
name
:
"31
-Dec-23 Forcast
"
,
options
:
{
customHeadRender
:
(
columnMeta
)
=>
(
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
54960
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
white
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
TableCell
style
=
{{
...
style2
,
top
:
0
,
zIndex
:
99
,
backgroundColor
:
'#3
7b5e6
'
,
width
:
96
}}
>
<
Typography
style
=
{{
color
:
'
black
'
,
fontSize
:
12
,
fontWeight
:
'bold'
,
textAlign
:
'center'
}}
>
{
columnMeta
.
name
}
<
/Typography
>
<
/TableCell
>
),
setCellProps
:
()
=>
({
style2
}),
...
...
@@ -1980,7 +1957,7 @@ export default class ProfitLoss extends Component {
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#4b4b4b'
}}
>
in
IDR
mn
<
/Typography
>
<
/div
>
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
200
,
height
:
this
.
props
.
height
-
2
00
}}
>
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
,
height
:
this
.
props
.
height
-
4
00
}}
>
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
<
MUIDataTable
data
=
{
dataTable2
}
...
...
@@ -1990,7 +1967,7 @@ export default class ProfitLoss extends Component {
<
/MuiThemeProvider
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x"
>
<
div
className
=
"grid grid-2x"
style
=
{{
marginTop
:
20
}}
>
<
div
className
=
"col-1"
>
<
button
className
=
"button"
...
...
src/container/MasterData/ReportItems.js
View file @
6bceff12
...
...
@@ -604,7 +604,7 @@ export default class ReportItems extends Component {
if
(
response
.
data
.
status
==
'success'
)
{
let
data
=
response
.
data
.
data
let
listData
=
data
.
sort
((
a
,
b
)
=>
a
.
item_report_id
-
b
.
item_report_id
).
map
((
item
,
index
)
=>
{
return
[
index
,
item
.
item_report_id
,
item
.
report_name
,
item
.
company_name
,
item
.
order
,
item
.
description
,
item
.
parent
,
item
.
uom
,
item
.
weight
,
item
.
type_item_report_name
,
item
.
status
]
return
[
index
,
item
.
item_report_id
,
item
.
report_name
,
item
.
company_name
,
item
.
order
,
item
.
description
,
item
.
parent
,
item
.
uom
,
item
.
weight
,
item
.
type_item_report_name
,
item
.
kpi_type
,
item
.
max_ach
,
item
.
formula_ytd
,
item
.
status
]
})
this
.
setState
({
dataTable
:
listData
,
listData
:
response
.
data
.
data
},
()
=>
{
console
.
log
(
this
.
state
.
dataTable
);
...
...
@@ -880,7 +880,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -892,7 +892,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -904,7 +904,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -916,7 +916,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -928,7 +928,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -940,7 +940,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -952,7 +952,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -964,7 +964,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -976,7 +976,43 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
10
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
13
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
}
},
{
name
:
"KPI Type"
,
options
:
{
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
13
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
}
},
{
name
:
"Max Achievement"
,
options
:
{
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
13
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
}
},
{
name
:
"Formula YTD"
,
options
:
{
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
13
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
/div
>
);
}
...
...
@@ -988,7 +1024,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
display
:
'flex'
}}
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
0
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/span
>
<
span
style
=
{{
color
:
tableMeta
.
rowData
[
1
3
]
===
"Active"
?
"#656565"
:
'rgba(0, 0, 0, 0.25)'
}}
>
{
val
}
<
/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