bug修复
This commit is contained in:
1 parent
18b5c1e9e1
commit
654d08c8c8
4 files changed
+42
-48
No files matched your search
@@ -14,7 +14,7 @@ type Field = {
|
||||
maxLength?: number | null;
|
||||
required: boolean;
|
||||
systemField: boolean;
|
||||
optionsJson: string;
|
||||
optionsJson: string | null;
|
||||
widthType: string;
|
||||
sortNo: number;
|
||||
};
|
||||
@@ -146,13 +146,14 @@ export default function InquirySettingsPanel() {
|
||||
const saveForm = async () => {
|
||||
if (!editing) return;
|
||||
try {
|
||||
setNotice("");
|
||||
setSaving(true);
|
||||
await post("/inquiries/forms/save", {
|
||||
...editing,
|
||||
siteCode: SITE,
|
||||
fields: editing.fields.map((field, index) => ({
|
||||
...field,
|
||||
optionsJson: field.optionsJson.trim() || null,
|
||||
optionsJson: field.optionsJson?.trim() || null,
|
||||
sortNo: index,
|
||||
})),
|
||||
});
|
||||
@@ -212,6 +213,7 @@ export default function InquirySettingsPanel() {
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
{notice && <div className="notice">{notice}</div>}
|
||||
<div className="inquiry-editor-layout">
|
||||
<div className="editor-main">
|
||||
<section className="edit-section">
|
||||
|
||||
Reference in new issue
Block a user