This commit is contained in:
helen 2024-12-27 15:54:06 +08:00
parent 858c27502c
commit a02c8656c6

View File

@ -293,7 +293,7 @@ const handleUpdate = async (row?: BannedVO) => {
reset();
const _id = row?.id || ids.value[0];
// const res = await getBanned(_id);
// Object.assign(form.value, res.data);
Object.assign(form.value,row);
dialog.visible = true;
dialog.title = `封禁【${row.nickName}`;
};
@ -303,12 +303,13 @@ const submitForm = () => {
bannedFormRef.value?.validate(async (valid: boolean) => {
const arr = {
...form.value,
id: form.value.reportUserId,
type: queryParams.value.type,
message: 0
}
deleteType: 0
};
if (valid) {
buttonLoading.value = true;
await updatemanage(form.value).finally(() => (buttonLoading.value = false));
await updatemanage(arr).finally(() => (buttonLoading.value = false));
proxy?.$modal.msgSuccess('操作成功');
dialog.visible = false;
await getList();
@ -321,10 +322,11 @@ const handleDelete = async (row?: BannedVO) => {
const _ids = row?.contentId;
const _idsname = row?.contentName;
const arr = {
id: row?.contentId,
id: row?.id,
contentId: row?.contentId,
type: queryParams.value.type,
handlingStatus: 1,
message: 1
deleteType: 1
};
const text = queryParams.value.type == 1 ? '笔记名称为“' : queryParams.value.type == 2 ? '活动名称为“' : '评论内容为“';
await proxy?.$modal.confirm('是否确认删除' + text + _idsname + '"的数据项?').finally(() => (loading.value = false));