Always show allocation formula section for labor/admin detail modal
This commit is contained in:
@@ -6840,11 +6840,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style={{ display: "grid", gap: 18, marginTop: 18 }}>
|
<div style={{ display: "grid", gap: 18, marginTop: 18 }}>
|
||||||
{((lifecycleAccountDetailModal.account_code || "").startsWith("SHARED_") ||
|
{((lifecycleAccountDetailModal.bucket_label || "") === "인건비" || (lifecycleAccountDetailModal.bucket_label || "") === "관리비") && (
|
||||||
Number(lifecycleAccountDetailModal.allocation_source_amount || 0) > 0 ||
|
<section className="mini-card">
|
||||||
Number(lifecycleAccountDetailModal.detail?.allocation_source_amount || 0) > 0) && (
|
<div style={{ fontSize: 16, fontWeight: 700 }}>배부 계산식</div>
|
||||||
<section className="mini-card">
|
|
||||||
<div style={{ fontSize: 16, fontWeight: 700 }}>배부 계산식</div>
|
|
||||||
<div className="subtle" style={{ marginTop: 6 }}>
|
<div className="subtle" style={{ marginTop: 6 }}>
|
||||||
본사관리비 배부원천 x (프로젝트 기준값 / 전체 기준값)
|
본사관리비 배부원천 x (프로젝트 기준값 / 전체 기준값)
|
||||||
</div>
|
</div>
|
||||||
@@ -6866,9 +6864,12 @@
|
|||||||
allocated_amount: lifecycleAccountDetailModal.allocation_result_amount ?? 0,
|
allocated_amount: lifecycleAccountDetailModal.allocation_result_amount ?? 0,
|
||||||
}];
|
}];
|
||||||
const list = rows.length ? rows : fallback;
|
const list = rows.length ? rows : fallback;
|
||||||
return list.map((row, idx) => {
|
if (!list.length || (list.length === 1 && Number(list[0].source_amount || 0) === 0 && Number(list[0].allocated_amount || 0) === 0)) {
|
||||||
const sourceAmount = Number(row.source_amount || 0);
|
return <div key="alloc-empty">해당 계정의 배부 원천 금액이 없어 계산식이 없습니다.</div>;
|
||||||
const allocatedAmount = Number(row.allocated_amount || 0);
|
}
|
||||||
|
return list.map((row, idx) => {
|
||||||
|
const sourceAmount = Number(row.source_amount || 0);
|
||||||
|
const allocatedAmount = Number(row.allocated_amount || 0);
|
||||||
const projectBasisAmount = Number(row.display_project_basis_amount ?? row.project_basis_amount ?? 0);
|
const projectBasisAmount = Number(row.display_project_basis_amount ?? row.project_basis_amount ?? 0);
|
||||||
const totalBasisAmount = Number(row.display_total_basis_amount ?? row.total_basis_amount ?? 0);
|
const totalBasisAmount = Number(row.display_total_basis_amount ?? row.total_basis_amount ?? 0);
|
||||||
return (
|
return (
|
||||||
|
|||||||
Reference in New Issue
Block a user