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
963725e6
Commit
963725e6
authored
Oct 03, 2020
by
Dida Adams Arizona
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'syadziy' into 'master'
update See merge request
!434
parents
59a43758
c0540712
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
4 deletions
+11
-4
index.js
src/api/index.js
+1
-1
BudgetTahunan.js
src/container/BudgetTahunan.js
+10
-3
No files found.
src/api/index.js
View file @
963725e6
...
...
@@ -193,7 +193,7 @@ const create = (type = "") => {
const
getDetailReportMB
=
(
body
)
=>
api
.
post
(
'/transaction/master_budget/get_report_hierarki'
,
body
)
const
getLastestUpdateMB
=
(
body
)
=>
api
.
post
(
'/transaction/master_budget/get_latest_update'
,
body
)
const
createSubmitReport
=
(
body
)
=>
api
.
post
(
'transaction/master_budget/create_submission_report'
,
body
)
const
getSubmission
=
(
body
)
=>
api
.
post
(
'transaction/get_submission_id'
,
body
)
const
getSubmission
=
(
body
)
=>
api
.
post
(
'transaction/
master_budget/
get_submission_id'
,
body
)
const
checkUploadMB
=
(
body
)
=>
api
.
post
(
'transaction/master_budget/check_import'
,
body
)
const
uploadMasterBudget
=
(
body
)
=>
api
.
post
(
'transaction/master_budget/import_master_budget'
,
body
)
const
validateSubmitReport
=
(
body
)
=>
api
.
post
(
'transaction/master_budget/validate_save'
,
body
)
...
...
src/container/BudgetTahunan.js
View file @
963725e6
...
...
@@ -60,7 +60,9 @@ export default class BudgetTahunan extends Component {
submitter
:
false
,
detailRevisiCheck
:
[],
lastRevision
:
""
,
checkApprover
:
false
checkApprover
:
false
,
lastPeriod
:
''
,
latestPeriode
:
''
}
this
.
fileHandler
=
this
.
fileHandler
.
bind
(
this
);
}
...
...
@@ -254,7 +256,7 @@ export default class BudgetTahunan extends Component {
api
.
create
().
getLastPeriod
(
this
.
state
.
company
.
company_id
).
then
(
response
=>
{
console
.
log
(
response
);
if
(
response
.
data
.
status
===
"success"
)
{
this
.
setState
({
lastPeriod
:
response
.
data
.
data
.
last_periode
},
()
=>
{
this
.
setState
({
lastPeriod
:
response
.
data
.
data
.
last_periode
,
latestPeriode
:
response
.
data
.
data
.
latest_periode
},
()
=>
{
this
.
getPeriode
()
})
}
...
...
@@ -267,7 +269,12 @@ export default class BudgetTahunan extends Component {
// let year = this.state.rawData ? this.state.rawData.periode : format(dateNow, 'yyyy')
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
let
data
=
response
.
data
.
data
let
data
=
[]
response
.
data
.
data
.
map
((
item
)
=>
{
if
((
item
==
this
.
state
.
latestPeriode
||
item
>
this
.
state
.
latestPeriode
)
&&
(
item
==
this
.
state
.
lastPeriod
||
item
<
this
.
state
.
lastPeriod
))
{
data
.
push
(
item
)
}
})
let
periodeData
=
data
.
map
((
item
)
=>
{
return
{
periode
:
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