Commit b8fa1044 authored by Hardiansyah's avatar Hardiansyah

tambah filter

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