Commit af8b2c11 authored by faisalhamdi's avatar faisalhamdi

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

parents d6caf99e e985683f
// contents of .env // contents of .env
REACT_APP_URL_MAIN_BE=https://dashboard.triputra-group.com/tia-reporting REACT_APP_URL_MAIN_BE=https://dashboard.triputra-group.com/tia-reporting
REACT_APP_URL_MAIN_FE=/tia-web REACT_APP_URL_MAIN_FE=/web
\ No newline at end of file \ No newline at end of file
...@@ -248,7 +248,7 @@ export default class ProfitLossMR extends Component { ...@@ -248,7 +248,7 @@ export default class ProfitLossMR extends Component {
item.formula, item.formula,
item.level, item.level,
item.description, item.description,
item.profit_loss.notes === "" ? null : item.profit_loss.notes, item.profit_loss.notes == null || item.profit_loss.notes == "null" ? "" : item.profit_loss.notes,
item.profit_loss.rolling_outlook === null ? "0.0" : item.profit_loss.rolling_outlook === "" ? "0.0" : item.profit_loss.rolling_outlook === "0" ? "0.0" : item.profit_loss.rolling_outlook, item.profit_loss.rolling_outlook === null ? "0.0" : item.profit_loss.rolling_outlook === "" ? "0.0" : item.profit_loss.rolling_outlook === "0" ? "0.0" : item.profit_loss.rolling_outlook,
item.profit_loss.master_budget === null ? "0.0" : item.profit_loss.master_budget === "" ? "0.0" : item.profit_loss.master_budget, item.profit_loss.master_budget === null ? "0.0" : item.profit_loss.master_budget === "" ? "0.0" : item.profit_loss.master_budget,
item.profit_loss.rolling_budget === null ? "0.0" : item.profit_loss.rolling_budget === "" ? "0.0" : item.profit_loss.rolling_budget, item.profit_loss.rolling_budget === null ? "0.0" : item.profit_loss.rolling_budget === "" ? "0.0" : item.profit_loss.rolling_budget,
...@@ -289,7 +289,7 @@ export default class ProfitLossMR extends Component { ...@@ -289,7 +289,7 @@ export default class ProfitLossMR extends Component {
item.formula, item.formula,
item.level, item.level,
item.description, item.description,
item.profit_loss.notes === "" ? null : item.profit_loss.notes, item.profit_loss.notes == null || item.profit_loss.notes == "null" ? "" : item.profit_loss.notes,
item.profit_loss.rolling_outlook === null ? "0.0" : item.profit_loss.rolling_outlook === "" ? "0.0" : item.profit_loss.rolling_outlook, item.profit_loss.rolling_outlook === null ? "0.0" : item.profit_loss.rolling_outlook === "" ? "0.0" : item.profit_loss.rolling_outlook,
item.profit_loss.master_budget === null ? "0.0" : item.profit_loss.master_budget === "" ? "0.0" : item.profit_loss.master_budget, item.profit_loss.master_budget === null ? "0.0" : item.profit_loss.master_budget === "" ? "0.0" : item.profit_loss.master_budget,
item.profit_loss.rolling_budget === null ? "0.0" : item.profit_loss.rolling_budget === "" ? "0.0" : item.profit_loss.rolling_budget, item.profit_loss.rolling_budget === null ? "0.0" : item.profit_loss.rolling_budget === "" ? "0.0" : item.profit_loss.rolling_budget,
...@@ -405,31 +405,31 @@ export default class ProfitLossMR extends Component { ...@@ -405,31 +405,31 @@ export default class ProfitLossMR extends Component {
} }
console.log(payload); console.log(payload);
// console.log(JSON.stringify(payload)); // console.log(JSON.stringify(payload));
// api.create('UPLOAD').createMonthlyReportPL(payload).then(response => { api.create('UPLOAD').createMonthlyReportPL(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") {
// if (type == 'submitted') { if (type == 'submitted') {
// this.props.saveToMonthlyReport('PL') this.props.saveToMonthlyReport('PL')
// } else { } else {
// this.props.saveToMonthlyReport() this.props.saveToMonthlyReport()
// } }
// } 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 }, () => {
// document.body.style.overflow = 'unset'; document.body.style.overflow = 'unset';
// if (response.data.message.includes("Someone Logged In")) { if (response.data.message.includes("Someone Logged In")) {
// setTimeout(() => { setTimeout(() => {
// localStorage.removeItem(Constant.TOKEN) localStorage.removeItem(Constant.TOKEN)
// window.location.reload(); window.location.reload();
// }, 1000); }, 1000);
// } }
// this.props.saveToMonthlyReport() this.props.saveToMonthlyReport()
// }) })
// } }
// } 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 })
// } }
// }) })
} }
fileHandler = (event) => { fileHandler = (event) => {
...@@ -487,7 +487,7 @@ export default class ProfitLossMR extends Component { ...@@ -487,7 +487,7 @@ export default class ProfitLossMR extends Component {
item.formula, item.formula,
item.level, item.level,
item.item_report, item.item_report,
item.notes, item.notes == null || item.notes == "null" ? "" : item.notes,
item.rolling_outlook === null ? "" : item.rolling_outlook === "" ? "" : item.rolling_outlook, item.rolling_outlook === null ? "" : item.rolling_outlook === "" ? "" : item.rolling_outlook,
item.master_budget === "" ? "" : item.master_budget, item.master_budget === "" ? "" : item.master_budget,
item.rolling_budget === "" ? "" : item.rolling_budget, item.rolling_budget === "" ? "" : item.rolling_budget,
......
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