Commit 575df2c7 authored by Deni Rinaldi's avatar Deni Rinaldi

kes plow monli riport

parent 58116afd
...@@ -18,6 +18,7 @@ import MuiAlert from '@material-ui/lab/Alert'; ...@@ -18,6 +18,7 @@ import MuiAlert from '@material-ui/lab/Alert';
import Constant from '../library/Constant'; import Constant from '../library/Constant';
import OperatingIndicatorMR from './MonthlyReport/OperatingIndicatorMR'; import OperatingIndicatorMR from './MonthlyReport/OperatingIndicatorMR';
import CorporateAnnualTargetMR from './MonthlyReport/CorporateAnnualTargetMR'; import CorporateAnnualTargetMR from './MonthlyReport/CorporateAnnualTargetMR';
import CashFlowMR from './MonthlyReport/CashFlowMR';
var ct = require("../library/CustomTable"); var ct = require("../library/CustomTable");
const getMuiTheme = () => createMuiTheme(ct.customTable()); const getMuiTheme = () => createMuiTheme(ct.customTable());
...@@ -45,6 +46,7 @@ export default class MonthlyReport extends Component { ...@@ -45,6 +46,7 @@ export default class MonthlyReport extends Component {
visibleFAM: false, visibleFAM: false,
visibleCAT: false, visibleCAT: false,
visibleOI: false, visibleOI: false,
visibleCF: false,
listAttachment: [], listAttachment: [],
visibleUpload: false, visibleUpload: false,
lastRevision: 0, lastRevision: 0,
...@@ -471,7 +473,7 @@ export default class MonthlyReport extends Component { ...@@ -471,7 +473,7 @@ export default class MonthlyReport extends Component {
}) })
} }
saveToMonthlyReport(){ saveToMonthlyReport() {
this.setState({ this.setState({
visibleMonthlyReport: true, visibleMonthlyReport: true,
visibleBS: false, visibleBS: false,
...@@ -481,7 +483,7 @@ export default class MonthlyReport extends Component { ...@@ -481,7 +483,7 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: false, visibleLOCF: false,
visibleOI: false, visibleOI: false,
}, ()=> { }, () => {
this.getMonthlyReportID() this.getMonthlyReportID()
}) })
} }
...@@ -503,6 +505,7 @@ export default class MonthlyReport extends Component { ...@@ -503,6 +505,7 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: false, visibleLOCF: false,
visibleOI: false, visibleOI: false,
visibleCF: false,
}) })
} else if (item === 'Profit Loss') { } else if (item === 'Profit Loss') {
this.setState({ this.setState({
...@@ -514,6 +517,7 @@ export default class MonthlyReport extends Component { ...@@ -514,6 +517,7 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: false, visibleLOCF: false,
visibleOI: false, visibleOI: false,
visibleCF: false,
}) })
} else if (item === 'Tax Planning') { } else if (item === 'Tax Planning') {
this.setState({ this.setState({
...@@ -525,6 +529,7 @@ export default class MonthlyReport extends Component { ...@@ -525,6 +529,7 @@ export default class MonthlyReport extends Component {
visibleTP: true, visibleTP: true,
visibleLOCF: false, visibleLOCF: false,
visibleOI: false, visibleOI: false,
visibleCF: false,
}) })
} else if (item === 'Fixed Assets Movement') { } else if (item === 'Fixed Assets Movement') {
this.setState({ this.setState({
...@@ -547,6 +552,7 @@ export default class MonthlyReport extends Component { ...@@ -547,6 +552,7 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: false, visibleLOCF: false,
visibleOI: false, visibleOI: false,
visibleCF: false,
}) })
} else if (item === 'List of Credit Facilities') { } else if (item === 'List of Credit Facilities') {
this.setState({ this.setState({
...@@ -558,6 +564,7 @@ export default class MonthlyReport extends Component { ...@@ -558,6 +564,7 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: true, visibleLOCF: true,
visibleOI: false, visibleOI: false,
visibleCF: false,
}) })
} else if (item === 'Operating Indicator') { } else if (item === 'Operating Indicator') {
this.setState({ this.setState({
...@@ -569,6 +576,19 @@ export default class MonthlyReport extends Component { ...@@ -569,6 +576,19 @@ export default class MonthlyReport extends Component {
visibleTP: false, visibleTP: false,
visibleLOCF: false, visibleLOCF: false,
visibleOI: true, visibleOI: true,
visibleCF: false,
})
} else if (item === 'Cash Flow') {
this.setState({
visibleMonthlyReport: false,
visibleBS: false,
visiblePL: false,
visibleCAT: false,
visibleFAM: false,
visibleTP: false,
visibleLOCF: false,
visibleOI: false,
visibleCF: true,
}) })
} }
}) })
...@@ -645,7 +665,7 @@ export default class MonthlyReport extends Component { ...@@ -645,7 +665,7 @@ export default class MonthlyReport extends Component {
`https://tia.eksad.com/tia-reporting-dev/public/transaction/monthly_report/download_attachment?fileName=${fileurl}&&fileType=${fileType}` `https://tia.eksad.com/tia-reporting-dev/public/transaction/monthly_report/download_attachment?fileName=${fileurl}&&fileType=${fileType}`
) )
res = await res.blob() res = await res.blob()
this.setState({ loading: false }, ()=> { this.setState({ loading: false }, () => {
document.body.style.overflow = 'unset'; document.body.style.overflow = 'unset';
}) })
if (res.size > 0) { if (res.size > 0) {
...@@ -1088,7 +1108,7 @@ export default class MonthlyReport extends Component { ...@@ -1088,7 +1108,7 @@ export default class MonthlyReport extends Component {
month={this.state.month} month={this.state.month}
saveToMonthlyReport={this.saveToMonthlyReport.bind(this)} saveToMonthlyReport={this.saveToMonthlyReport.bind(this)}
onClickClose={() => this.setState({ visibleTP: false, visibleMonthlyReport: true })} onClickClose={() => this.setState({ visibleTP: false, visibleMonthlyReport: true })}
// getReport={this.getCompanyActive.bind(this)} // getReport={this.getCompanyActive.bind(this)}
/> />
)} )}
{this.state.visibleFAM && ( {this.state.visibleFAM && (
...@@ -1151,6 +1171,21 @@ export default class MonthlyReport extends Component { ...@@ -1151,6 +1171,21 @@ export default class MonthlyReport extends Component {
onClickClose={() => this.setState({ visibleOI: false, visibleMonthlyReport: true })} onClickClose={() => this.setState({ visibleOI: false, visibleMonthlyReport: true })}
/> />
)} )}
{this.state.visibleCF && (
<CashFlowMR
open={this.props.open}
report_id={this.state.report_id}
height={this.props.height}
width={this.props.width}
company={this.state.company}
revision={this.state.revisionTable}
periode={this.state.periode.periode}
monthlyReportId={this.state.monthlyReportId}
month={this.state.month}
onClickClose={() => this.setState({ visibleCF: false, visibleMonthlyReport: true })}
/>
)}
</div > </div >
); );
} }
......
This diff is collapsed.
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