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
ca45675b
Commit
ca45675b
authored
Mar 23, 2021
by
d.arizona
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
a1d9abc9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
8 deletions
+10
-8
index.js
src/api/index.js
+4
-2
OutlookPA.js
src/container/OutlookPA.js
+6
-6
No files found.
src/api/index.js
View file @
ca45675b
...
...
@@ -347,8 +347,9 @@ const create = (type = "") => {
const
uploadAttOLPA
=
(
body
)
=>
api
.
post
(
'transaction/outlook_pa/upload_attachment'
,
body
)
const
deleteAttOLPA
=
(
id
)
=>
api
.
post
(
`transaction/outlook_pa/delete_attachment/
${
id
}
`
)
const
getReportOLPA
=
(
body
)
=>
api
.
post
(
'transaction/outlook_pa/get_all_report'
,
body
)
const
approvalSubmissionOLPA
=
(
body
)
=>
api
.
post
(
'transaction/outlook_pa/approval_
submission
'
,
body
)
const
approvalSubmissionOLPA
=
(
body
)
=>
api
.
post
(
'transaction/outlook_pa/approval_
outlook
'
,
body
)
const
checkApproverOLPA
=
()
=>
api
.
get
(
'transaction/outlook_pa/is_approver'
)
const
createPeriodeRevisionOLPA
=
(
body
)
=>
api
.
post
(
'transaction/outlook_pa/create_periode_revision'
,
body
)
// Monthly
const
getMonthlyReport
=
(
body
)
=>
api
.
post
(
'transaction/monthly_report/get_all_report'
,
body
)
...
...
@@ -764,7 +765,8 @@ const create = (type = "") => {
checkUploadRollingOutlookOI
,
uploadRollingOutlookOI
,
submitRollingOutlook
,
getRollingOutlookCompanySubmitted
getRollingOutlookCompanySubmitted
,
createPeriodeRevisionOLPA
}
}
...
...
src/container/OutlookPA.js
View file @
ca45675b
...
...
@@ -311,7 +311,7 @@ export default class OutlookPA extends Component {
let
data
=
[]
response
.
data
.
data
.
map
((
item
)
=>
{
if
(
this
.
state
.
isApprover
)
{
if
(
item
>=
2000
&&
item
<=
(
Number
(
currentYear
)))
{
if
(
item
>=
2000
&&
item
<=
(
Number
(
currentYear
)
+
1
))
{
data
.
push
(
item
)
}
}
else
{
...
...
@@ -329,7 +329,7 @@ export default class OutlookPA extends Component {
options
:
periodeData
,
getOptionLabel
:
(
option
)
=>
option
.
periode
,
};
let
periode
=
(
this
.
state
.
lastPeriod
==
""
?
String
(
Number
(
currentYear
))
:
Number
(
this
.
state
.
lastPeriod
))
let
periode
=
(
this
.
state
.
lastPeriod
==
""
?
String
(
Number
(
currentYear
)
+
1
)
:
Number
(
this
.
state
.
lastPeriod
))
let
index
=
data
.
sort
((
a
,
b
)
=>
a
-
b
).
findIndex
((
val
)
=>
val
==
periode
)
// console.log(data)
// console.log(this.state.lastPeriod)
...
...
@@ -450,13 +450,13 @@ export default class OutlookPA extends Component {
"max_periode"
:
moment
(
this
.
state
.
maxDateRevision
).
format
(
'YYYY-MM-DD'
)
}
// console.log(payload)
api
.
create
().
approvalSubmission
(
body
).
then
((
res
)
=>
{
//
console.log(res)
api
.
create
().
approvalSubmission
OLPA
(
body
).
then
((
res
)
=>
{
console
.
log
(
res
)
this
.
setState
({
loading
:
false
},
()
=>
{
this
.
get
Submission
()
this
.
get
OutlookPAID
()
})
if
(
type
==
'revision'
)
{
api
.
create
().
createPeriodeRevision
(
payload
).
then
((
res
)
=>
console
.
log
(
res
))
api
.
create
().
createPeriodeRevision
OLPA
(
payload
).
then
((
res
)
=>
console
.
log
(
res
))
}
})
}
...
...
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