Commit b8fa1044 authored by Hardiansyah's avatar Hardiansyah

tambah filter

parent 31e77635
...@@ -394,7 +394,8 @@ export default class BalanceSheetRO extends Component { ...@@ -394,7 +394,8 @@ export default class BalanceSheetRO extends Component {
"quartal": this.props.quarter, "quartal": this.props.quarter,
"status": type, "status": type,
"currency_id": this.props.defaultCurrency.id, "currency_id": this.props.defaultCurrency.id,
"balance_sheet": data "balance_sheet": data,
"master_report_type_id": this.props?.master_report_type_id
} }
console.log(payload); console.log(payload);
api.create('UPLOAD').createRollingOutlookBS(payload).then(response => { api.create('UPLOAD').createRollingOutlookBS(payload).then(response => {
......
...@@ -462,7 +462,8 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -462,7 +462,8 @@ export default class CorporateAnnualTargetRO extends Component {
"quartal": this.props.quarter, "quartal": this.props.quarter,
"currency_id": this.props.defaultCurrency.id, "currency_id": this.props.defaultCurrency.id,
"status": type, "status": type,
"cat": data "cat": data,
"master_report_type_id": this.props?.master_report_type_id
} }
// console.log(JSON.stringify(payload)); // console.log(JSON.stringify(payload));
api.create('UPLOAD').createRollingOutlookCAT(payload).then(response => { api.create('UPLOAD').createRollingOutlookCAT(payload).then(response => {
......
...@@ -419,7 +419,8 @@ export default class ProfitLossROO extends Component { ...@@ -419,7 +419,8 @@ export default class ProfitLossROO extends Component {
"currency_id": this.props.defaultCurrency.id, "currency_id": this.props.defaultCurrency.id,
"quartal": this.props.quarter, "quartal": this.props.quarter,
"status": type, "status": type,
"profit_loss": data "profit_loss": data,
"master_report_type_id": this.props?.master_report_type_id
} }
console.log("backToRollingOutlook payload", payload); console.log("backToRollingOutlook payload", payload);
// console.log(JSON.stringify(payload)); // console.log(JSON.stringify(payload));
......
...@@ -1757,6 +1757,13 @@ export default class RollingOutlook extends Component { ...@@ -1757,6 +1757,13 @@ export default class RollingOutlook extends Component {
return tableKey === 'CAT' ? lastStatusCat : lastStatus return tableKey === 'CAT' ? lastStatusCat : lastStatus
} }
getActiveMasterReportTypeId = () => {
const { tableKey, rowDataFinance, rowDataCAT } = this.state
const mstIdFinance = rowDataFinance?.length > 0 && rowDataFinance[0]?.master_report_type_id
const mstIdCAT = rowDataCAT?.length > 0 && rowDataCAT[0]?.master_report_type_id
return tableKey === 'CAT' ? mstIdCAT : mstIdFinance
}
getSubmissionObj = (tableKeyParam) => { getSubmissionObj = (tableKeyParam) => {
const { const {
tableKey, tableKey,
...@@ -2661,6 +2668,7 @@ export default class RollingOutlook extends Component { ...@@ -2661,6 +2668,7 @@ export default class RollingOutlook extends Component {
prevRevision={this.state.isSubmit ? this.state.prevRevision : true} prevRevision={this.state.isSubmit ? this.state.prevRevision : true}
status={this.state.status} status={this.state.status}
lastStatus={this.getLastStatus()} lastStatus={this.getLastStatus()}
master_report_type_id={this.getActiveMasterReportTypeId()}
/> />
)} )}
...@@ -2683,6 +2691,7 @@ export default class RollingOutlook extends Component { ...@@ -2683,6 +2691,7 @@ export default class RollingOutlook extends Component {
prevRevision={this.state.isSubmit ? this.state.prevRevision : true} prevRevision={this.state.isSubmit ? this.state.prevRevision : true}
status={this.state.status} status={this.state.status}
lastStatus={this.getLastStatus()} lastStatus={this.getLastStatus()}
master_report_type_id={this.getActiveMasterReportTypeId()}
/> />
)} )}
...@@ -2702,6 +2711,7 @@ export default class RollingOutlook extends Component { ...@@ -2702,6 +2711,7 @@ export default class RollingOutlook extends Component {
refresh={this.getRollingOutlookID.bind(this)} refresh={this.getRollingOutlookID.bind(this)}
status={this.state.status} status={this.state.status}
lastStatus={this.getLastStatus()} lastStatus={this.getLastStatus()}
master_report_type_id={this.getActiveMasterReportTypeId()}
quarter={this.state.quarter.value} quarter={this.state.quarter.value}
isApprover={this.state.isApprover} isApprover={this.state.isApprover}
prevRevision={this.state.isSubmit ? this.state.prevRevision : true} prevRevision={this.state.isSubmit ? this.state.prevRevision : true}
...@@ -2751,6 +2761,7 @@ export default class RollingOutlook extends Component { ...@@ -2751,6 +2761,7 @@ export default class RollingOutlook extends Component {
status={this.state.status} status={this.state.status}
lastStatus={this.getLastStatus()} lastStatus={this.getLastStatus()}
PLBSFAMSubmitted={this.getLastStatus() === 'APPROVED' ? true : false} PLBSFAMSubmitted={this.getLastStatus() === 'APPROVED' ? true : false}
master_report_type_id={this.getActiveMasterReportTypeId()}
/> />
)} )}
......
...@@ -411,7 +411,8 @@ export default class TaxPlanning extends Component { ...@@ -411,7 +411,8 @@ export default class TaxPlanning extends Component {
"revision": 0, "revision": 0,
"quartal": this.props.quarter, "quartal": this.props.quarter,
"currency_id": this.props.defaultCurrency.id, "currency_id": this.props.defaultCurrency.id,
"tax_planning": data "tax_planning": data,
"master_report_type_id": this.props?.master_report_type_id
} }
// this.props.saveToMasterBudget(payload) // this.props.saveToMasterBudget(payload)
// this.props.onClickClose() // this.props.onClickClose()
......
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