refactor: remove departmentId from Class entity

This commit is contained in:
2026-07-09 17:32:37 +08:00
parent 40fef906cd
commit 22bc1876d8
9 changed files with 4 additions and 116 deletions

View File

@@ -236,13 +236,7 @@ const IntegrationConfigPage: React.FC = () => {
const userIds = checkedKeys
.filter((k) => String(k).startsWith('user-'))
.map((k) => String(k).replace('user-', ''));
const deptKeys = checkedKeys.filter((k) => String(k).startsWith('dept-'));
const deptId = deptKeys.length > 0
? Number(String(deptKeys[0]).replace('dept-', ''))
: undefined;
setImporting(true);
await api.post('/classes', { ...values, dingUserIds: userIds, departmentId: deptId });
await api.post('/classes', { ...values, dingUserIds: userIds });
message.success('班级创建成功');
setClassModalOpen(false);
classForm.resetFields();