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
c4ca098d
Commit
c4ca098d
authored
Apr 15, 2021
by
Dida Adams Arizona
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'GGMAC' into 'master'
Ggmac See merge request
!1410
parents
fe409346
5027733c
Changes
7
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
567 additions
and
13 deletions
+567
-13
index.js
src/api/index.js
+6
-2
HomePage.js
src/container/HomePage.js
+18
-4
DashboardCAT.js
src/container/Laporan/DashboardCAT.js
+16
-0
DashboardFinancial.js
src/container/Laporan/DashboardFinancial.js
+16
-2
OutlookPA.js
src/container/OutlookPA.js
+1
-2
RollingOutlook.js
src/container/RollingOutlook.js
+500
-1
ProfitLossRO.js
src/container/RollingOutlook/ProfitLossRO.js
+10
-2
No files found.
src/api/index.js
View file @
c4ca098d
...
@@ -363,6 +363,8 @@ const create = (type = "") => {
...
@@ -363,6 +363,8 @@ const create = (type = "") => {
const
createCFOLPA
=
(
body
)
=>
api
.
post
(
'transaction/cash_flow/outlook_pa/create_outlook_report'
,
body
)
const
createCFOLPA
=
(
body
)
=>
api
.
post
(
'transaction/cash_flow/outlook_pa/create_outlook_report'
,
body
)
const
getHierarkiDBPLOLPA
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/outlook_pa/get_report_hierarki'
,
body
)
const
getHierarkiDBPLOLPA
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/outlook_pa/get_report_hierarki'
,
body
)
const
createDBPLOLPA
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/outlook_pa/create_outlook_report'
,
body
)
const
createDBPLOLPA
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/outlook_pa/create_outlook_report'
,
body
)
const
getHierarkiDBPLRO
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/rolling_outlook/get_report_hierarki'
,
body
)
const
createDBPLRO
=
(
body
)
=>
api
.
post
(
'transaction/db_profit_loss/rolling_outlook/create_rolling_outlook'
,
body
)
// Monthly
// Monthly
const
getMonthlyReport
=
(
body
)
=>
api
.
post
(
'transaction/monthly_report/get_all_report'
,
body
)
const
getMonthlyReport
=
(
body
)
=>
api
.
post
(
'transaction/monthly_report/get_all_report'
,
body
)
...
@@ -796,7 +798,9 @@ const create = (type = "") => {
...
@@ -796,7 +798,9 @@ const create = (type = "") => {
getHierarkiCFOLPA
,
getHierarkiCFOLPA
,
createCFOLPA
,
createCFOLPA
,
getHierarkiDBPLOLPA
,
getHierarkiDBPLOLPA
,
createDBPLOLPA
createDBPLOLPA
,
getHierarkiDBPLRO
,
createDBPLRO
}
}
}
}
...
...
src/container/HomePage.js
View file @
c4ca098d
...
@@ -71,11 +71,25 @@ class HomePage extends Component {
...
@@ -71,11 +71,25 @@ class HomePage extends Component {
let
userId
=
localStorage
.
getItem
(
Constant
.
USER
)
let
userId
=
localStorage
.
getItem
(
Constant
.
USER
)
api
.
create
().
getDetailUser
(
userId
).
then
((
response
)
=>
{
api
.
create
().
getDetailUser
(
userId
).
then
((
response
)
=>
{
if
(
response
.
data
)
{
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
'success'
)
{
if
(
response
.
data
.
status
===
'success'
)
{
this
.
setState
({
userData
:
response
.
data
.
data
},
()
=>
{
this
.
setState
({
userData
:
response
.
data
.
data
})
// console.log(this.state.userData)
// console.log(response.data.data)
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
},
()
=>
{
if
(
response
.
data
.
message
.
includes
(
"Someone Logged In"
)
||
response
.
data
.
message
.
includes
(
"Token Expired"
))
{
setTimeout
(()
=>
{
localStorage
.
removeItem
(
Constant
.
TOKEN
)
window
.
location
.
reload
();
},
1000
);
}
})
})
}
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'error'
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
problem
,
tipeAlert
:
'error'
})
}
}
})
})
// api.create().checkApprover().then(response => {
// api.create().checkApprover().then(response => {
...
...
src/container/Laporan/DashboardCAT.js
View file @
c4ca098d
...
@@ -82,8 +82,24 @@ export default class DashboardCAT extends Component {
...
@@ -82,8 +82,24 @@ export default class DashboardCAT extends Component {
this
.
getCompanyActive
()
this
.
getCompanyActive
()
})
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
},
()
=>
{
if
(
response
.
data
.
message
.
includes
(
"Someone Logged In"
)
||
response
.
data
.
message
.
includes
(
"Token Expired"
))
{
setTimeout
(()
=>
{
localStorage
.
removeItem
(
Constant
.
TOKEN
)
window
.
location
.
reload
();
},
1000
);
}
}
})
}
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'error'
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
problem
,
tipeAlert
:
'error'
})
}
// }
// }
})
})
}
}
...
...
src/container/Laporan/DashboardFinancial.js
View file @
c4ca098d
...
@@ -104,7 +104,21 @@ export default class DashboardFinancial extends React.Component {
...
@@ -104,7 +104,21 @@ export default class DashboardFinancial extends React.Component {
this
.
getCompanyActive
()
this
.
getCompanyActive
()
})
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
},
()
=>
{
if
(
response
.
data
.
message
.
includes
(
"Someone Logged In"
)
||
response
.
data
.
message
.
includes
(
"Token Expired"
))
{
setTimeout
(()
=>
{
localStorage
.
removeItem
(
Constant
.
TOKEN
)
window
.
location
.
reload
();
},
1000
);
}
}
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'error'
})
}
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
problem
,
tipeAlert
:
'error'
})
}
}
})
})
}
}
...
@@ -132,7 +146,7 @@ export default class DashboardFinancial extends React.Component {
...
@@ -132,7 +146,7 @@ export default class DashboardFinancial extends React.Component {
})
})
let
defaultProps
=
{
let
defaultProps
=
{
options
:
arrayBaru
.
sort
((
a
,
b
)
=>
a
.
company_name
.
localeCompare
(
b
.
company_name
)),
options
:
arrayBaru
.
sort
((
a
,
b
)
=>
a
.
company_name
.
localeCompare
(
b
.
company_name
)),
getOptionLabel
:
(
option
)
=>
titleCase
(
option
.
company_name
),
getOptionLabel
:
(
option
)
=>
titleCase
(
option
.
company_name
),
};
};
...
...
src/container/OutlookPA.js
View file @
c4ca098d
...
@@ -821,7 +821,7 @@ export default class OutlookPA extends Component {
...
@@ -821,7 +821,7 @@ export default class OutlookPA extends Component {
"revision"
:
Number
(
this
.
state
.
lastRevision
),
"revision"
:
Number
(
this
.
state
.
lastRevision
),
"periode"
:
this
.
state
.
periode
.
periode
,
"periode"
:
this
.
state
.
periode
.
periode
,
"company_id"
:
this
.
state
.
company
.
company_id
,
"company_id"
:
this
.
state
.
company
.
company_id
,
"
submission
_id"
:
this
.
state
.
PLID
,
"
outlook_pa
_id"
:
this
.
state
.
PLID
,
}
}
api
.
create
().
getHierarkiDBPLOLPA
(
payload
).
then
(
response
=>
{
api
.
create
().
getHierarkiDBPLOLPA
(
payload
).
then
(
response
=>
{
// console.log(response);
// console.log(response);
...
@@ -1282,7 +1282,6 @@ export default class OutlookPA extends Component {
...
@@ -1282,7 +1282,6 @@ export default class OutlookPA extends Component {
"status"
:
"submitted"
,
"status"
:
"submitted"
,
"profit_loss_id"
:
this
.
state
.
PLID
,
"profit_loss_id"
:
this
.
state
.
PLID
,
"profit_loss_olpa"
:
this
.
state
.
dbPL
,
"profit_loss_olpa"
:
this
.
state
.
dbPL
,
"months"
:
0
,
}
}
console
.
log
(
this
.
state
.
dbPL
)
console
.
log
(
this
.
state
.
dbPL
)
// console.log(JSON.stringify(payload))
// console.log(JSON.stringify(payload))
...
...
src/container/RollingOutlook.js
View file @
c4ca098d
This diff is collapsed.
Click to expand it.
src/container/RollingOutlook/ProfitLossRO.js
View file @
c4ca098d
...
@@ -405,7 +405,11 @@ export default class ProfitLossROO extends Component {
...
@@ -405,7 +405,11 @@ export default class ProfitLossROO extends Component {
console
.
log
(
response
);
console
.
log
(
response
);
if
(
response
.
data
)
{
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
if
(
response
.
data
.
status
===
"success"
)
{
if
(
type
==
'submitted'
)
{
this
.
props
.
refresh
(
'PL'
)
}
else
{
this
.
props
.
refresh
()
this
.
props
.
refresh
()
}
this
.
props
.
onClickClose
()
this
.
props
.
onClickClose
()
}
else
{
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
loading
:
false
,
handleTekTekTek
:
0
},
()
=>
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
loading
:
false
,
handleTekTekTek
:
0
},
()
=>
{
...
@@ -573,7 +577,11 @@ export default class ProfitLossROO extends Component {
...
@@ -573,7 +577,11 @@ export default class ProfitLossROO extends Component {
if
(
response
.
ok
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
"success"
)
{
if
(
response
.
data
.
status
===
"success"
)
{
this
.
props
.
onClickClose
()
this
.
props
.
onClickClose
()
if
(
type
==
'submitted'
)
{
this
.
props
.
refresh
(
'PL'
)
}
else
{
this
.
props
.
refresh
()
this
.
props
.
refresh
()
}
// this.props.onClickClose()
// this.props.onClickClose()
// this.props.getReport()
// this.props.getReport()
}
else
{
}
else
{
...
...
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