diff --git a/PTC/management_dashboard_preview.html b/PTC/management_dashboard_preview.html index 6e1355e..92d9792 100644 --- a/PTC/management_dashboard_preview.html +++ b/PTC/management_dashboard_preview.html @@ -5445,11 +5445,13 @@ const sharedAllocationDetails = Object.values(aggregatedByYearMonth).sort((a, b) => String(a.year_month || "").localeCompare(String(b.year_month || "")) ); + const shouldShowSharedRow = + lifecycleBreakdownModal.label !== "시공비" || sharedAmount > 0; const groupedRows = [ { key: "영업", label: "영업", amount: roleAmount.영업, showWhenZero: false, codes: Array.from(roleCodes.영업) }, { key: "설계", label: "설계", amount: roleAmount.설계, showWhenZero: false, codes: Array.from(roleCodes.설계) }, { key: "시공", label: "시공", amount: roleAmount.시공, showWhenZero: true, codes: Array.from(roleCodes.시공) }, - { key: "공통배분분", label: "공통배분분", amount: sharedAmount, showWhenZero: true, codes: [] }, + { key: "공통배분분", label: "공통배분분", amount: sharedAmount, showWhenZero: shouldShowSharedRow, codes: [] }, ].filter((row) => row.showWhenZero || row.amount > 0); return groupedRows.map((item) => (