Commit da2511e6 authored by Rifka Kurnia Irfiana's avatar Rifka Kurnia Irfiana

Merge branch 'master' of http://103.44.149.204/d.arizona/tia-dev into rifka

parents b830c08d cc1081a4
...@@ -173,7 +173,7 @@ export default class BudgetTahunan extends Component { ...@@ -173,7 +173,7 @@ export default class BudgetTahunan extends Component {
"report_type": "Master Budget", "report_type": "Master Budget",
} }
api.create().getReportTypeBody(payload).then(response => { api.create().getReportTypeBody(payload).then(response => {
// console.log(response); console.log(response);
if (response.data) { if (response.data) {
if (response.data.status === "success") { if (response.data.status === "success") {
let dataTable = response.data.data.map((item, index) => { let dataTable = response.data.data.map((item, index) => {
...@@ -190,7 +190,7 @@ export default class BudgetTahunan extends Component { ...@@ -190,7 +190,7 @@ export default class BudgetTahunan extends Component {
let dataTableRevision = response.data.data.map((item, index) => { let dataTableRevision = response.data.data.map((item, index) => {
return [ return [
item.report_id, item.report_id,
item.report_name, item.report_name === 'CAT' ? 'Corporate Annual Target' : item.report_name,
"" ""
] ]
}) })
...@@ -454,9 +454,15 @@ export default class BudgetTahunan extends Component { ...@@ -454,9 +454,15 @@ export default class BudgetTahunan extends Component {
} }
clickDetail(item, id, revision, status) { clickDetail(item, id, revision, status) {
let items = ''
if (item === 'Corporate Annual Target') {
items = 'CAT'
} else {
items = item
}
// console.log(this.state.dataForRevision); // console.log(this.state.dataForRevision);
this.state.dataForRevision.map(i => { this.state.dataForRevision.map(i => {
if (i.report_name === item) { if (i.report_name === items) {
if (i.revision !== revision) { if (i.revision !== revision) {
this.setState({ prevRevision: true }) this.setState({ prevRevision: true })
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment