From 21d1f4ec43eaae3c2fe2e27dd9754342439ad615 Mon Sep 17 00:00:00 2001 From: pqhuy1987 Date: Fri, 19 Jun 2026 11:28:18 +0700 Subject: [PATCH] [CLAUDE] FE: PE ngan sach Block A -> bang luoi vien o giong Excel (anh phan hoi) Anh: "giao dien van chua chia cot dung, muon giong file Excel". Block A dang dung flex + spacing (khong co vien doc chia cot) -> chuyen sang
vien o day du: header [Khoan muc | Du an | PRO | CCM] + 5 hang (full / ban hanh / hieu chinh / ghi chu PRO / ghi chu CCM). BudgetCell xep doc (input full o + nut Luu duoi) cho vua cot. BudgetNoteRow -> BudgetNoteCell (td colSpan=3). Mirror fe-user/fe-admin identical. FE-only, build 2 app PASS. Co-Authored-By: Claude Opus 4.8 --- fe-admin/src/components/pe/PeDetailTabs.tsx | 287 ++++++++++---------- fe-user/src/components/pe/PeDetailTabs.tsx | 287 ++++++++++---------- 2 files changed, 300 insertions(+), 274 deletions(-) diff --git a/fe-admin/src/components/pe/PeDetailTabs.tsx b/fe-admin/src/components/pe/PeDetailTabs.tsx index 949d679..1384dc5 100644 --- a/fe-admin/src/components/pe/PeDetailTabs.tsx +++ b/fe-admin/src/components/pe/PeDetailTabs.tsx @@ -1084,36 +1084,40 @@ function BudgetCell({ value, editable, allowNegative = false, saving, onSave }: } const dirty = parse() !== value return ( -
- {allowNegative && ( - - )} - setText(e.target.value.replace(/[^\d.]/g, ''))} - placeholder="0" - className="h-7 min-w-0 px-1.5 text-right font-mono text-[12px]" - /> - +
+
+ {allowNegative && ( + + )} + setText(e.target.value.replace(/[^\d.]/g, ''))} + placeholder="0" + className="h-7 min-w-0 flex-1 px-1.5 text-right font-mono text-[12px]" + /> +
+
+ +
) } -// [S76] Dòng ghi chú phòng (Ghi chú từ PRO / từ CCM) — Textarea editable hoặc text display. -function BudgetNoteRow({ label, editable, value, setValue, savedValue, saving, onSave }: { - label: string +// [S76] Ô ghi chú phòng (Ghi chú từ PRO / từ CCM) — Textarea editable hoặc text display. +// Đặt trong
của bảng ngân sách (không bọc row riêng). +function BudgetNoteCell({ editable, value, setValue, savedValue, saving, onSave }: { editable: boolean value: string setValue: (v: string) => void @@ -1121,30 +1125,26 @@ function BudgetNoteRow({ label, editable, value, setValue, savedValue, saving, o saving: boolean onSave: () => void }) { + if (!editable) { + return ( +
+ {savedValue || } +
+ ) + } return ( -
-
{label}
-
- {editable ? ( -
-