feat(est): print annual item allocations
This commit is contained in:
@@ -6,8 +6,19 @@ const EstForms = (() => {
|
||||
columns: ["Gubun", "Name", "originalCost", "changedCost", "difference"],
|
||||
rows: EstBusiness.costChanges(project),
|
||||
};
|
||||
if (id === "annual-summary") {
|
||||
if (["annual-summary", "annual-items"].includes(id)) {
|
||||
const output = EstBusiness.annual(project, false);
|
||||
if (id === "annual-items")
|
||||
return {
|
||||
columns: ["stage", "Code", "Name", "Size", "Unite", "GN", "NC", "GC", "JC", "SC", "TC"],
|
||||
rows: output.results.flatMap((item) =>
|
||||
item.project.tables.EstMainDat.filter((row) => row.Code || row.Name).map((row) => ({
|
||||
...row,
|
||||
stage: item.name,
|
||||
})),
|
||||
),
|
||||
errors: output.errors,
|
||||
};
|
||||
return {
|
||||
columns: ["Name", "formula", "directCost", "contractCost"],
|
||||
rows: project.annual.map((year, index) => ({
|
||||
@@ -289,6 +300,7 @@ const EstForms = (() => {
|
||||
excludedCost: "제외 금액",
|
||||
originalCost: "당초 금액",
|
||||
changedCost: "변경 금액",
|
||||
stage: "차수",
|
||||
TargetCode: "연결 내역",
|
||||
TU: "단가",
|
||||
TC: "금액",
|
||||
|
||||
Reference in New Issue
Block a user