Commit e2edebad authored by d.arizona's avatar d.arizona

apdet yuk

parent 902c91fd
...@@ -585,7 +585,7 @@ export default class BalanceSheetMR extends Component { ...@@ -585,7 +585,7 @@ export default class BalanceSheetMR extends Component {
if (response.data.data.result && err === false && errorContrl === false ) { if (response.data.data.result && err === false && errorContrl === false ) {
this.setState({ loading: false, buttonError: false, editable: false, saveDraft: false }) this.setState({ loading: false, buttonError: false, editable: false, saveDraft: false })
} else { } else {
this.setState({ loading: false, buttonError: true, editable: true, saveDraft: true }) this.setState({ loading: false, buttonError: true, editable: true, saveDraft: false })
} }
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => { this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => {
...@@ -734,7 +734,7 @@ export default class BalanceSheetMR extends Component { ...@@ -734,7 +734,7 @@ export default class BalanceSheetMR extends Component {
} }
} else { } else {
let data = tableMeta.rowData[20] == null? [] : tableMeta.rowData[20] let data = tableMeta.rowData[20] == null? [] : tableMeta.rowData[20]
let indexID = data.findIndex((val) => val.item_formula == String(`${item}`)) let indexID = data.findIndex((val) => val.item_formula == String(`@${item}`))
if (indexID !== -1) { if (indexID !== -1) {
// console.log(tableMeta) // console.log(tableMeta)
let valuezz = data[indexID].value let valuezz = data[indexID].value
...@@ -746,14 +746,18 @@ export default class BalanceSheetMR extends Component { ...@@ -746,14 +746,18 @@ export default class BalanceSheetMR extends Component {
let tst = String(item).replace('[M-1]', '') let tst = String(item).replace('[M-1]', '')
let indexID = dataTable2.findIndex((val) => val[21] == tst) let indexID = dataTable2.findIndex((val) => val[21] == tst)
if (indexID !== -1) { if (indexID !== -1) {
let valuezz = dataTable2[indexID][9] let valuezz = dataTable2[indexID][10]
anjay.push(valuezz == "" ? 0 : valuezz) if (item == dataTable2[tableMeta.rowIndex][21]) {
anjay.push(0)
} else {
anjay.push(valuezz == "" ? 0 : valuezz)
}
} }
} else { } else {
let indexID = dataTable2.findIndex((val) => val[21] == item) let indexID = dataTable2.findIndex((val) => val[21] == item)
if (indexID !== -1) { if (indexID !== -1) {
let valuezz = dataTable2[indexID][colIdx] let valuezz = dataTable2[indexID][colIdx]
if (item == dataTable2[tableMeta.rowIndex][24]) { if (item == dataTable2[tableMeta.rowIndex][21]) {
anjay.push(0) anjay.push(0)
} else { } else {
anjay.push(valuezz == "" ? 0 : valuezz) anjay.push(valuezz == "" ? 0 : valuezz)
...@@ -2054,16 +2058,17 @@ export default class BalanceSheetMR extends Component { ...@@ -2054,16 +2058,17 @@ export default class BalanceSheetMR extends Component {
<LightTooltip title={"MTD Explanation vs Prev Month is Reqiured"} arrow> <LightTooltip title={"MTD Explanation vs Prev Month is Reqiured"} arrow>
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
// disabled={false} // disabled={false}
multiline={true}
defaultValue={tableMeta.rowData[17]} defaultValue={tableMeta.rowData[17]}
inputProps={{ inputProps={{
style: { style: {
color: "#5198ea", color: "#5198ea",
textAlign: 'right', textAlign: 'left',
backgroundColor: '#ffac99' backgroundColor: '#ffac99'
} }
}} }}
...@@ -2111,16 +2116,17 @@ export default class BalanceSheetMR extends Component { ...@@ -2111,16 +2116,17 @@ export default class BalanceSheetMR extends Component {
// : // :
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
// disabled={Number(tableMeta.rowData[12]) < this.state.minValue || Number(tableMeta.rowData[12]) > this.state.maxValue ? false : true} // disabled={Number(tableMeta.rowData[12]) < this.state.minValue || Number(tableMeta.rowData[12]) > this.state.maxValue ? false : true}
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
multiline={true}
defaultValue={tableMeta.rowData[17]} defaultValue={tableMeta.rowData[17]}
inputProps={{ inputProps={{
style: { style: {
color: Number(tableMeta.rowData[12]) < this.state.minValue || Number(tableMeta.rowData[12]) > this.state.maxValue ? "#5198ea" : '#5198ea', color: Number(tableMeta.rowData[12]) < this.state.minValue || Number(tableMeta.rowData[12]) > this.state.maxValue ? "#5198ea" : '#5198ea',
textAlign: 'right' textAlign: 'left'
} }
}} }}
onBlur={(event) => { onBlur={(event) => {
...@@ -2147,16 +2153,17 @@ export default class BalanceSheetMR extends Component { ...@@ -2147,16 +2153,17 @@ export default class BalanceSheetMR extends Component {
<LightTooltip title={"MTD Explanation vs MB is Reqiured"} arrow> <LightTooltip title={"MTD Explanation vs MB is Reqiured"} arrow>
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
multiline={true}
// disabled={false} // disabled={false}
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
defaultValue={tableMeta.rowData[18]} defaultValue={tableMeta.rowData[18]}
inputProps={{ inputProps={{
style: { style: {
color: "#5198ea", color: "#5198ea",
textAlign: 'right', textAlign: 'left',
backgroundColor: '#ffac99' backgroundColor: '#ffac99'
} }
}} }}
...@@ -2204,8 +2211,9 @@ export default class BalanceSheetMR extends Component { ...@@ -2204,8 +2211,9 @@ export default class BalanceSheetMR extends Component {
// : // :
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
multiline={true}
placeholder="" placeholder=""
// disabled={Number(tableMeta.rowData[14]) < this.state.minValue || Number(tableMeta.rowData[14]) > this.state.maxValue ? false : true} // disabled={Number(tableMeta.rowData[14]) < this.state.minValue || Number(tableMeta.rowData[14]) > this.state.maxValue ? false : true}
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
...@@ -2213,7 +2221,7 @@ export default class BalanceSheetMR extends Component { ...@@ -2213,7 +2221,7 @@ export default class BalanceSheetMR extends Component {
inputProps={{ inputProps={{
style: { style: {
color: Number(tableMeta.rowData[14]) < this.state.minValue || Number(tableMeta.rowData[14]) > this.state.maxValue ? "#5198ea" : '#5198ea', color: Number(tableMeta.rowData[14]) < this.state.minValue || Number(tableMeta.rowData[14]) > this.state.maxValue ? "#5198ea" : '#5198ea',
textAlign: 'right' textAlign: 'left'
} }
}} }}
onBlur={(event) => { onBlur={(event) => {
...@@ -2240,8 +2248,9 @@ export default class BalanceSheetMR extends Component { ...@@ -2240,8 +2248,9 @@ export default class BalanceSheetMR extends Component {
<LightTooltip title={"MTD Explanation vs RB is Reqiured"} arrow> <LightTooltip title={"MTD Explanation vs RB is Reqiured"} arrow>
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
multiline={true}
placeholder="" placeholder=""
// disabled={false} // disabled={false}
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
...@@ -2249,7 +2258,7 @@ export default class BalanceSheetMR extends Component { ...@@ -2249,7 +2258,7 @@ export default class BalanceSheetMR extends Component {
inputProps={{ inputProps={{
style: { style: {
color: "#5198ea", color: "#5198ea",
textAlign: 'right', textAlign: 'left',
backgroundColor: '#ffac99' backgroundColor: '#ffac99'
} }
}} }}
...@@ -2297,8 +2306,9 @@ export default class BalanceSheetMR extends Component { ...@@ -2297,8 +2306,9 @@ export default class BalanceSheetMR extends Component {
// : // :
<Input <Input
disableUnderline={true} disableUnderline={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
multiline={true}
placeholder="" placeholder=""
// disabled={Number(tableMeta.rowData[16]) < this.state.minValue || Number(tableMeta.rowData[16]) > this.state.maxValue ? false : true} // disabled={Number(tableMeta.rowData[16]) < this.state.minValue || Number(tableMeta.rowData[16]) > this.state.maxValue ? false : true}
disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)} disabled={this.props.isApprover? true : (this.state.get_for == 'view'? true : false)}
...@@ -2306,7 +2316,7 @@ export default class BalanceSheetMR extends Component { ...@@ -2306,7 +2316,7 @@ export default class BalanceSheetMR extends Component {
inputProps={{ inputProps={{
style: { style: {
color: Number(tableMeta.rowData[16]) < this.state.minValue || Number(tableMeta.rowData[16]) > this.state.maxValue ? "#5198ea" : '#5198ea', color: Number(tableMeta.rowData[16]) < this.state.minValue || Number(tableMeta.rowData[16]) > this.state.maxValue ? "#5198ea" : '#5198ea',
textAlign: 'right' textAlign: 'left'
} }
}} }}
onBlur={(event) => { onBlur={(event) => {
...@@ -2583,9 +2593,9 @@ export default class BalanceSheetMR extends Component { ...@@ -2583,9 +2593,9 @@ export default class BalanceSheetMR extends Component {
marginRight: 20 marginRight: 20
}} }}
onClick={() => onClick={() =>
// this.state.saveDraft ? this.state.saveDraft ?
// this.setState({ alert: true, messageAlert: 'Data Incomplete !', tipeAlert: 'error' }) this.setState({ alert: true, messageAlert: 'Data Incomplete !', tipeAlert: 'error' })
// : :
this.state.handleTekTekTek == 1 ? null : this.state.handleTekTekTek == 1 ? null :
this.setState({ handleTekTekTek: 1, loading: true }, () => { this.setState({ handleTekTekTek: 1, loading: true }, () => {
this.backToMonthlyReport('draft') this.backToMonthlyReport('draft')
......
...@@ -627,7 +627,8 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -627,7 +627,8 @@ export default class FixedAssetsMovementMR extends Component {
} }
const handleChange = (value, tableMeta, type) => { const handleChange = (value, tableMeta, type) => {
dataTable2[tableMeta.rowIndex][type] = value let val = String(value).split(",").join("")
dataTable2[tableMeta.rowIndex][type] = val
// console.log(dataTable2) // console.log(dataTable2)
// console.log(dataTable2[tableMeta.rowIndex][type]); // console.log(dataTable2[tableMeta.rowIndex][type]);
// console.log(value); // console.log(value);
...@@ -696,7 +697,7 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -696,7 +697,7 @@ export default class FixedAssetsMovementMR extends Component {
dataTable2[tableMeta.rowIndex][tableMeta.columnIndex + type] = Number(total).toFixed(1) dataTable2[tableMeta.rowIndex][tableMeta.columnIndex + type] = Number(total).toFixed(1)
// console.log(total); // console.log(total);
} }
return total return total * 100
} }
let columns = [ let columns = [
...@@ -885,7 +886,7 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -885,7 +886,7 @@ export default class FixedAssetsMovementMR extends Component {
} }
/> />
</div> : </div> :
tableMeta.rowData[0] === 5 ? tableMeta.rowData[0] === 5 || tableMeta.rowData[0] === 6?
<span style={{ fontSize: 12, textAlign: 'right' }}> <span style={{ fontSize: 12, textAlign: 'right' }}>
<NumberFormat <NumberFormat
thousandSeparator={true} thousandSeparator={true}
...@@ -1099,7 +1100,7 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -1099,7 +1100,7 @@ export default class FixedAssetsMovementMR extends Component {
type="text" type="text"
placeholder="" placeholder=""
disabled={true} disabled={true}
value={Number(tableMeta.rowData[11]).toFixed(1)} value={Number(Number(tableMeta.rowData[11]) * 100).toFixed(1)}
/> />
} }
/> />
...@@ -1143,7 +1144,7 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -1143,7 +1144,7 @@ export default class FixedAssetsMovementMR extends Component {
type="text" type="text"
placeholder="" placeholder=""
disabled={true} disabled={true}
value={Number(tableMeta.rowData[12]).toFixed(1)} value={Number(Number(tableMeta.rowData[12]) * 100).toFixed(1)}
/> />
} }
/> />
...@@ -1182,7 +1183,7 @@ export default class FixedAssetsMovementMR extends Component { ...@@ -1182,7 +1183,7 @@ export default class FixedAssetsMovementMR extends Component {
type="text" type="text"
placeholder="" placeholder=""
disabled={true} disabled={true}
value={Number(tableMeta.rowData[13]).toFixed(1)} value={Number(Number(tableMeta.rowData[13]) * 100).toFixed(1)}
/> />
} }
/> />
......
...@@ -89,7 +89,9 @@ export default class ListOfCreditFacilities extends Component { ...@@ -89,7 +89,9 @@ export default class ListOfCreditFacilities extends Component {
visibleLOCFMR: true, visibleLOCFMR: true,
saveDraft: true, saveDraft: true,
saveComp: true, saveComp: true,
get_for: 'view' get_for: 'view',
updateBy: '-',
notes: "",
} }
this.fileHandler = this.fileHandler.bind(this); this.fileHandler = this.fileHandler.bind(this);
} }
...@@ -98,6 +100,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -98,6 +100,7 @@ export default class ListOfCreditFacilities extends Component {
this.getBankData() this.getBankData()
this.getTypeOfCredit() this.getTypeOfCredit()
this.getSubmission() this.getSubmission()
this.getLatestUpdate()
} }
handleGetFor(type) { handleGetFor(type) {
...@@ -105,6 +108,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -105,6 +108,7 @@ export default class ListOfCreditFacilities extends Component {
this.getBankData() this.getBankData()
this.getTypeOfCredit() this.getTypeOfCredit()
this.getSubmission() this.getSubmission()
this.getLatestUpdate()
}) })
} }
...@@ -197,13 +201,13 @@ export default class ListOfCreditFacilities extends Component { ...@@ -197,13 +201,13 @@ export default class ListOfCreditFacilities extends Component {
item.formula, item.formula,
item.level, item.level,
// item.description, // item.description,
item.locf.borrower_comp_name === null ? "" : item.locf.borrower_comp_name === "" ? "" : item.locf.borrower_comp_name, item.locf.borrower_comp_name === null || item.locf.borrower_comp_name === "" ? this.props.company.company_name : item.locf.borrower_comp_name,
item.locf.bank_name === null ? null : item.locf.bank_name === "" ? null : {value: item.locf.bank_name}, item.locf.bank_name === null ? null : item.locf.bank_name === "" ? null : {value: item.locf.bank_name},
item.locf.type_of_credit === null ? null : item.locf.type_of_credit === "" ? null : {value: item.locf.type_of_credit}, item.locf.type_of_credit === null ? null : item.locf.type_of_credit === "" ? null : {value: item.locf.type_of_credit},
item.locf.remarks === null ? "0.0" : item.locf.remarks === "" ? "0.0" : item.locf.remarks, item.locf.remarks === null ? "0.0" : item.locf.remarks === "" ? "0.0" : item.locf.remarks,
item.locf.loan_maturity_date === null ? "0.0" : item.locf.loan_maturity_date === "" ? "0.0" : item.locf.loan_maturity_date, item.locf.loan_maturity_date === null || item.locf.loan_maturity_date === "" ? null : item.locf.loan_maturity_date,
item.locf.interest === null ? "0.0" : item.locf.interest === "" ? "0.0" : item.locf.interest, item.locf.interest === null || item.locf.interest === "" ? "0.00" : item.locf.interest,
item.locf.currency === null ? "0.0" : item.locf.currency === "" ? "0.0" : item.locf.currency, item.locf.currency === null || item.locf.currency === "" ? "" : item.locf.currency,
item.locf.loan_plafond_amount_ori, item.locf.loan_plafond_amount_ori,
item.locf.loan_plafond_amount_idr === null ? "0.0" : item.locf.loan_plafond_amount_idr === "" ? "0.0" : item.locf.loan_plafond_amount_idr, item.locf.loan_plafond_amount_idr === null ? "0.0" : item.locf.loan_plafond_amount_idr === "" ? "0.0" : item.locf.loan_plafond_amount_idr,
item.locf.out_loan_ki_amount_ori, item.locf.out_loan_ki_amount_ori,
...@@ -236,11 +240,12 @@ export default class ListOfCreditFacilities extends Component { ...@@ -236,11 +240,12 @@ export default class ListOfCreditFacilities extends Component {
item.locf.other_ratio3_financial, item.locf.other_ratio3_financial,
item.locf.other_ratio3_current === null ? "0.0" : item.locf.other_ratio3_current === "" ? "0.0" : item.locf.other_ratio3_current, item.locf.other_ratio3_current === null ? "0.0" : item.locf.other_ratio3_current === "" ? "0.0" : item.locf.other_ratio3_current,
item.locf.other_ratio4_ratio_name, item.locf.other_ratio4_ratio_name,
item.locf.other_ratio4_financia,, item.locf.other_ratio4_financial,
item.locf.other_ratio4_current === null ? "0.0" : item.locf.other_ratio4_current === "" ? "0.0" : item.locf.other_ratio4_current, item.locf.other_ratio4_current === null ? "0.0" : item.locf.other_ratio4_current === "" ? "0.0" : item.locf.other_ratio4_current,
item.notes, item.locf.notes,
// item.per_bs === null ? "0.0" : item.locf.per_bs === "" ? "0.0" : item.locf.per_bs, // item.per_bs === null ? "0.0" : item.locf.per_bs === "" ? "0.0" : item.locf.per_bs,
// item.diff === null ? "0.0" : item.locf.diff === "" ? "0.0" : item.locf.diff, // item.diff === null ? "0.0" : item.locf.diff === "" ? "0.0" : item.locf.diff,
index
], ],
[9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ], [9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ],
) )
...@@ -252,13 +257,13 @@ export default class ListOfCreditFacilities extends Component { ...@@ -252,13 +257,13 @@ export default class ListOfCreditFacilities extends Component {
item.formula, item.formula,
item.level, item.level,
// item.description, // item.description,
item.locf.borrower_comp_name === null ? "0.0" : item.locf.borrower_comp_name === "" ? "0.0" : item.locf.borrower_comp_name, item.locf.borrower_comp_name === null || item.locf.borrower_comp_name === "" ? this.props.company.company_name : item.locf.borrower_comp_name,
item.locf.bank_name === null ? null : item.locf.bank_name === "" ? null : {value: item.locf.bank_name}, item.locf.bank_name === null ? null : item.locf.bank_name === "" ? null : {value: item.locf.bank_name},
item.locf.type_of_credit === null ? null : item.locf.type_of_credit === "" ? null : {value: item.locf.type_of_credit}, item.locf.type_of_credit === null ? null : item.locf.type_of_credit === "" ? null : {value: item.locf.type_of_credit},
item.locf.remarks === null ? "0.0" : item.locf.remarks === "" ? "0.0" : item.locf.remarks, item.locf.remarks === null ? "0.0" : item.locf.remarks === "" ? "0.0" : item.locf.remarks,
item.locf.loan_maturity_date === null ? "0.0" : item.locf.loan_maturity_date === "" ? "0.0" : item.locf.loan_maturity_date, item.locf.loan_maturity_date === null || item.locf.loan_maturity_date === "" ? null : item.locf.loan_maturity_date,
item.locf.interest === null ? "0.0" : item.locf.interest === "" ? "0.0" : item.locf.interest, item.locf.interest === null || item.locf.interest === "" ? "0.00" : item.locf.interest,
item.locf.currency === null ? "0.0" : item.locf.currency === "" ? "0.0" : item.locf.currency, item.locf.currency === null || item.locf.currency === "" ? "" : item.locf.currency,
item.locf.loan_plafond_amount_ori, item.locf.loan_plafond_amount_ori,
item.locf.loan_plafond_amount_idr === null ? "0.0" : item.locf.loan_plafond_amount_idr === "" ? "0.0" : item.locf.loan_plafond_amount_idr, item.locf.loan_plafond_amount_idr === null ? "0.0" : item.locf.loan_plafond_amount_idr === "" ? "0.0" : item.locf.loan_plafond_amount_idr,
item.locf.out_loan_ki_amount_ori, item.locf.out_loan_ki_amount_ori,
...@@ -291,9 +296,10 @@ export default class ListOfCreditFacilities extends Component { ...@@ -291,9 +296,10 @@ export default class ListOfCreditFacilities extends Component {
item.locf.other_ratio3_financial, item.locf.other_ratio3_financial,
item.locf.other_ratio3_current === null ? "0.0" : item.locf.other_ratio3_current === "" ? "0.0" : item.locf.other_ratio3_current, item.locf.other_ratio3_current === null ? "0.0" : item.locf.other_ratio3_current === "" ? "0.0" : item.locf.other_ratio3_current,
item.locf.other_ratio4_ratio_name, item.locf.other_ratio4_ratio_name,
item.locf.other_ratio4_financia,, item.locf.other_ratio4_financial,
item.locf.other_ratio4_current === null ? "0.0" : item.locf.other_ratio4_current === "" ? "0.0" : item.locf.other_ratio4_current, item.locf.other_ratio4_current === null ? "0.0" : item.locf.other_ratio4_current === "" ? "0.0" : item.locf.other_ratio4_current,
item.notes, item.locf.notes,
index
// item.per_bs === null ? "0.0" : item.locf.per_bs === "" ? "0.0" : item.locf.per_bs, // item.per_bs === null ? "0.0" : item.locf.per_bs === "" ? "0.0" : item.locf.per_bs,
// item.diff === null ? "0.0" : item.locf.diff === "" ? "0.0" : item.locf.diff, // item.diff === null ? "0.0" : item.locf.diff === "" ? "0.0" : item.locf.diff,
]) ])
...@@ -310,7 +316,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -310,7 +316,7 @@ export default class ListOfCreditFacilities extends Component {
// console.log(dataTable); // console.log(dataTable);
if (dataTable.length == 0 && this.state.get_for == 'edit') { if (dataTable.length == 0 && this.state.get_for == 'edit') {
dataTable.push( dataTable.push(
[3, "", "", "", "", this.props.company.company_name, null, null, "", this.state.currentDate, "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 0 ], [3, "", "", "", "", this.props.company.company_name, null, null, "", this.state.currentDate, "0.00", "", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 0 ],
[9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ], [9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ],
) )
} }
...@@ -323,6 +329,41 @@ export default class ListOfCreditFacilities extends Component { ...@@ -323,6 +329,41 @@ export default class ListOfCreditFacilities extends Component {
}) })
} }
getLatestUpdate() {
let payload = {
"report_id": this.props.report_id,
"revision": Number(this.props.revision),
"periode": this.props.periode,
"company_id": this.props.company.company_id,
"monthly_report_id": this.props.monthlyReportId,
"months": this.props.month.month_id
}
// console.log(payload)
api.create().getLastestUpdateMR(payload).then(response => {
console.log(JSON.stringify(response))
if (response.data) {
if (response.data.status === "success") {
this.setState({
updateBy: response.data.data.latest_update === null ? '-' : response.data.data.latest_update,
notes: response.data.data.notes_update === null ? "" : response.data.data.notes_update
})
} else {
this.setState({ alert: true, messageAlert: response.data.message, typeAlert: 'warning', loading: false }, () => {
if (response.data.message.includes("Someone Logged In")) {
setTimeout(() => {
localStorage.removeItem(Constant.TOKEN)
window.location.reload();
}, 1000);
}
})
}
} else {
// console.log('brrrrrrrr')
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
}
})
}
fileHandler = (event) => { fileHandler = (event) => {
let fileObj = event let fileObj = event
ExcelRenderer(fileObj, (err, resp) => { ExcelRenderer(fileObj, (err, resp) => {
...@@ -417,9 +458,9 @@ export default class ListOfCreditFacilities extends Component { ...@@ -417,9 +458,9 @@ export default class ListOfCreditFacilities extends Component {
item.bank_name === null ? null : item.bank_name === "" ? null : {value: item.bank_name}, item.bank_name === null ? null : item.bank_name === "" ? null : {value: item.bank_name},
item.type_of_credit === null ? null : item.type_of_credit === "" ? null : {value: item.type_of_credit}, item.type_of_credit === null ? null : item.type_of_credit === "" ? null : {value: item.type_of_credit},
item.remarks === null ? "" : item.remarks === "" ? "" : item.remarks, item.remarks === null ? "" : item.remarks === "" ? "" : item.remarks,
item.loan_maturity_date === null ? this.state.currentDate : item.loan_maturity_date === "" ? this.state.currentDate : item.loan_maturity_date, item.loan_maturity_date === null || item.loan_maturity_date === "" ? null : item.loan_maturity_date,
item.interest === null ? "0" : item.interest === "" ? "0" : item.interest, item.interest === null || item.interest === "" ? "0.00" : item.interest,
item.currency === null ? "0.0" : item.currency === "" ? "0.0" : item.currency, item.currency === null || item.currency === "" ? "" : item.currency,
item.loan_plafond_amount_ori, item.loan_plafond_amount_ori,
item.loan_plafond_amount_idr === null ? "0.0" : item.loan_plafond_amount_idr === "" ? "0.0" : item.loan_plafond_amount_idr, item.loan_plafond_amount_idr === null ? "0.0" : item.loan_plafond_amount_idr === "" ? "0.0" : item.loan_plafond_amount_idr,
item.out_loan_ki_amount_ori, item.out_loan_ki_amount_ori,
...@@ -468,9 +509,9 @@ export default class ListOfCreditFacilities extends Component { ...@@ -468,9 +509,9 @@ export default class ListOfCreditFacilities extends Component {
item.bank_name === null ? null : item.bank_name === "" ? null : {value: item.bank_name}, item.bank_name === null ? null : item.bank_name === "" ? null : {value: item.bank_name},
item.type_of_credit === null ? null : item.type_of_credit === "" ? null : {value: item.type_of_credit}, item.type_of_credit === null ? null : item.type_of_credit === "" ? null : {value: item.type_of_credit},
item.remarks === null ? "" : item.remarks === "" ? "" : item.remarks, item.remarks === null ? "" : item.remarks === "" ? "" : item.remarks,
item.loan_maturity_date === null ? this.state.currentDate : item.loan_maturity_date === "" ? this.state.currentDate : item.loan_maturity_date, item.loan_maturity_date === null || item.loan_maturity_date === "" ? null : item.loan_maturity_date,
item.interest === null ? "0" : item.interest === "" ? "0" : item.interest, item.interest === null || item.interest === "" ? "0.00" : item.interest,
item.currency === null ? "0.0" : item.currency === "" ? "0.0" : item.currency, item.currency === null || item.currency === "" ? "" : item.currency,
item.loan_plafond_amount_ori, item.loan_plafond_amount_ori,
item.loan_plafond_amount_idr === null ? "0.0" : item.loan_plafond_amount_idr === "" ? "0.0" : item.loan_plafond_amount_idr, item.loan_plafond_amount_idr === null ? "0.0" : item.loan_plafond_amount_idr === "" ? "0.0" : item.loan_plafond_amount_idr,
item.out_loan_ki_amount_ori, item.out_loan_ki_amount_ori,
...@@ -519,7 +560,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -519,7 +560,7 @@ export default class ListOfCreditFacilities extends Component {
// console.log(dataTable); // console.log(dataTable);
if (dataTable.length == 0) { if (dataTable.length == 0) {
dataTable.push( dataTable.push(
[3, "", "", "", "", this.props.company.company_name, null, null, "", this.state.currentDate, "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 0 ], [3, "", "", "", "", this.props.company.company_name, null, null, "", this.state.currentDate, "0.00", "", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 0 ],
[9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ], [9, "", "", "", "", "", {value: "Grand Total"}, null, "", "", "", "0", "", "0", "", "0", "", "0", "", "", "0", "0", "0", "0", "0", "", "0", "", "0", "", "0", "", "0", "", "", "", "", "", "", "", "", "", "", "", "", "notes", 999999 ],
) )
} }
...@@ -542,8 +583,12 @@ export default class ListOfCreditFacilities extends Component { ...@@ -542,8 +583,12 @@ export default class ListOfCreditFacilities extends Component {
uploadLOCF(type) { uploadLOCF(type) {
let data = [] let data = []
let error = false
this.state.dataTable.map(i => { this.state.dataTable.map(i => {
if (i[0] == 3) { if (i[0] == 3) {
if (i[6].value == null || i[7].value == null || i[8] == "" || i[9] == "" || i[10] == "" || i[11] == "") {
error = true
}
data.push({ data.push({
"item_report_id": i[1], "item_report_id": i[1],
"borrower_comp_name": i[5], "borrower_comp_name": i[5],
...@@ -571,7 +616,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -571,7 +616,7 @@ export default class ListOfCreditFacilities extends Component {
"current_ratio_current": i[26], "current_ratio_current": i[26],
"der_financial": i[27], "der_financial": i[27],
"der_current": i[28], "der_current": i[28],
"debt_to_ebitda_financial": i[20], "debt_to_ebitda_financial": i[29],
"debt_to_ebitda_current": i[30], "debt_to_ebitda_current": i[30],
"ebitda_to_interest_financial": i[31], "ebitda_to_interest_financial": i[31],
"ebitda_to_interest_current": i[32], "ebitda_to_interest_current": i[32],
...@@ -586,7 +631,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -586,7 +631,7 @@ export default class ListOfCreditFacilities extends Component {
"other_ratio3_current": i[41], "other_ratio3_current": i[41],
"other_ratio4_ratio_name": i[42], "other_ratio4_ratio_name": i[42],
"other_ratio4_financial": i[43], "other_ratio4_financial": i[43],
"other_ratio4_current": i[4], "other_ratio4_current": i[44],
"notes": i[45], "notes": i[45],
}) })
} }
...@@ -604,32 +649,36 @@ export default class ListOfCreditFacilities extends Component { ...@@ -604,32 +649,36 @@ export default class ListOfCreditFacilities extends Component {
"total_loan" : this.state.totalOutStand "total_loan" : this.state.totalOutStand
} }
// console.log(data); // console.log(data);
api.create('UPLOAD').uploadMonthlyReportLOCF(body).then(response => { if (error) {
console.log(response); this.setState({handleTekTekTek: 0, saveDraft: true, saveComp: true, loading: false})
if (response.data) { } else {
if (response.ok) { api.create('UPLOAD').uploadMonthlyReportLOCF(body).then(response => {
if (response.data.status === "success") { console.log(response);
this.props.saveToMonthlyReport() if (response.data) {
// this.props.onClickClose() if (response.ok) {
// this.props.getReport() if (response.data.status === "success") {
this.props.saveToMonthlyReport()
// this.props.onClickClose()
// this.props.getReport()
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => {
if (response.data.message.includes("Someone Logged In")) {
setTimeout(() => {
localStorage.removeItem(Constant.TOKEN)
window.location.reload();
}, 1000);
}
})
// alert(response.data.status)
}
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => { this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
if (response.data.message.includes("Someone Logged In")) {
setTimeout(() => {
localStorage.removeItem(Constant.TOKEN)
window.location.reload();
}, 1000);
}
})
// alert(response.data.status)
} }
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false }) this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
} }
} else { })
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false }) }
}
})
} }
getBankData() { getBankData() {
...@@ -913,8 +962,12 @@ export default class ListOfCreditFacilities extends Component { ...@@ -913,8 +962,12 @@ export default class ListOfCreditFacilities extends Component {
backToMonthlyReport(type) { backToMonthlyReport(type) {
// this.setState({ loading: true }) // this.setState({ loading: true })
let data = [] let data = []
let error = false
this.state.dataTable.map(i => { this.state.dataTable.map(i => {
if (i[0] == 3) { if (i[0] == 3) {
if (i[6].value == null || i[7].value == null || i[8] == "" || i[9] == "" || i[10] == "" || i[11] == "") {
error = true
}
data.push({ data.push({
"item_report_id": i[1], "item_report_id": i[1],
"borrower_comp_name": i[5], "borrower_comp_name": i[5],
...@@ -942,7 +995,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -942,7 +995,7 @@ export default class ListOfCreditFacilities extends Component {
"current_ratio_current": i[26], "current_ratio_current": i[26],
"der_financial": i[27], "der_financial": i[27],
"der_current": i[28], "der_current": i[28],
"debt_to_ebitda_financial": i[20], "debt_to_ebitda_financial": i[29],
"debt_to_ebitda_current": i[30], "debt_to_ebitda_current": i[30],
"ebitda_to_interest_financial": i[31], "ebitda_to_interest_financial": i[31],
"ebitda_to_interest_current": i[32], "ebitda_to_interest_current": i[32],
...@@ -957,7 +1010,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -957,7 +1010,7 @@ export default class ListOfCreditFacilities extends Component {
"other_ratio3_current": i[41], "other_ratio3_current": i[41],
"other_ratio4_ratio_name": i[42], "other_ratio4_ratio_name": i[42],
"other_ratio4_financial": i[43], "other_ratio4_financial": i[43],
"other_ratio4_current": i[4], "other_ratio4_current": i[44],
"notes": i[45], "notes": i[45],
}) })
} }
...@@ -975,24 +1028,28 @@ export default class ListOfCreditFacilities extends Component { ...@@ -975,24 +1028,28 @@ export default class ListOfCreditFacilities extends Component {
"total_loan" : this.state.totalOutStand "total_loan" : this.state.totalOutStand
} }
console.log(payload) console.log(JSON.stringify(payload))
api.create('UPLOAD').createMonthlyReportLOCF(payload).then(response => { if (error) {
console.log(response); this.setState({handleTekTekTek: 0, saveDraft: true, saveComp: true, loading: false})
if (response.data) { } else {
if (response.data.status === "success") { api.create('UPLOAD').createMonthlyReportLOCF(payload).then(response => {
this.props.saveToMonthlyReport() console.log(response);
if (response.data) {
if (response.data.status === "success") {
this.props.saveToMonthlyReport()
} else {
this.setState({ loading: false }, () => {
this.props.saveToMonthlyReport()
})
}
} else { } else {
this.setState({ loading: false }, () => { this.setState({ loading: false }, () => {
this.props.saveToMonthlyReport() // this.getSubmission()
document.body.style.overflow = 'unset';
}) })
} }
} else { })
this.setState({ loading: false }, () => { }
// this.getSubmission()
document.body.style.overflow = 'unset';
})
}
})
} }
...@@ -1071,8 +1128,8 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1071,8 +1128,8 @@ export default class ListOfCreditFacilities extends Component {
null, null,
"", "",
this.state.currentDate, this.state.currentDate,
"", "0.00",
"0", "",
"", "",
"0", "0",
"", "",
...@@ -1106,7 +1163,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1106,7 +1163,7 @@ export default class ListOfCreditFacilities extends Component {
"", "",
"", "",
"", "",
"notez", "",
index], index],
items, items,
) )
...@@ -1133,8 +1190,8 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1133,8 +1190,8 @@ export default class ListOfCreditFacilities extends Component {
null, null,
"", "",
this.state.currentDate, this.state.currentDate,
"", "0.00",
"0", "",
"", "",
"0", "0",
"", "",
...@@ -1168,7 +1225,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1168,7 +1225,7 @@ export default class ListOfCreditFacilities extends Component {
"", "",
"", "",
"", "",
"notez", "",
index], index],
items, items,
) )
...@@ -1372,8 +1429,8 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1372,8 +1429,8 @@ export default class ListOfCreditFacilities extends Component {
null, null,
"", "",
this.state.currentDate, this.state.currentDate,
"", "0.00",
"0", "",
"", "",
"0", "0",
"", "",
...@@ -1407,7 +1464,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1407,7 +1464,7 @@ export default class ListOfCreditFacilities extends Component {
"", "",
"", "",
"", "",
"notez", "",
indexxx], indexxx],
) )
...@@ -1632,11 +1689,29 @@ export default class ListOfCreditFacilities extends Component { ...@@ -1632,11 +1689,29 @@ export default class ListOfCreditFacilities extends Component {
<div style={{ textAlign: 'right', width: 90 }}> <div style={{ textAlign: 'right', width: 90 }}>
{ tableMeta.rowData[0] === 8 || tableMeta.rowData[0] === 9? { tableMeta.rowData[0] === 8 || tableMeta.rowData[0] === 9?
null : null :
<div style={{ padding: 0, margin: 0 }}> // <div style={{ padding: 0, margin: 0 }}>
<textarea disabled={this.state.get_for == 'view'} style={{ borderColor: 'white', width: 96, textAlign: 'center', justifyContent:'center', padding: 0, margin: 0, color: this.state.get_for == 'view'? "black" : "#5198ea" }} type="text" defaultValue={tableMeta.rowData[8]} // <textarea disabled={this.state.get_for == 'view'} style={{ borderColor: 'white', width: 96, textAlign: 'center', justifyContent:'center', padding: 0, margin: 0, color: this.state.get_for == 'view'? "black" : "#5198ea" }} type="text" defaultValue={tableMeta.rowData[8]}
onBlur={(event) => handleChange(event.target.value, tableMeta, tableMeta.columnIndex)} /> // onBlur={(event) => handleChange(event.target.value, tableMeta, tableMeta.columnIndex)} />
</div> // </div>
<Input
disableUnderline={true}
style={{ fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
disabled={tableMeta.rowData[0] == 8 || tableMeta.rowData[0] == 9 || this.state.get_for == 'view'? true : false}
defaultValue={tableMeta.rowData[8]}
// disabled={false}
multiline={true}
inputProps={{
style: {
color: this.state.get_for == 'view'? "black" : "#5198ea",
textAlign: 'center',
backgroundColor: 'white'
}
}}
/>
// <ThemeProvider theme={theme}> // <ThemeProvider theme={theme}>
// <Input // <Input
// disableUnderline={true} // disableUnderline={true}
// style={{color: this.state.get_for == 'view'? "black" : "#5198ea", fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent', marginBottom: -105 }} // style={{color: this.state.get_for == 'view'? "black" : "#5198ea", fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent', marginBottom: -105 }}
...@@ -3335,22 +3410,39 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3335,22 +3410,39 @@ export default class ListOfCreditFacilities extends Component {
<div style={{ textAlign: 'right', width: 90 }}> <div style={{ textAlign: 'right', width: 90 }}>
{tableMeta.rowData[0] === 4 || tableMeta.rowData[0] === 8 || tableMeta.rowData[0] === 9? {tableMeta.rowData[0] === 4 || tableMeta.rowData[0] === 8 || tableMeta.rowData[0] === 9?
null : null :
<ThemeProvider theme={theme}> <Input
<Input disableUnderline={true}
disableUnderline={true} style={{ fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
style={{ color: this.state.get_for == 'view'? "black" : "#5198ea", fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, backgroundColor: 'transparent', marginBottom: -105 }} type="text"
type="text" disabled={this.state.get_for == 'view'? true : false}
placeholder="" defaultValue={tableMeta.rowData[45]}
disabled={this.state.get_for == 'view'} // disabled={false}
defaultValue={tableMeta.rowData[45]} multiline={true}
onBlur={(event) => { inputProps={{
// // // console.log(event.target.value) style: {
// updateValue(event.target.value) color: this.state.get_for == 'view'? "black" : "#5198ea",
handleChange(event.target.value, tableMeta, 45) textAlign: 'center',
// // // console.log(dataTable2) backgroundColor: 'white'
}} }
/> }}
</ThemeProvider> />
// <ThemeProvider theme={theme}>
// <Input
// disableUnderline={true}
// style={{ color: this.state.get_for == 'view'? "black" : "#5198ea", fontSize: 12, textAlign: 'center', borderColor: 'transparent', margin: 0, backgroundColor: 'transparent', marginBottom: -105 }}
// type="text"
// placeholder=""
// disabled={this.state.get_for == 'view'}
// defaultValue={tableMeta.rowData[45]}
// multin
// onBlur={(event) => {
// // // // console.log(event.target.value)
// // updateValue(event.target.value)
// handleChange(event.target.value, tableMeta, 45)
// // // // console.log(dataTable2)
// }}
// />
// </ThemeProvider>
} }
</div> </div>
) )
...@@ -3585,7 +3677,10 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3585,7 +3677,10 @@ export default class ListOfCreditFacilities extends Component {
</MuiThemeProvider>} </MuiThemeProvider>}
</div> </div>
<div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}> <div style={{ display: 'flex', justifyContent: 'space-between', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}>
<div>
<Typography style={{ fontSize: '11px', color: '#4b4b4b', marginTop: 10 }}>Last Updated by : {this.state.updateBy}</Typography>
</div>
<div style={{display: 'flex', flexDirection: 'row'}}> <div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}> <div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography> <Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography>
...@@ -3595,7 +3690,10 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3595,7 +3690,10 @@ export default class ListOfCreditFacilities extends Component {
</div> </div>
</div> </div>
</div> </div>
<div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15}}> <div style={{ display: 'flex', justifyContent: 'space-between', maxWidth: '100%', paddingLeft: 15, paddingRight: 15}}>
<div>
<Typography style={{ fontSize: '11px', color: '#4b4b4b', marginTop: 10 }}>Notes : {this.state.notes}</Typography>
</div>
<div style={{display: 'flex', flexDirection: 'row'}}> <div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}> <div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Diff</Typography> <Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Diff</Typography>
...@@ -3605,6 +3703,26 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3605,6 +3703,26 @@ export default class ListOfCreditFacilities extends Component {
</div> </div>
</div> </div>
</div> </div>
{/* <div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}>
<div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography>
</div>
<div style={{border: '1px solid black', padding: 5, minWidth: 200, display: 'flex', justifyContent: 'flex-end'}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{formatSeparator(this.state.totalOutStand)}</Typography>
</div>
</div>
</div>
<div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15}}>
<div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Diff</Typography>
</div>
<div style={{borderStyle: 'solid', borderWidth: '0px 1px 1px 1px', padding: 5, minWidth: 200, display: 'flex', justifyContent: 'flex-end'}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{formatSeparator(this.state.diff)}</Typography>
</div>
</div>
</div> */}
</div> </div>
<div className="grid grid-2x" style={{ marginTop: 20 }}> <div className="grid grid-2x" style={{ marginTop: 20 }}>
<div className="col-1"> <div className="col-1">
...@@ -3752,7 +3870,34 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3752,7 +3870,34 @@ export default class ListOfCreditFacilities extends Component {
</MuiThemeProvider>} </MuiThemeProvider>}
</div> </div>
<div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}> <div style={{ display: 'flex', justifyContent: 'space-between', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}>
<div>
<Typography style={{ fontSize: '11px', color: '#4b4b4b', marginTop: 10 }}>Last Updated by : {this.state.updateBy}</Typography>
</div>
<div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography>
</div>
<div style={{border: '1px solid black', padding: 5, minWidth: 200, display: 'flex', justifyContent: 'flex-end'}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{formatSeparator(this.state.totalOutStand)}</Typography>
</div>
</div>
</div>
<div style={{ display: 'flex', justifyContent: 'space-between', maxWidth: '100%', paddingLeft: 15, paddingRight: 15}}>
<div>
<Typography style={{ fontSize: '11px', color: '#4b4b4b', marginTop: 10 }}>Notes : {this.state.notes}</Typography>
</div>
<div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Diff</Typography>
</div>
<div style={{borderStyle: 'solid', borderWidth: '0px 1px 1px 1px', padding: 5, minWidth: 200, display: 'flex', justifyContent: 'flex-end'}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{formatSeparator(this.state.diff)}</Typography>
</div>
</div>
</div>
{/* <div style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%', paddingLeft: 15, paddingRight: 15, marginTop: 5}}>
<div style={{display: 'flex', flexDirection: 'row'}}> <div style={{display: 'flex', flexDirection: 'row'}}>
<div style={{padding: 5}}> <div style={{padding: 5}}>
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography> <Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>Total Outstanding Loan</Typography>
...@@ -3771,7 +3916,7 @@ export default class ListOfCreditFacilities extends Component { ...@@ -3771,7 +3916,7 @@ export default class ListOfCreditFacilities extends Component {
<Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{(formatSeparator(this.state.diff))}</Typography> <Typography style={{ fontSize: '11px', color: '#4b4b4b' }}>{(formatSeparator(this.state.diff))}</Typography>
</div> </div>
</div> </div>
</div> </div> */}
</div> </div>
<div className="grid grid-2x" style={{ marginTop: 20 }}> <div className="grid grid-2x" style={{ marginTop: 20 }}>
<div className="col-1"> <div className="col-1">
......
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