Commit fa841b04 authored by Riri Novita's avatar Riri Novita

Merge branch 'dev/riri' into 'ENV-DEV'

update130723

See merge request !1896
parents 9d4d0578 6d676279
...@@ -4118,10 +4118,10 @@ export default class SubHolding extends Component { ...@@ -4118,10 +4118,10 @@ export default class SubHolding extends Component {
a.click(); a.click();
} }
} else if (this.state.report.value === 4) { } else if (this.state.report.value === 4) {
let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/db_ratio/export_report?submission_id=${this.state.FRID === null ? "" : this.state.FRID}&&report_id=29&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}` let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/db_ratio/export_report?submission_id=${this.state.FRID === null ? "" : this.state.FRID}&&report_id=29&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&currency_id=${this.state.defaultCurrency.id}`
console.log(url); console.log(url);
let res = await fetch( let res = await fetch(
`${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/db_ratio/export_report?submission_id=${this.state.FRID === null ? "" : this.state.FRID}&&report_id=29&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}` `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/db_ratio/export_report?submission_id=${this.state.FRID === null ? "" : this.state.FRID}&&report_id=29&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&currency_id=${this.state.defaultCurrency.id}`
) )
res = await res.blob() res = await res.blob()
this.setState({ loading: false }) this.setState({ loading: false })
...@@ -4161,10 +4161,10 @@ export default class SubHolding extends Component { ...@@ -4161,10 +4161,10 @@ export default class SubHolding extends Component {
a.click(); a.click();
} }
} else if (this.state.report.value === 6) { } else if (this.state.report.value === 6) {
let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/summary_cash_flow/export_report?submission_id=${this.state.submissionID === null ? "" : this.state.submissionID}&&report_id=6&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&months=${this.state.month.month_id}&&quarter=1` let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/summary_cash_flow/export_report?submission_id=${this.state.submissionID === null ? "" : this.state.submissionID}&&report_id=6&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&months=${this.state.month.month_id}&&quarter=1&&currency_id=${this.state.defaultCurrency.id}`
console.log(url); console.log(url);
let res = await fetch( let res = await fetch(
`${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/summary_cash_flow/export_report?submission_id=${this.state.submissionID === null ? "" : this.state.submissionID}&&report_id=6&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&months=${this.state.month.month_id}&&quarter=1` `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/summary_cash_flow/export_report?submission_id=${this.state.submissionID === null ? "" : this.state.submissionID}&&report_id=6&&company_id=${this.state.company.company_id}&&year=${this.state.periode.periode}&&revision=${this.state.revisionType}&&months=${this.state.month.month_id}&&quarter=1&&currency_id=${this.state.defaultCurrency.id}`
) )
res = await res.blob() res = await res.blob()
this.setState({ loading: false }) this.setState({ loading: false })
......
...@@ -61,6 +61,8 @@ export default class BalanceSheetRO extends Component { ...@@ -61,6 +61,8 @@ export default class BalanceSheetRO extends Component {
defaultCurrencyUpload: this.props.defaultCurrency, defaultCurrencyUpload: this.props.defaultCurrency,
visibleAlertSave: false visibleAlertSave: false
} }
this.fileHandler = this.fileHandler.bind(this);
this.fileHandlerSimulasi = this.fileHandlerSimulasi.bind(this);
} }
componentDidMount() { componentDidMount() {
...@@ -515,6 +517,56 @@ export default class BalanceSheetRO extends Component { ...@@ -515,6 +517,56 @@ export default class BalanceSheetRO extends Component {
}); });
} }
fileHandlerSimulasi = (event) => {
let fileObj = event
ExcelRenderer(fileObj, (err, resp) => {
// console.log(resp)
if (err) {
console.log(err);
}
else {
let isi = resp.rows.slice(3)
console.log(isi);
let payload = []
let reg = /^[-+]?(?:[0-9]+,)*[0-9]+(?:\.[0-9]+)?$/;
isi.map((i, index) => {
if (i.length > 0) {
payload.push({
orders: i[0] === undefined ? "" : String(i[0]).trim(),
item_report_id: i[1] === undefined ? "" : String(i[1]).trim(),
item_report: i[2] === undefined ? "" : String(i[2]).trim(),
"january": i[4] === undefined ? "0" : reg.test(String(i[4])) === false ? "0" : String(i[4]).trim(),
"february": i[5] === undefined ? "0" : reg.test(String(i[5])) === false ? "0" : String(i[5]).trim(),
"march": i[6] === undefined ? "0" : reg.test(String(i[6])) === false ? "0" : String(i[6]).trim(),
"april": i[7] === undefined ? "0" : reg.test(String(i[7])) === false ? "0" : String(i[7]).trim(),
"may": i[8] === undefined ? "0" : reg.test(String(i[8])) === false ? "0" : String(i[8]).trim(),
"june": i[9] === undefined ? "0" : reg.test(String(i[9])) === false ? "0" : String(i[9]).trim(),
"july": i[10] === undefined ? "0" : reg.test(String(i[10])) === false ? "0" : String(i[10]).trim(),
"august": i[11] === undefined ? "0" : reg.test(String(i[11])) === false ? "0" : String(i[11]).trim(),
"september": i[12] === undefined ? "0" : reg.test(String(i[12])) === false ? "0" : String(i[12]).trim(),
"october": i[13] === undefined ? "0" : reg.test(String(i[13])) === false ? "0" : String(i[13]).trim(),
"november": i[14] === undefined ? "0" : reg.test(String(i[14])) === false ? "0" : String(i[14]).trim(),
"december": i[15] === undefined ? "0" : reg.test(String(i[15])) === false ? "0" : String(i[15]).trim(),
"total_december_year": i[16] === undefined ? "0" : reg.test(String(i[16])) === false ? "0" : String(i[16]).trim(),
})
}
})
console.log(payload);
let body = {
company_id: this.props.company.company_id,
periode: this.props.periode,
report_id: this.props.report_id,
balance_sheet: payload,
rolling_outlook_id: this.props.rollingOutlookID,
quartal: this.props.quarter,
status: 'submitted'
}
console.log(body)
this.setState({ payload: body, judul: resp.rows[1][0], judulColumn: resp.rows[0][0] })
}
});
}
checkUpload() { checkUpload() {
let payload = { let payload = {
...this.state.payload, ...this.state.payload,
...@@ -574,6 +626,33 @@ export default class BalanceSheetRO extends Component { ...@@ -574,6 +626,33 @@ export default class BalanceSheetRO extends Component {
}) })
} }
uploadSimulasi() {
let payload = {
...this.state.payload,
currency_id: this.state.defaultCurrencyUpload?.id
}
this.setState({ loading: true, dataTable: [] })
console.log(payload)
api.create().checkUploadMBSimulasi(payload).then(response => {
console.log(response)
if (response.data) {
if (response.ok) {
if (response.data.status === "success") {
this.props.onClickClose()
this.props.refresh('BS')
this.setState({ loading: false })
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: 'Error saving data. Please try again', tipeAlert: 'error', loading: false })
}
})
}
uploadBSRO(type) { uploadBSRO(type) {
let data = [] let data = []
this.state.dataTable.map(i => { this.state.dataTable.map(i => {
...@@ -2532,67 +2611,83 @@ export default class BalanceSheetRO extends Component { ...@@ -2532,67 +2611,83 @@ export default class BalanceSheetRO extends Component {
} }
</div> </div>
<div style={{ width: '50%' }}> <div style={{ width: '50%' }}>
{this.props.isApprover === true || this.state.get_for == 'view' ? <div style={{ display: 'flex', justifyContent: 'flex-end' }}>
null <ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
// <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> <a data-tip={'Upload Simulasi'} data-for="upload">
// <a data-tip={'Download'} data-for="download"> <button
// <button style={{
// style={{ backgroundColor: 'transparent',
// backgroundColor: 'transparent', cursor: 'pointer',
// cursor: 'pointer', borderColor: 'transparent',
// borderColor: 'transparent', margin: 5
// margin: 5 }}
// }} onClick={() => this.setState({ visibleUploadSimulasi: true, buttonDraft: true })}
// onClick={() => >
// this.setState({ loading: true }, () => { <img src={Images.simulasiUpload} style={{ width: 40, height: 40, marginRight: 3 }} />
// this.downloadAllData() </button>
// })} </a>
// > <ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
// <img src={Images.download} /> {this.props.isApprover === true || this.state.get_for == 'view' ?
// </button> null
// </a> // <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
// <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> // <a data-tip={'Download'} data-for="download">
// </div> // <button
: // style={{
<div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> // backgroundColor: 'transparent',
<a data-tip={'Download Template'} data-for="template"> // cursor: 'pointer',
<button // borderColor: 'transparent',
style={{ // margin: 5
backgroundColor: 'transparent', // }}
cursor: 'pointer', // onClick={() =>
borderColor: 'transparent', // this.setState({ loading: true }, () => {
margin: 5 // this.downloadAllData()
}} // })}
onClick={() => this.setState({ loading: true }, () => { // >
this.downloadTemplate() // <img src={Images.download} />
})} // </button>
> // </a>
<img src={Images.template} /> // <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" />
</button> // </div>
</a> :
<ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" /> <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
<a data-tip={'Upload'} data-for="upload"> <a data-tip={'Download Template'} data-for="template">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
cursor: 'pointer', cursor: 'pointer',
borderColor: 'transparent', borderColor: 'transparent',
margin: 5 margin: 5
}} }}
onClick={() => this.setState({ loading: true }, () => { onClick={() => this.setState({ loading: true }, () => {
setTimeout(() => { this.downloadTemplate()
this.setState({ })}
loading: false, >
visibleUpload: true <img src={Images.template} />
}) </button>
}, 300); </a>
})} <ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
> <a data-tip={'Upload'} data-for="upload">
<img src={Images.upload} /> <button
</button> style={{
</a> backgroundColor: 'transparent',
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" /> cursor: 'pointer',
{/* <a data-tip={'Download'} data-for="download"> borderColor: 'transparent',
margin: 5
}}
onClick={() => this.setState({ loading: true }, () => {
setTimeout(() => {
this.setState({
loading: false,
visibleUpload: true
})
}, 300);
})}
>
<img src={Images.upload} />
</button>
</a>
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
{/* <a data-tip={'Download'} data-for="download">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
...@@ -2611,8 +2706,9 @@ export default class BalanceSheetRO extends Component { ...@@ -2611,8 +2706,9 @@ export default class BalanceSheetRO extends Component {
</button> </button>
</a> </a>
<ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> */} <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> */}
</div> </div>
} }
</div>
</div> </div>
</div> </div>
...@@ -2936,6 +3032,47 @@ export default class BalanceSheetRO extends Component { ...@@ -2936,6 +3032,47 @@ export default class BalanceSheetRO extends Component {
</div> </div>
)} )}
{this.state.visibleUploadSimulasi && (
<div className="test app-popup-show">
<div className="popup-content background-white border-radius" style={{ borderRadius: 8 }}>
<div className="popup-panel grid grid-2x main-color" style={{ height: 64, borderTopRightRadius: 8, borderTopLeftRadius: 8 }}>
<div className="col-1" style={{ maxWidth: "inherit", display: 'flex', alignItems: 'center' }}>
<div className="popup-title">
<span style={{ color: '#fff', fontSize: 16, fontWeight: 'bold' }}>Upload File Simulasi</span>
</div>
</div>
<div className="col-2 content-right" style={{ maxWidth: "inherit", alignSelf: 'center' }}>
<button
type="button"
className="btn btn-circle btn-white"
onClick={() => this.setState({ visibleUploadSimulasi: false })}
>
<img src={Images.close} />
</button>
</div>
</div>
<div style={{ padding: '25px 30px' }}>
<UploadFile
type={this.state.uploadStatusSimulasi}
percentage={this.state.percentageSimulasi}
result={this.state.resultSimulasi}
acceptedFiles={["xlsx"]}
onHandle={(dt) => {
this.fileHandlerSimulasi(dt)
this.setState({ uploadStatusSimulasi: 'idle', percentageSimulasi: '0' })
}}
onUpload={() => {
String(this.state.judulColumn).includes("TEMPLATE") && String(this.state.judulColumn).includes("UPLOAD") && String(this.state.judul).includes("ROLLING") && String(this.state.judul).includes("OUTLOOK") && String(this.state.judul).includes("BALANCE") && String(this.state.judul).includes("SHEET") ?
this.uploadSimulasi() :
this.setState({ alert: true, messageAlert: "Invalid Template", tipeAlert: 'warning' })
}}
/>
</div>
<div style={{ padding: '0px 30px 29px', fontSize: 17, color: 'red' }}><b>Warning:</b> Valid currency for uploading data is <b>{this.props.defaultCurrency.id == 1 ? "IDR" : "USD"}</b></div>
</div>
</div>
)}
{this.state.visibleAlertSave && ( {this.state.visibleAlertSave && (
<div className="test app-popup-show"> <div className="test app-popup-show">
<div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}> <div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}>
......
...@@ -286,7 +286,7 @@ export default class CashFlow extends Component { ...@@ -286,7 +286,7 @@ export default class CashFlow extends Component {
this.setState({ alert: false }) this.setState({ alert: false })
} }
olahDataCashFlow(dataTable2) { olahDataCashFlow(dataTable2, trigger) {
console.log(dataTable2) console.log(dataTable2)
let listCF = [] let listCF = []
dataTable2.map((item, index) => { dataTable2.map((item, index) => {
...@@ -339,10 +339,10 @@ export default class CashFlow extends Component { ...@@ -339,10 +339,10 @@ export default class CashFlow extends Component {
}) })
console.log(listCF) console.log(listCF)
this.createCashFlow(listCF) this.createCashFlow(listCF, trigger)
} }
createCashFlow(dbcf) { createCashFlow(dbcf, trigger) {
let payload = { let payload = {
"rolling_outlook_id": this.props.rollingOutlookID, "rolling_outlook_id": this.props.rollingOutlookID,
"company_id": this.props.company.company_id, "company_id": this.props.company.company_id,
...@@ -355,41 +355,45 @@ export default class CashFlow extends Component { ...@@ -355,41 +355,45 @@ export default class CashFlow extends Component {
} }
console.log(dbcf) console.log(dbcf)
console.log(JSON.stringify(payload)) console.log(JSON.stringify(payload))
api.create().createRollingOutlookCF(payload).then(response => { if (trigger === "simulasi") {
console.log(payload);
console.log(response); } else {
// console.log(JSON.stringify(payload)) api.create().createRollingOutlookCF(payload).then(response => {
if (response.data) { console.log(payload);
if (response.data.status === "success") { console.log(response);
this.props.onClickClose() // console.log(JSON.stringify(payload))
this.props.refresh() if (response.data) {
} else { if (response.data.status === "success") {
if (response.data?.message == "Please Set Up Rate Currency First") { this.props.onClickClose()
this.setState({ visibleAlertSave: true, loading: false }) this.props.refresh()
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false, handleDoubleClick: 0 }, () => { if (response.data?.message == "Please Set Up Rate Currency First") {
document.body.style.overflow = 'unset'; this.setState({ visibleAlertSave: true, loading: false })
if (response.data.message.includes("Someone Logged In") || response.data.message.includes("Token Expired")) { } else {
setTimeout(() => { this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false, handleDoubleClick: 0 }, () => {
localStorage.removeItem(Constant.TOKEN) document.body.style.overflow = 'unset';
window.location.reload(); if (response.data.message.includes("Someone Logged In") || response.data.message.includes("Token Expired")) {
}, 1000); setTimeout(() => {
} localStorage.removeItem(Constant.TOKEN)
this.props.onClickClose() window.location.reload();
this.props.refresh() }, 1000);
}) }
this.props.onClickClose()
this.props.refresh()
})
}
} }
// else {
// this.setState({ loading: false, handleDoubleClick: 0 }, () => {
// this.props.onClickClose()
// this.props.refresh()
// })
// }
} else {
this.setState({ loading: false, handleDoubleClick: 0 })
} }
// else { })
// this.setState({ loading: false, handleDoubleClick: 0 }, () => { }
// this.props.onClickClose()
// this.props.refresh()
// })
// }
} else {
this.setState({ loading: false, handleDoubleClick: 0 })
}
})
this.props.onClickClose() this.props.onClickClose()
this.props.refresh() this.props.refresh()
} }
...@@ -2228,7 +2232,7 @@ export default class CashFlow extends Component { ...@@ -2228,7 +2232,7 @@ export default class CashFlow extends Component {
// : // :
this.state.handleDoubleClick == 1 ? null : this.state.handleDoubleClick == 1 ? null :
this.setState({ handleDoubleClick: 1 }, () => { this.setState({ handleDoubleClick: 1 }, () => {
this.olahDataCashFlow(dataTable2) this.olahDataCashFlow(dataTable2, "simulasi")
})} })}
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
......
...@@ -76,6 +76,7 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -76,6 +76,7 @@ export default class CorporateAnnualTargetRO extends Component {
visibleAlertSave: false visibleAlertSave: false
} }
this.fileHandler = this.fileHandler.bind(this); this.fileHandler = this.fileHandler.bind(this);
this.fileHandlerSimulasi = this.fileHandlerSimulasi.bind(this);
} }
componentDidMount() { componentDidMount() {
...@@ -524,6 +525,60 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -524,6 +525,60 @@ export default class CorporateAnnualTargetRO extends Component {
}); });
} }
fileHandlerSimulasi = (event) => {
let fileObj = event
ExcelRenderer(fileObj, (err, resp) => {
// console.log(resp)
if (err) {
// console.log(err);
}
else {
let isi = resp.rows.slice(3)
// console.log(isi);
let payload = []
let reg = /^[-+]?(?:[0-9]+,)*[0-9]+(?:\.[0-9]+)?$/;
isi.map((i, index) => {
if (i.length > 0) {
payload.push({
item_report_id: i[1] === undefined ? 0 : reg.test(String(i[1])) === false ? 0 : String(i[1]).trim(),
item_report: i[2] === undefined ? "" : String(i[2]).trim(),
weight: i[3] === undefined ? "" : String(i[3]).trim(),
uom: i[4] === undefined ? "" : String(i[4]).trim(),
kpi_type: i[5] === undefined ? "" : String(i[5]).trim(),
max_ach: i[6] === undefined ? "" : String(i[6]).toLocaleLowerCase() !== 'unlimited' ? (String(i[6]).includes('%') ? String(i[6].trim()) : String(Number(i[6] * 100) + '%')) : String(i[6]).trim(),
january: i[7] === undefined ? "0.0" : reg.test(String(i[7])) === false ? "0.0" : String(roundMath(Number(i[7]), 1)).trim(),
february: i[8] === undefined ? "0.0" : reg.test(String(i[8])) === false ? "0.0" : String(roundMath(Number(i[8]), 1)).trim(),
march: i[9] === undefined ? "0.0" : reg.test(String(i[9])) === false ? "0.0" : String(roundMath(Number(i[9]), 1)).trim(),
april: i[10] === undefined ? "0.0" : reg.test(String(i[10])) === false ? "0.0" : String(roundMath(Number(i[10]), 1)).trim(),
may: i[11] === undefined ? "0.0" : reg.test(String(i[11])) === false ? "0.0" : String(roundMath(Number(i[11]), 1)).trim(),
june: i[12] === undefined ? "0.0" : reg.test(String(i[12])) === false ? "0.0" : String(roundMath(Number(i[12]), 1)).trim(),
july: i[13] === undefined ? "0.0" : reg.test(String(i[13])) === false ? "0.0" : String(roundMath(Number(i[13]), 1)).trim(),
august: i[14] === undefined ? "0.0" : reg.test(String(i[14])) === false ? "0.0" : String(roundMath(Number(i[14]), 1)).trim(),
september: i[15] === undefined ? "0.0" : reg.test(String(i[15])) === false ? "0.0" : String(roundMath(Number(i[15]), 1)).trim(),
october: i[16] === undefined ? "0.0" : reg.test(String(i[16])) === false ? "0.0" : String(roundMath(Number(i[16]), 1)).trim(),
november: i[17] === undefined ? "0.0" : reg.test(String(i[17])) === false ? "0.0" : String(roundMath(Number(i[17]), 1)).trim(),
december: i[18] === undefined ? "0.0" : reg.test(String(i[18])) === false ? "0.0" : String(roundMath(Number(i[18]), 1)).trim(),
strategic_initiative: i[20] === undefined ? "" : String(i[20]).trim(),
pic: i[21] === undefined ? "" : String(i[21]).trim()
})
}
})
// console.log(payload)
let body = {
company_id: this.props.company.company_id,
periode: this.props.periode,
report_id: this.props.report_id,
cat: payload,
rolling_outlook_id: this.props.rollingOutlookID,
quartal: this.props.quarter,
status: 'submitted'
}
console.log(body)
this.setState({ payload: body, judul: resp.rows[1][0], judulColumn: resp.rows[0][0] })
}
});
}
checkUpload() { checkUpload() {
this.setState({ loading: true, dataTable: [] }) this.setState({ loading: true, dataTable: [] })
let payload = { let payload = {
...@@ -600,6 +655,33 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -600,6 +655,33 @@ export default class CorporateAnnualTargetRO extends Component {
}) })
} }
uploadSimulasi() {
let payload = {
...this.state.payload,
currency_id: this.state.defaultCurrencyUpload?.id
}
this.setState({ loading: true, dataTable: [] })
console.log(payload)
api.create().checkUploadMBSimulasi(payload).then(response => {
console.log(response)
if (response.data) {
if (response.ok) {
if (response.data.status === "success") {
this.props.onClickClose()
this.props.refresh()
this.setState({ loading: false })
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: 'Error saving data. Please try again', tipeAlert: 'error', loading: false })
}
})
}
uploadCATRO(type) { uploadCATRO(type) {
let data = [] let data = []
let stateFR = false let stateFR = false
...@@ -2594,60 +2676,76 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -2594,60 +2676,76 @@ export default class CorporateAnnualTargetRO extends Component {
} }
</div> </div>
<div style={{ width: '50%' }}> <div style={{ width: '50%' }}>
{this.props.isApprover === true || this.state.get_for == 'view' ? <div style={{ display: 'flex', justifyContent: 'flex-end' }}>
null <ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
// <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> <a data-tip={'Upload Simulasi'} data-for="upload">
// <a data-tip={'Download'} data-for="download"> <button
// <button style={{
// style={{ backgroundColor: 'transparent',
// backgroundColor: 'transparent', cursor: 'pointer',
// cursor: 'pointer', borderColor: 'transparent',
// borderColor: 'transparent', margin: 5
// margin: 5 }}
// }} onClick={() => this.setState({ visibleUploadSimulasi: true, buttonDraft: true })}
// onClick={() => >
// this.setState({ loading: true }, () => { <img src={Images.simulasiUpload} style={{ width: 40, height: 40, marginRight: 3 }} />
// setTimeout(() => { </button>
// this.downloadAllData() </a>
// }, 100); <ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
// })} {this.props.isApprover === true || this.state.get_for == 'view' ?
// > null
// <img src={Images.download} /> // <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
// </button> // <a data-tip={'Download'} data-for="download">
// </a> // <button
// <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> // style={{
// </div> // backgroundColor: 'transparent',
: // cursor: 'pointer',
<div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> // borderColor: 'transparent',
<a data-tip={'Download Template'} data-for="template"> // margin: 5
<button // }}
style={{ // onClick={() =>
backgroundColor: 'transparent', // this.setState({ loading: true }, () => {
cursor: 'pointer', // setTimeout(() => {
borderColor: 'transparent', // this.downloadAllData()
margin: 5 // }, 100);
}} // })}
onClick={() => this.downloadTemplate()} // >
> // <img src={Images.download} />
<img src={Images.template} /> // </button>
</button> // </a>
</a> // <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" />
<ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" /> // </div>
<a data-tip={'Upload'} data-for="upload"> :
<button <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
style={{ <a data-tip={'Download Template'} data-for="template">
backgroundColor: 'transparent', <button
cursor: 'pointer', style={{
borderColor: 'transparent', backgroundColor: 'transparent',
margin: 5 cursor: 'pointer',
}} borderColor: 'transparent',
onClick={() => this.setState({ visibleUpload: true })} margin: 5
> }}
<img src={Images.upload} /> onClick={() => this.downloadTemplate()}
</button> >
</a> <img src={Images.template} />
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" /> </button>
{/* <a data-tip={'Download'} data-for="download"> </a>
<ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
<a data-tip={'Upload'} data-for="upload">
<button
style={{
backgroundColor: 'transparent',
cursor: 'pointer',
borderColor: 'transparent',
margin: 5
}}
onClick={() => this.setState({ visibleUpload: true })}
>
<img src={Images.upload} />
</button>
</a>
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
{/* <a data-tip={'Download'} data-for="download">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
...@@ -2666,8 +2764,9 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -2666,8 +2764,9 @@ export default class CorporateAnnualTargetRO extends Component {
</button> </button>
</a> </a>
<ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> */} <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> */}
</div> </div>
} }
</div>
</div> </div>
</div> </div>
...@@ -3003,6 +3102,47 @@ export default class CorporateAnnualTargetRO extends Component { ...@@ -3003,6 +3102,47 @@ export default class CorporateAnnualTargetRO extends Component {
</div> </div>
)} )}
{this.state.visibleUploadSimulasi && (
<div className="test app-popup-show">
<div className="popup-content background-white border-radius" style={{ borderRadius: 8 }}>
<div className="popup-panel grid grid-2x main-color" style={{ height: 64, borderTopRightRadius: 8, borderTopLeftRadius: 8 }}>
<div className="col-1" style={{ maxWidth: "inherit", display: 'flex', alignItems: 'center' }}>
<div className="popup-title">
<span style={{ color: '#fff', fontSize: 16, fontWeight: 'bold' }}>Upload File Simulasi</span>
</div>
</div>
<div className="col-2 content-right" style={{ maxWidth: "inherit", alignSelf: 'center' }}>
<button
type="button"
className="btn btn-circle btn-white"
onClick={() => this.setState({ visibleUploadSimulasi: false })}
>
<img src={Images.close} />
</button>
</div>
</div>
<div style={{ padding: '25px 30px' }}>
<UploadFile
type={this.state.uploadStatusSimulasi}
percentage={this.state.percentageSimulasi}
result={this.state.resultSimulasi}
acceptedFiles={["xlsx"]}
onHandle={(dt) => {
this.fileHandlerSimulasi(dt)
this.setState({ uploadStatusSimulasi: 'idle', percentageSimulasi: '0' })
}}
onUpload={() => {
String(this.state.judulColumn).includes("TEMPLATE") && String(this.state.judulColumn).includes("UPLOAD") && String(this.state.judul).includes("ROLLING") && String(this.state.judul).includes("OUTLOOK") && String(this.state.judul).includes("CAT") ?
this.uploadSimulasi() :
this.setState({ alert: true, messageAlert: "Invalid Template", tipeAlert: 'warning' })
}}
/>
</div>
<div style={{ padding: '0px 30px 29px', fontSize: 17, color: 'red' }}><b>Warning:</b> Valid currency for uploading data is <b>{this.props.defaultCurrency.id == 1 ? "IDR" : "USD"}</b></div>
</div>
</div>
)}
{this.state.visibleAlertSave && ( {this.state.visibleAlertSave && (
<div className="test app-popup-show"> <div className="test app-popup-show">
<div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}> <div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}>
......
...@@ -91,6 +91,7 @@ export default class ProfitLossROO extends Component { ...@@ -91,6 +91,7 @@ export default class ProfitLossROO extends Component {
} }
this.fileHandler = this.fileHandler.bind(this); this.fileHandler = this.fileHandler.bind(this);
this.fileHandlerSimulasi = this.fileHandlerSimulasi.bind(this);
} }
componentDidMount() { componentDidMount() {
...@@ -478,6 +479,56 @@ export default class ProfitLossROO extends Component { ...@@ -478,6 +479,56 @@ export default class ProfitLossROO extends Component {
}); });
} }
fileHandlerSimulasi = (event) => {
let fileObj = event
ExcelRenderer(fileObj, (err, resp) => {
console.log(resp)
if (err) {
console.log(err);
}
else {
let isi = resp.rows.slice(3)
// console.log(resp.rows[2]);
let payload = []
let reg = /^[-+]?(?:[0-9]+,)*[0-9]+(?:\.[0-9]+)?$/;
isi.map((i, index) => {
if (i.length > 0) {
payload.push({
orders: i[0] === undefined ? "" : String(i[0]).trim(),
"item_report_id": i[1] === undefined ? 0 : i[1],
"item_report": i[2] === undefined ? "" : String(i[2]).trim(),
"notes": i[3] === undefined ? "" : reg.test(String(i[3])) === false ? "" : String(i[3]).trim(),
"january": i[5] === undefined ? "0" : reg.test(String(fixNumber(Number(i[5]), 1))) === false ? "0" : String(fixNumber(Number(i[5]), 1)).trim(),
"february": i[6] === undefined ? "0" : reg.test(String(fixNumber(Number(i[6]), 1))) === false ? "0" : String(fixNumber(Number(i[6]), 1)).trim(),
"march": i[7] === undefined ? "0" : reg.test(String(fixNumber(Number(i[7]), 1))) === false ? "0" : String(fixNumber(Number(i[7]), 1)).trim(),
"april": i[8] === undefined ? "0" : reg.test(String(fixNumber(Number(i[8]), 1))) === false ? "0" : String(fixNumber(Number(i[8]), 1)).trim(),
"may": i[9] === undefined ? "0" : reg.test(String(fixNumber(Number(i[9]), 1))) === false ? "0" : String(fixNumber(Number(i[9]), 1)).trim(),
"june": i[10] === undefined ? "0" : reg.test(String(fixNumber(Number(i[10]), 1))) === false ? "0" : String(fixNumber(Number(i[10]), 1)).trim(),
"july": i[11] === undefined ? "0" : reg.test(String(fixNumber(Number(i[11]), 1))) === false ? "0" : String(fixNumber(Number(i[11]), 1)).trim(),
"august": i[12] === undefined ? "0" : reg.test(String(fixNumber(Number(i[12]), 1))) === false ? "0" : String(fixNumber(Number(i[12]), 1)).trim(),
"september": i[13] === undefined ? "0" : reg.test(String(fixNumber(Number(i[13]), 1))) === false ? "0" : String(fixNumber(Number(i[13]), 1)).trim(),
"october": i[14] === undefined ? "0" : reg.test(String(fixNumber(Number(i[14]), 1))) === false ? "0" : String(fixNumber(Number(i[14]), 1)).trim(),
"november": i[15] === undefined ? "0" : reg.test(String(fixNumber(Number(i[15]), 1))) === false ? "0" : String(fixNumber(Number(i[15]), 1)).trim(),
"december": i[16] === undefined ? "0" : reg.test(String(fixNumber(Number(i[16]), 1))) === false ? "0" : String(fixNumber(Number(i[16]), 1)).trim(),
})
}
})
console.log("fileHandler payload", payload)
let body = {
company_id: this.props.company.company_id,
periode: this.props.periode,
report_id: this.props.report_id,
quartal: this.props.quarter,
rolling_outlook_id: this.props.rollingOutlookID,
status: 'submitted',
profit_loss: payload
}
console.log("fileHandler body", body)
this.setState({ payload: body, judul: resp.rows[1][0], judulColumn: resp.rows[0][0] })
}
});
}
checkUpload() { checkUpload() {
let payload = { let payload = {
...this.state.payload, ...this.state.payload,
...@@ -540,6 +591,33 @@ export default class ProfitLossROO extends Component { ...@@ -540,6 +591,33 @@ export default class ProfitLossROO extends Component {
}) })
} }
uploadSimulasi() {
let payload = {
...this.state.payload,
currency_id: this.state.defaultCurrencyUpload?.id
}
this.setState({ loading: true, dataTable: [] })
console.log(payload)
api.create().checkUploadMBSimulasi(payload).then(response => {
console.log(response)
if (response.data) {
if (response.ok) {
if (response.data.status === "success") {
this.props.onClickClose()
this.props.refresh('PL', 'simulasiPL')
this.setState({ loading: false })
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
}
} else {
this.setState({ alert: true, messageAlert: 'Error saving data. Please try again', tipeAlert: 'error', loading: false })
}
})
}
uploadProfitLossRO(type) { uploadProfitLossRO(type) {
let data = [] let data = []
this.state.dataTable.map(i => { this.state.dataTable.map(i => {
...@@ -2329,80 +2407,97 @@ export default class ProfitLossROO extends Component { ...@@ -2329,80 +2407,97 @@ export default class ProfitLossROO extends Component {
} }
</div> </div>
<div style={{ width: '50%' }}> <div style={{ width: '50%' }}>
{this.props.isApprover === true || this.state.get_for == 'view' ? <div style={{ display: 'flex', justifyContent: 'flex-end' }}>
null <ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
// <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> <a data-tip={'Upload Simulasi'} data-for="upload">
// <a data-tip={'Download'} data-for="download"> <button
// <button style={{
// style={{ backgroundColor: 'transparent',
// backgroundColor: 'transparent', cursor: 'pointer',
// cursor: 'pointer', borderColor: 'transparent',
// borderColor: 'transparent', margin: 5
// margin: 5 }}
// }} onClick={() => this.setState({ visibleUploadSimulasi: true, buttonDraft: true })}
// onClick={() => >
// this.setState({ loading: true }, () => { <img src={Images.simulasiUpload} style={{ width: 40, height: 40, marginRight: 3 }} />
// setTimeout(() => { </button>
// this.downloadAllData() </a>
// }, 100); <ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
// })} {this.props.isApprover === true || this.state.get_for == 'view' ?
// > null
// <img src={Images.download} /> // <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
// </button> // <a data-tip={'Download'} data-for="download">
// </a> // <button
// <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> // style={{
// </div> // backgroundColor: 'transparent',
: // cursor: 'pointer',
<div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}> // borderColor: 'transparent',
<a data-tip={'Download Template'} data-for="template"> // margin: 5
<button // }}
style={{ // onClick={() =>
backgroundColor: 'transparent', // this.setState({ loading: true }, () => {
cursor: 'pointer', // setTimeout(() => {
borderColor: 'transparent', // this.downloadAllData()
margin: 5 // }, 100);
}} // })}
onClick={() => this.setState({ loading: true }, () => { // >
this.downloadTemplate() // <img src={Images.download} />
})} // </button>
> // </a>
<img src={Images.template} /> // <ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" />
</button> // </div>
</a> :
<ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" /> <div style={{ justifyContent: 'flex-end', display: 'flex', flexFlow: 'wrap' }}>
<a data-tip={'Upload'} data-for="upload"> <a data-tip={'Download Template'} data-for="template">
<button <button
style={{ style={{
backgroundColor: 'transparent', backgroundColor: 'transparent',
cursor: 'pointer', cursor: 'pointer',
borderColor: 'transparent', borderColor: 'transparent',
margin: 5 margin: 5
}} }}
onClick={() => this.setState({ visibleUpload: true })} onClick={() => this.setState({ loading: true }, () => {
> this.downloadTemplate()
<img src={Images.upload} />
</button>
</a>
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
<a data-tip={'Download'} data-for="download">
<button
style={{
backgroundColor: 'transparent',
cursor: 'pointer',
borderColor: 'transparent',
margin: 5
}}
onClick={() =>
this.setState({ loading: true }, () => {
this.downloadAllData()
})} })}
> >
<img src={Images.download} /> <img src={Images.template} />
</button> </button>
</a> </a>
<ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" /> <ReactTooltip border={true} id="template" place="bottom" type="light" effect="solid" />
</div> <a data-tip={'Upload'} data-for="upload">
} <button
style={{
backgroundColor: 'transparent',
cursor: 'pointer',
borderColor: 'transparent',
margin: 5
}}
onClick={() => this.setState({ visibleUpload: true })}
>
<img src={Images.upload} />
</button>
</a>
<ReactTooltip border={true} id="upload" place="bottom" type="light" effect="solid" />
<a data-tip={'Download'} data-for="download">
<button
style={{
backgroundColor: 'transparent',
cursor: 'pointer',
borderColor: 'transparent',
margin: 5
}}
onClick={() =>
this.setState({ loading: true }, () => {
this.downloadAllData()
})}
>
<img src={Images.download} />
</button>
</a>
<ReactTooltip border={true} id="download" place="bottom" type="light" effect="solid" />
</div>
}
</div>
</div> </div>
</div> </div>
...@@ -2722,6 +2817,48 @@ export default class ProfitLossROO extends Component { ...@@ -2722,6 +2817,48 @@ export default class ProfitLossROO extends Component {
</div> </div>
)} )}
{this.state.visibleUploadSimulasi && (
// alert("Coming Soon...")
<div className="test app-popup-show">
<div className="popup-content background-white border-radius" style={{ borderRadius: 8 }}>
<div className="popup-panel grid grid-2x main-color" style={{ height: 64, borderTopRightRadius: 8, borderTopLeftRadius: 8 }}>
<div className="col-1" style={{ maxWidth: "inherit", display: 'flex', alignItems: 'center' }}>
<div className="popup-title">
<span style={{ color: '#fff', fontSize: 16, fontWeight: 'bold' }}>Upload File Simulasi</span>
</div>
</div>
<div className="col-2 content-right" style={{ maxWidth: "inherit", alignSelf: 'center' }}>
<button
type="button"
className="btn btn-circle btn-white"
onClick={() => this.setState({ visibleUploadSimulasi: false })}
>
<img src={Images.close} />
</button>
</div>
</div>
<div style={{ padding: '25px 30px' }}>
<UploadFile
type={this.state.uploadStatusSimulasi}
percentage={this.state.percentageSimulasi}
result={this.state.resultSimulasi}
acceptedFiles={["xlsx"]}
onHandle={(dt) => {
this.fileHandlerSimulasi(dt)
this.setState({ uploadStatusSimulasi: 'idle', percentageSimulasi: '0' })
}}
onUpload={() => {
String(this.state.judulColumn).includes("TEMPLATE") && String(this.state.judulColumn).includes("UPLOAD") && String(this.state.judul).includes("ROLLING") && String(this.state.judul).includes("OUTLOOK") && String(this.state.judul).includes("PROFIT") && String(this.state.judul).includes("LOSS") ?
this.uploadSimulasi() :
this.setState({ alert: true, messageAlert: "Invalid Template", tipeAlert: 'warning' })
}}
/>
</div>
<div style={{ padding: '0px 30px 29px', fontSize: 17, color: 'red' }}><b>Warning:</b> Valid currency for uploading data is <b>{this.props.defaultCurrency.id == 1 ? "IDR" : "USD"}</b></div>
</div>
</div>
)}
{this.state.visibleAlertSave && ( {this.state.visibleAlertSave && (
<div className="test app-popup-show"> <div className="test app-popup-show">
<div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}> <div className="popup-content border-radius" style={{ background: '#FFF27D', borderRadius: 10, width: 715, height: 238 }}>
......
...@@ -606,7 +606,7 @@ export default class RollingOutlook extends Component { ...@@ -606,7 +606,7 @@ export default class RollingOutlook extends Component {
}) })
} }
getRollingOutlookID(type) { getRollingOutlookID(type, trigger) {
this.setState({ loading: true }) this.setState({ loading: true })
let payload = { let payload = {
"company_id": this.state.company.company_id, "company_id": this.state.company.company_id,
...@@ -653,7 +653,7 @@ export default class RollingOutlook extends Component { ...@@ -653,7 +653,7 @@ export default class RollingOutlook extends Component {
this.getLatestPeriodSubmit() this.getLatestPeriodSubmit()
if (type != undefined && type == 'PL') { if (type != undefined && type == 'PL') {
// this.getCashFlow(type) // this.getCashFlow(type)
this.getPL(type) this.getPL(type, trigger)
} else if (type != undefined && type == 'BS') { } else if (type != undefined && type == 'BS') {
let bodyRatioBs = { let bodyRatioBs = {
"report": 'ratio', "report": 'ratio',
...@@ -1017,7 +1017,7 @@ export default class RollingOutlook extends Component { ...@@ -1017,7 +1017,7 @@ export default class RollingOutlook extends Component {
} }
} }
getPL(type) { getPL(type, trigger) {
let PLID = null let PLID = null
let payloadID = { let payloadID = {
"periode": this.state.periode.periode, "periode": this.state.periode.periode,
...@@ -1128,7 +1128,7 @@ export default class RollingOutlook extends Component { ...@@ -1128,7 +1128,7 @@ export default class RollingOutlook extends Component {
}) })
// console.log(dataTable) // console.log(dataTable)
this.setState({ dbPL: dataTable }, () => { this.setState({ dbPL: dataTable }, () => {
this.olahDataPL(this.state.dbPL, type) this.olahDataPL(this.state.dbPL, type, trigger)
}) })
} else { } else {
this.setState({ dbPL: [], previewTable: false, previewDownload: false }) this.setState({ dbPL: [], previewTable: false, previewDownload: false })
...@@ -1367,7 +1367,7 @@ export default class RollingOutlook extends Component { ...@@ -1367,7 +1367,7 @@ export default class RollingOutlook extends Component {
return total return total
} }
olahDataPL(dbPL, type) { olahDataPL(dbPL, type, trigger) {
dbPL.map((item, index) => { dbPL.map((item, index) => {
if (item[0] == 5 || item[0] == 6 || item[0] == 7) { if (item[0] == 5 || item[0] == 6 || item[0] == 7) {
item[7].value = this.handleValueFormulaDBPL(index, item[7], item, 7) item[7].value = this.handleValueFormulaDBPL(index, item[7], item, 7)
...@@ -1387,11 +1387,11 @@ export default class RollingOutlook extends Component { ...@@ -1387,11 +1387,11 @@ export default class RollingOutlook extends Component {
} }
}) })
this.setState({ dbPL }, () => { this.setState({ dbPL }, () => {
this.payloadPL(type) this.payloadPL(type, trigger)
}) })
} }
payloadPL(type) { payloadPL(type, trigger) {
let listPL = [] let listPL = []
// console.log(this.state.dbPL) // console.log(this.state.dbPL)
this.state.dbPL.map((item, index) => { this.state.dbPL.map((item, index) => {
...@@ -1486,13 +1486,13 @@ export default class RollingOutlook extends Component { ...@@ -1486,13 +1486,13 @@ export default class RollingOutlook extends Component {
if (type != undefined) { if (type != undefined) {
if (type == 'PL') { if (type == 'PL') {
console.log('tarik sis') console.log('tarik sis')
this.createDBPL() this.createDBPL(trigger)
} }
} }
}) })
} }
createDBPL() { createDBPL(trigger) {
let payload = { let payload = {
// "submission_id": this.state.submissionID, // "submission_id": this.state.submissionID,
"company_id": this.state.company.company_id, "company_id": this.state.company.company_id,
...@@ -1506,10 +1506,14 @@ export default class RollingOutlook extends Component { ...@@ -1506,10 +1506,14 @@ export default class RollingOutlook extends Component {
} }
console.log(this.state.dbPL) console.log(this.state.dbPL)
// console.log(JSON.stringify(payload)) // console.log(JSON.stringify(payload))
api.create().createDBPLRO(payload).then((res) => { if (trigger === 'simulasiPL') {
console.log(res)
this.setState({ loading: false }) } else {
}) api.create().createDBPLRO(payload).then((res) => {
console.log(res)
this.setState({ loading: false })
})
}
} }
handleApproveAdmin() { handleApproveAdmin() {
......
This source diff could not be displayed because it is too large. You can view the blob instead.
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