[feat] negosium: 협상완료 부가정보 수취·표시·잠금 + VAT 표기 통일

- 완료 요약 카드(투찰/협상 결과)에 부가정보·의견을 항상 구조로 표시, 미입력 필드는 '-'
- 협상 리스트 부가정보를 완전 읽기전용으로 잠금 — 입력은 완료 챗 마무리에서만
- 어드민 협상상세(현황·챗 탭)에 협력사 의견(custom.opinion) 노출
- 협상 화면 VAT 표기를 회사설정(vat_yn) 기준으로 통일 — hidden이면 라벨 생략
This commit is contained in:
minaChoi committed 2026-07-30 08:31:16 +09:00
1 parent 671904c762
commit 9dca78dc72
10 files changed
+115 -40

No files matched your search

@@ -80,10 +80,15 @@ export function ChatTab({
// 협상완료 부가정보(sessions.custom) — 공급사가 타결 후 입력. 라벨은 회사 설정(session_fields)에서.
const { settings } = useCompanySettings();
const sessionFields = settings.session_fields ?? [];
const extraRows = (sd: SessionData | null) =>
sessionFields
.map((f) => ({ label: f.label, value: (sd?.custom as Record<string, unknown> | undefined)?.[f.key] }))
const extraRows = (sd: SessionData | null) => {
const custom = sd?.custom as Record<string, unknown> | undefined;
const rows = sessionFields
.map((f) => ({ label: f.label, value: custom?.[f.key] }))
.filter((r) => r.value !== undefined && r.value !== null && r.value !== '');
// 의견은 회사설정과 무관한 내장 공통 필드(custom.opinion) — 값 있으면 항상 표시
if (custom?.opinion) rows.push({ label: '의견', value: custom.opinion });
return rows;
};
return (
<div className="h-[500px] border border-border rounded-lg overflow-hidden bg-card flex">
{/* Sessions list */}
@@ -42,10 +42,15 @@ export function SessionsStatusTab({
const { settings } = useCompanySettings();
const sessionFields = settings.session_fields ?? [];
const [extraSession, setExtraSession] = useState<SessionView | null>(null);
const extraRows = (sv: SessionView | null) =>
sessionFields
.map((f) => ({ label: f.label, value: (sv?.custom as Record<string, unknown> | undefined)?.[f.key] }))
const extraRows = (sv: SessionView | null) => {
const custom = sv?.custom as Record<string, unknown> | undefined;
const rows = sessionFields
.map((f) => ({ label: f.label, value: custom?.[f.key] }))
.filter((r) => r.value !== undefined && r.value !== null && r.value !== '');
// 의견은 회사설정과 무관한 내장 공통 필드(custom.opinion) — 값 있으면 항상 표시
if (custom?.opinion) rows.push({ label: '의견', value: custom.opinion });
return rows;
};
const [sendingAll, setSendingAll] = useState(false);
const [sendingId, setSendingId] = useState<string | null>(null);
const [selectedWinnerId, setSelectedWinnerId] = useState<string | null>(null);