|
|
|
@ -98,10 +98,9 @@ const DashboardProject = () => {
|
|
|
|
|
useEffect(() => { |
|
|
|
|
let deviation = 0; |
|
|
|
|
if(plannedCost && totalCost){ |
|
|
|
|
console.log("QQQ", [plannedCost, totalCost]); |
|
|
|
|
deviation = plannedCost - totalCost; |
|
|
|
|
} |
|
|
|
|
setRemToComplete(deviation) |
|
|
|
|
setRemToComplete(deviation.toString()) |
|
|
|
|
|
|
|
|
|
}, [plannedCost, totalCost]); |
|
|
|
|
|
|
|
|
@ -597,10 +596,10 @@ const DashboardProject = () => {
|
|
|
|
|
</Col> |
|
|
|
|
<Col span={7} style={{fontSize: 11, fontWeight: 'bold'}}><i className="fa fa-calendar" style={{marginRight:8}}></i>Cost Deviation</Col> |
|
|
|
|
<Col span={5} style={{fontSize: 11}}> |
|
|
|
|
{/* {isReadyProjectDetail && isReadyIntegrationInvoice ? */} |
|
|
|
|
{/* totalCost > plannedCost ? renderFormatRupiah(totalCost-plannedCost, 'Rp.') : 'Rp. 0' */} |
|
|
|
|
{/* : <SingleTextLoader width={100} height={10} /> */} |
|
|
|
|
{/* } */} |
|
|
|
|
{isReadyProjectDetail && isReadyIntegrationInvoice ? |
|
|
|
|
totalCost > plannedCost ? renderFormatRupiah( (totalCost-plannedCost).toString(), 'Rp.') : 'Rp. 0' |
|
|
|
|
: <SingleTextLoader width={100} height={10} /> |
|
|
|
|
} |
|
|
|
|
</Col> |
|
|
|
|
</Row> |
|
|
|
|
<Row> |
|
|
|
|