|
@@ -207,11 +207,12 @@
|
|
const save = async () => {
|
|
const save = async () => {
|
|
saveLoading.value = true;
|
|
saveLoading.value = true;
|
|
const data = tableData.value.map((item) => item.timePeriodList).flat();
|
|
const data = tableData.value.map((item) => item.timePeriodList).flat();
|
|
- const res = await saveScheduling(data, searchModel.examRoomId).catch(
|
|
|
|
- () => false
|
|
|
|
- );
|
|
|
|
|
|
+ let result = true;
|
|
|
|
+ await saveScheduling(data, searchModel.examRoomId).catch(() => {
|
|
|
|
+ result = false;
|
|
|
|
+ });
|
|
saveLoading.value = false;
|
|
saveLoading.value = false;
|
|
- if (!res) return;
|
|
|
|
|
|
+ if (!result) return;
|
|
Message.success('保存成功!');
|
|
Message.success('保存成功!');
|
|
search();
|
|
search();
|
|
};
|
|
};
|