|
@@ -77,15 +77,23 @@
|
|
|
try {
|
|
|
const values = await validate();
|
|
|
setModalProps({ confirmLoading: true });
|
|
|
- const postParams = {
|
|
|
- id: unref(modelRef).id,
|
|
|
- isCanBanding: unref(modelRef).isCanBanding === 0 ? 1 : 0,
|
|
|
- remarks: values.remarks,
|
|
|
- };
|
|
|
+ const postParams: Recordable[] = [];
|
|
|
if (unref(isUpdate)) {
|
|
|
+ unref(modelRef).data.forEach((item) => {
|
|
|
+ postParams.push({
|
|
|
+ id: item.id,
|
|
|
+ isCanBanding: values.isCanBanding,
|
|
|
+ remarks: values.remarks,
|
|
|
+ });
|
|
|
+ });
|
|
|
} else {
|
|
|
- await postBaseNewStudentChangeBandingStatus(postParams);
|
|
|
+ postParams.push({
|
|
|
+ id: unref(modelRef).id,
|
|
|
+ isCanBanding: unref(modelRef).isCanBanding === 0 ? 1 : 0,
|
|
|
+ remarks: values.remarks,
|
|
|
+ });
|
|
|
}
|
|
|
+ await postBaseNewStudentChangeBandingStatus(postParams);
|
|
|
|
|
|
createMessage.success('操作成功');
|
|
|
closeModal();
|