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
ef68e97c
Commit
ef68e97c
authored
Dec 05, 2020
by
Dida Adams Arizona
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'didam' into 'master'
ketinggalan See merge request
!751
parents
23bdd5de
43490a74
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
50 additions
and
6 deletions
+50
-6
BalanceSheetMR.js
src/container/MonthlyReport/BalanceSheetMR.js
+50
-6
No files found.
src/container/MonthlyReport/BalanceSheetMR.js
View file @
ef68e97c
...
...
@@ -520,9 +520,11 @@ export default class BalanceSheetMR extends Component {
if
(
String
(
item
).
includes
(
'#'
))
{
if
(
String
(
item
).
includes
(
'[M-1]'
))
{
let
tst
=
String
(
item
).
replace
(
'[M-1]'
,
''
)
let
indexID
=
dataTable2
.
findIndex
((
val
)
=>
val
[
21
]
==
tst
)
// let indexID = dataTable2.findIndex((val) => val[21] == tst)
let
data
=
tableMeta
.
rowData
[
20
]
let
indexID
=
data
.
findIndex
((
val
)
=>
val
.
item_formula
==
String
(
`@
${
item
}
`
))
if
(
indexID
!==
-
1
)
{
let
valuezz
=
data
Table2
[
indexID
][
9
]
let
valuezz
=
data
[
indexID
].
value
anjay
.
push
(
valuezz
==
""
?
0
:
valuezz
)
}
}
else
{
...
...
@@ -584,9 +586,11 @@ export default class BalanceSheetMR extends Component {
let
totalPrio
=
0
let
optPrio
=
""
let
prio
=
false
let
optPrev
=
""
anjay2
.
map
((
item
,
index
)
=>
{
if
(
Array
.
isArray
(
item
))
{
prio
=
true
optPrev
=
opt
item
.
map
((
items
,
indexs
)
=>
{
if
(
items
==
"+"
)
{
optPrio
=
"tambah"
...
...
@@ -628,7 +632,17 @@ export default class BalanceSheetMR extends Component {
if
(
item
==
"+"
)
{
opt
=
"tambah"
if
(
prio
)
{
total
=
Number
(
Number
(
totalPrio
)
+
Number
(
total
))
if
(
optPrev
==
"tambah"
)
{
total
=
Number
(
total
)
+
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kurang"
)
{
total
=
Number
(
total
)
-
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kali"
)
{
total
=
Number
(
total
)
*
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"bagi"
)
{
total
=
Number
(
total
)
/
Number
(
totalPrio
)
==
NaN
?
0
:
Number
(
total
)
/
Number
(
totalPrio
)
}
else
{
total
+=
Number
(
totalPrio
)
}
prio
=
false
totalPrio
=
0
optPrio
=
""
...
...
@@ -636,7 +650,17 @@ export default class BalanceSheetMR extends Component {
}
else
if
(
item
==
"-"
)
{
opt
=
"kurang"
if
(
prio
)
{
total
=
Number
(
Number
(
totalPrio
)
+
Number
(
total
))
if
(
optPrev
==
"tambah"
)
{
total
=
Number
(
total
)
+
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kurang"
)
{
total
=
Number
(
total
)
-
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kali"
)
{
total
=
Number
(
total
)
*
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"bagi"
)
{
total
=
Number
(
total
)
/
Number
(
totalPrio
)
==
NaN
?
0
:
Number
(
total
)
/
Number
(
totalPrio
)
}
else
{
total
+=
Number
(
totalPrio
)
}
prio
=
false
totalPrio
=
0
optPrio
=
""
...
...
@@ -644,7 +668,17 @@ export default class BalanceSheetMR extends Component {
}
else
if
(
item
==
"*"
)
{
opt
=
"kali"
if
(
prio
)
{
total
=
Number
(
Number
(
totalPrio
)
+
Number
(
total
))
if
(
optPrev
==
"tambah"
)
{
total
=
Number
(
total
)
+
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kurang"
)
{
total
=
Number
(
total
)
-
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kali"
)
{
total
=
Number
(
total
)
*
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"bagi"
)
{
total
=
Number
(
total
)
/
Number
(
totalPrio
)
==
NaN
?
0
:
Number
(
total
)
/
Number
(
totalPrio
)
}
else
{
total
+=
Number
(
totalPrio
)
}
prio
=
false
totalPrio
=
0
optPrio
=
""
...
...
@@ -652,7 +686,17 @@ export default class BalanceSheetMR extends Component {
}
else
if
(
item
==
"/"
)
{
opt
=
"bagi"
if
(
prio
)
{
total
=
Number
(
Number
(
totalPrio
)
+
Number
(
total
))
if
(
optPrev
==
"tambah"
)
{
total
=
Number
(
total
)
+
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kurang"
)
{
total
=
Number
(
total
)
-
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"kali"
)
{
total
=
Number
(
total
)
*
Number
(
totalPrio
)
}
else
if
(
optPrev
==
"bagi"
)
{
total
=
Number
(
total
)
/
Number
(
totalPrio
)
==
NaN
?
0
:
Number
(
total
)
/
Number
(
totalPrio
)
}
else
{
total
+=
Number
(
totalPrio
)
}
prio
=
false
totalPrio
=
0
optPrio
=
""
...
...
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