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
d1d278d9
Commit
d1d278d9
authored
Mar 19, 2021
by
Riri Novita
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'riri' into 'master'
up See merge request
!1298
parents
03e6e30d
9dac1ac1
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
13 deletions
+5
-13
OperatingIndicatorRO.js
src/container/RollingOutlook/OperatingIndicatorRO.js
+5
-13
No files found.
src/container/RollingOutlook/OperatingIndicatorRO.js
View file @
d1d278d9
...
...
@@ -333,7 +333,7 @@ export default class OperatingIndicatorRO extends Component {
downloadTemplate
=
async
()
=>
{
let
res
=
await
fetch
(
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/operating_indicator/rolling_outlook/download_template?report_id=
${
this
.
props
.
data
.
report_id
}
&&company_id=
${
this
.
props
.
data
.
company
.
company_id
}
&&year=
${
this
.
props
.
data
.
periode
}
`
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/operating_indicator/rolling_outlook/download_template?report_id=
${
this
.
props
.
data
.
report_id
}
&&company_id=
${
this
.
props
.
data
.
company
.
company_id
}
&&year=
${
this
.
props
.
data
.
periode
}
&&quartal=
${
this
.
props
.
quartal
}
`
)
res
=
await
res
.
blob
()
// // console.log(res)
...
...
@@ -341,7 +341,7 @@ export default class OperatingIndicatorRO extends Component {
let
url
=
window
.
URL
.
createObjectURL
(
res
);
let
a
=
document
.
createElement
(
'a'
);
a
.
href
=
url
;
a
.
download
=
'Template
Master Budget
Operating Indicator.xlsx'
;
a
.
download
=
'Template
Rolling Outlook
Operating Indicator.xlsx'
;
a
.
click
();
}
}
...
...
@@ -520,14 +520,6 @@ export default class OperatingIndicatorRO extends Component {
let
val
=
String
(
value
).
split
(
","
).
join
(
""
)
let
total
=
0
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
Number
(
val
)
// dataTable2[tableMeta.rowIndex].map((item,index) => {
// if (index >= 8 && index <= 19) {
// let valItem = item == undefined || item == ""? 0 : item
// total += Number(valItem)
// }
// })
// dataTable2[tableMeta.rowIndex][20] = total
// // console.log(dataTable2[tableMeta.rowIndex])
}
const
handleValue
=
(
value
,
tableMeta
)
=>
{
...
...
@@ -535,12 +527,12 @@ export default class OperatingIndicatorRO extends Component {
let
total
=
0
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
Number
(
val
)
dataTable2
[
tableMeta
.
rowIndex
].
map
((
item
,
index
)
=>
{
if
(
index
>=
8
&&
index
<=
19
)
{
if
(
index
>=
7
&&
index
<=
19
)
{
let
valItem
=
item
==
undefined
||
item
==
""
?
0
:
item
total
+=
Number
(
valItem
)
}
})
dataTable2
[
tableMeta
.
rowIndex
][
20
]
=
total
dataTable2
[
tableMeta
.
rowIndex
][
19
]
=
total
return
total
}
...
...
@@ -572,7 +564,7 @@ export default class OperatingIndicatorRO extends Component {
}
else
if
(
item
==
'-'
||
item
==
'+'
||
item
==
'/'
||
item
==
'*'
)
{
arrayFormulaConvert
.
push
(
item
)
}
else
{
let
indexID
=
dataTable2
.
findIndex
((
val
)
=>
val
[
2
1
]
==
item
)
let
indexID
=
dataTable2
.
findIndex
((
val
)
=>
val
[
2
0
]
==
item
)
if
(
tambahan
)
{
if
(
item
==
'-'
||
item
==
'+'
||
item
==
'/'
||
item
==
'*'
)
{
opet
=
item
...
...
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