Pre Merge pull request !272 from zlflying/zl

pull/272/MERGE
zlflying 2025-11-24 08:50:33 +00:00 committed by Gitee
commit e87a4e7681
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 6 additions and 2 deletions

View File

@ -42,7 +42,9 @@ const [Modal, modalApi] = useVbenModal({
} }
modalApi.lock(); modalApi.lock();
// //
const data = (await formApi.getValues()) as PayChannelApi.Channel; // const data = (await formApi.getValues()) as PayChannelApi.Channel;
const data = formData.value as PayChannelApi.Channel;
// data.config = JSON.stringify(data.config);
data.config = JSON.stringify(data.config); data.config = JSON.stringify(data.config);
try { try {
await (data.id ? updateChannel(data) : createChannel(data)); await (data.id ? updateChannel(data) : createChannel(data));
@ -123,8 +125,10 @@ const [Modal, modalApi] = useVbenModal({
config: JSON.parse(res.config), config: JSON.parse(res.config),
}; };
} }
formData.value.config = JSON.stringify(formData.value.config);
// values // values
await formApi.setValues(formData.value); // await formApi.setValues(formData.value);
} finally { } finally {
modalApi.unlock(); modalApi.unlock();
} }