feat(M01): 로직 개선 시험 「텍스트 수식」 컨테이너 — 서버 /text 가 준 줄(비목 묶음 · 소계 · 끝수 · 까닭 옅게)을 그대로 찍음
- `runText` API + 시험 계산 때 `/calc` 와 같은 몸으로 같이 부름 · 화면은 다시 계산하지 않음 - 멈추면 서버 까닭 한 줄 - ORCA 13-4-1 · 12-4 · 12-17-1 소계 합이 호표 계와 같음 · 모달 표 뜸 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016WRFJmmhPi4exAzHgPZHMT
This commit is contained in:
@@ -23,6 +23,7 @@ import {
|
||||
fetchLogicSubs,
|
||||
saveFiles,
|
||||
type CalcLine,
|
||||
type TextAnswer,
|
||||
type ElementBrief,
|
||||
type LogicRow,
|
||||
type LogicSummary,
|
||||
@@ -52,6 +53,7 @@ interface Opened extends Draft {
|
||||
prices: Record<string, ElementBrief | null>;
|
||||
reasons: string[];
|
||||
lines: CalcLine[] | null;
|
||||
text: TextAnswer | null;
|
||||
values: Record<string, string>;
|
||||
}
|
||||
|
||||
@@ -151,6 +153,9 @@ export async function mountM01LogicLab(
|
||||
row: current.row as LogicRow,
|
||||
dirty: () => current.id in drafts,
|
||||
values: current.values,
|
||||
onText: (text) => {
|
||||
current.text = text;
|
||||
},
|
||||
onLines: (lines) => {
|
||||
current.lines = lines;
|
||||
drawEditor();
|
||||
@@ -178,6 +183,7 @@ export async function mountM01LogicLab(
|
||||
reasons: current.reasons,
|
||||
prices: current.prices,
|
||||
lines: current.lines,
|
||||
text: current.text,
|
||||
values: current.values,
|
||||
onChange: touch,
|
||||
calcHost: calc,
|
||||
@@ -194,7 +200,16 @@ export async function mountM01LogicLab(
|
||||
const open = async (id: string, sub: string, key: string): Promise<void> => {
|
||||
const draft = drafts[id];
|
||||
if (draft?.origKey === null) {
|
||||
show({ ...draft, id, original: null, prices: {}, reasons: [], lines: null, values: {} });
|
||||
show({
|
||||
...draft,
|
||||
id,
|
||||
original: null,
|
||||
prices: {},
|
||||
reasons: [],
|
||||
lines: null,
|
||||
text: null,
|
||||
values: {},
|
||||
});
|
||||
return;
|
||||
}
|
||||
try {
|
||||
@@ -210,6 +225,7 @@ export async function mountM01LogicLab(
|
||||
prices: one.prices,
|
||||
reasons: one.reasons,
|
||||
lines: null,
|
||||
text: null,
|
||||
values: {},
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user