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
915515b4
Commit
915515b4
authored
Dec 07, 2020
by
Deni Rinaldi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'deni-' into 'master'
Deni See merge request
!760
parents
8c6e3f42
16fdd7e0
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
298 additions
and
217 deletions
+298
-217
BudgetTahunan.js
src/container/BudgetTahunan.js
+32
-5
BalanceSheetMR.js
src/container/MonthlyReport/BalanceSheetMR.js
+239
-203
CashFlowMR.js
src/container/MonthlyReport/CashFlowMR.js
+14
-5
FixedAssetsMovementMR.js
src/container/MonthlyReport/FixedAssetsMovementMR.js
+13
-4
No files found.
src/container/BudgetTahunan.js
View file @
915515b4
...
...
@@ -85,14 +85,41 @@ export default class BudgetTahunan extends Component {
if
(
this
.
props
.
location
.
state
!==
undefined
)
{
// // console.log(this.props);
this
.
setState
({
userType
:
this
.
props
.
location
.
state
.
userType
,
intent
:
'Home'
,
lastPeriod
:
this
.
props
.
location
.
state
.
rawData
.
periode
,
rawData
:
this
.
props
.
location
.
state
.
rawData
},
()
=>
{
this
.
checkApprover
()
this
.
getPermission
()
// this.checkApprover()
})
}
else
{
this
.
checkApprover
()
this
.
getPermission
()
// this.checkApprover()
}
}
getPermission
()
{
let
payload
=
{
menu
:
"Master Budget & CAT"
}
api
.
create
().
getPermission
(
payload
).
then
(
response
=>
{
console
.
log
(
response
)
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
this
.
setState
({
btncreate
:
response
.
data
.
data
.
create
,
btnedit
:
response
.
data
.
data
.
edit
,
btndelete
:
response
.
data
.
data
.
delete
,
// load: true
},
()
=>
{
this
.
checkApprover
()
})
}
else
{
this
.
setState
({
// load: true
})
}
}
else
{
this
.
setState
({
load
:
true
})
}
})
}
getRole
(
id
)
{
api
.
create
().
getDetailRole
(
id
).
then
((
response
)
=>
{
...
...
@@ -505,10 +532,10 @@ export default class BudgetTahunan extends Component {
this
.
getLatestPeriodSubmit
()
api
.
create
().
checkApprover
().
then
(
response
=>
{
// // console.log(response);
if
(
response
.
data
.
data
.
is_approver
===
true
)
{
this
.
setState
({
isApprover
:
true
,
checkApprover
:
true
})
}
else
{
if
(
this
.
state
.
btncreate
===
true
&&
this
.
state
.
btnedit
===
true
)
{
this
.
setState
({
isApprover
:
false
,
checkApprover
:
false
})
}
else
{
this
.
setState
({
isApprover
:
true
,
checkApprover
:
true
})
}
})
...
...
src/container/MonthlyReport/BalanceSheetMR.js
View file @
915515b4
This diff is collapsed.
Click to expand it.
src/container/MonthlyReport/CashFlowMR.js
View file @
915515b4
...
...
@@ -161,11 +161,10 @@ export default class CashFlowMR extends Component {
})
anjay
.
push
(
forecastt
)
}
else
if
(
String
(
item
).
includes
(
'[M-1]'
))
{
let
tst
=
String
(
item
).
replace
(
'[M-1]'
,
''
)
let
data
=
tableMeta
.
columnIndex
==
7
?
18
:
tableMeta
.
columnIndex
-
1
let
period
=
data
==
18
?
Number
(
this
.
props
.
periode
)
-
1
:
this
.
props
.
periode
let
tst
=
String
(
item
).
replace
(
'[M-1]'
,
'[M1]'
)
let
data
=
tableMeta
.
columnIndex
// console.log(tableMeta.columnIndex)
let
indexID
=
tableMeta
.
rowData
[
data
].
formula
.
findIndex
((
val
)
=>
val
.
item_formula
==
String
(
`@
${
tst
}
`
)
&&
val
.
periode
==
period
)
let
indexID
=
tableMeta
.
rowData
[
data
].
actual_formula
.
findIndex
((
val
)
=>
val
.
item_formula
==
String
(
`@
${
tst
}
`
)
)
// console.log(indexID)
if
(
indexID
!==
-
1
)
{
let
valuezz
=
tableMeta
.
rowData
[
data
].
formula
[
indexID
].
value
...
...
@@ -361,7 +360,17 @@ export default class CashFlowMR extends Component {
console
.
log
(
tableMeta
);
return
(
<
div
style
=
{{
textAlign
:
'right'
}}
>
{
null
}
{
tableMeta
.
rowData
[
0
]
===
5
||
tableMeta
.
rowData
[
0
]
===
6
||
tableMeta
.
rowData
[
0
]
===
7
?
<
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
(
handleValueFormula
(
value
,
tableMeta
,
2
)).
toFixed
(
1
)}
/
>
<
/span> : null
}
<
/div
>
)
}
...
...
src/container/MonthlyReport/FixedAssetsMovementMR.js
View file @
915515b4
...
...
@@ -402,13 +402,17 @@ export default class FixedAssetsMovementMR extends Component {
}
else
{
if
(
String
(
item
).
includes
(
'#'
))
{
if
(
String
(
item
).
includes
(
'[M-1]'
))
{
let
tst
=
String
(
item
).
replace
(
'[M-1]'
,
''
)
let
indexID
=
dataTable2
.
findIndex
((
val
)
=>
val
[
17
]
==
tst
)
// console.log(indexID);
let
tst
=
String
(
item
).
replace
(
'[M-1]'
,
'[M1]'
)
// console.log(dataTable2[tableMeta.rowIndex]);
// console.log(tableMeta);
// console.log(tst);
let
indexID
=
dataTable2
[
tableMeta
.
rowIndex
][
16
].
findIndex
((
val
)
=>
val
.
item_formula
==
tst
)
console
.
log
(
indexID
);
if
(
indexID
!==
-
1
)
{
let
valuezz
=
dataTable2
[
indexID
][
8
]
let
valuezz
=
dataTable2
[
tableMeta
.
rowIndex
][
16
][
indexID
].
value
anjay
.
push
(
valuezz
==
""
?
0
:
valuezz
)
// console.log(valuezz);
}
}
else
{
let
data
=
tableMeta
.
rowData
[
16
]
...
...
@@ -1183,6 +1187,11 @@ export default class FixedAssetsMovementMR extends Component {
options
:
{
display
:
false
}
},
{
name
:
""
,
options
:
{
display
:
false
}
}]
const
loadingComponent
=
(
...
...
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