From d2f57fd18e4cfaaf4060285c338a9bf66c7f98d7 Mon Sep 17 00:00:00 2001 From: yangws <1607839436@qq.com> Date: Fri, 26 Jul 2024 12:09:31 +0800 Subject: [PATCH] =?UTF-8?q?add:=E7=8F=AD=E7=BA=A7=E7=AE=A1=E7=90=86?= =?UTF-8?q?=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 6 +- src/renderer/src/api/classManage/index.js | 132 +++++ .../src/components/avatar-handle/index.vue | 75 +++ .../components/classManage/select/index.vue | 23 + src/renderer/src/layout/components/Header.vue | 1 + src/renderer/src/store/modules/delClass.js | 22 + src/renderer/src/views/classManage/aside.vue | 53 ++ .../src/views/classManage/basicGroup.vue | 417 ++++++++++++++++ .../src/views/classManage/classInfo.vue | 80 +++ src/renderer/src/views/classManage/index.vue | 292 +++++++++++ .../src/views/classManage/studentList.vue | 454 ++++++++++++++++++ 11 files changed, 1553 insertions(+), 2 deletions(-) create mode 100644 src/renderer/src/api/classManage/index.js create mode 100644 src/renderer/src/components/avatar-handle/index.vue create mode 100644 src/renderer/src/components/classManage/select/index.vue create mode 100644 src/renderer/src/store/modules/delClass.js create mode 100644 src/renderer/src/views/classManage/aside.vue create mode 100644 src/renderer/src/views/classManage/basicGroup.vue create mode 100644 src/renderer/src/views/classManage/classInfo.vue create mode 100644 src/renderer/src/views/classManage/index.vue create mode 100644 src/renderer/src/views/classManage/studentList.vue diff --git a/package.json b/package.json index 31fd129..8ea8298 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "@electron-toolkit/preload": "^3.0.1", "@electron-toolkit/utils": "^3.0.0", "@element-plus/icons-vue": "^2.3.1", + "@vitejs/plugin-vue-jsx": "^4.0.0", "@vueuse/core": "^10.11.0", "crypto-js": "^4.2.0", "electron-dl-manager": "^3.0.0", @@ -34,8 +35,9 @@ "pinia": "^2.1.7", "pinia-plugin-persistedstate": "^3.2.1", "spark-md5": "^3.0.2", - "vue-cropper": "^1.0.3", - "vue-router": "^4.4.0" + "vue-cropper": "^1.1.4", + "vue-router": "^4.4.0", + "xlsx": "^0.18.5" }, "devDependencies": { "@electron-toolkit/eslint-config": "^1.0.2", diff --git a/src/renderer/src/api/classManage/index.js b/src/renderer/src/api/classManage/index.js new file mode 100644 index 0000000..14a8314 --- /dev/null +++ b/src/renderer/src/api/classManage/index.js @@ -0,0 +1,132 @@ +// 查询evaluation列表 +import request from '@/utils/request' +// 查询班级列表 +export function listClassmain(query) { + return request({ + url: '/education/classmain/list', + method: 'get', + params: query + }) +} +// 查询学生列表 +export function listClassuser(query) { + return request({ + url: '/education/classuser/list', + method: 'get', + params: query + }) +} +// 新增班级 +export function addClassmain(data) { + return request({ + url: '/education/classmain', + method: 'post', + data: data + }) +} +// 查询所有学科的列表 +export function listEvaluation(query) { + return request({ + url: '/education/evaluation/list', + method: 'get', + params: query + }) +} +// 新增小组 +export function addClassgroup(data) { + return request({ + url: '/education/classgroup', + method: 'post', + data: data + }) +} +//班级详情 +export function getClassmain(id) { + return request({ + url: '/education/classmain/' + id, + method: 'get' + }) +} +// 获取小组列表 +export function listClassgroup(query) { + return request({ + url: '/education/classgroup/list', + method: 'get', + params: query + }) +} +//删除小组 +export function delClassgroup(id) { + return request({ + url: '/education/classgroup/' + id, + method: 'delete' + }) +} +//查询小组信息 +export function getClassgroup(id) { + return request({ + url: '/education/classgroup/' + id, + method: 'get' + }) +} +//修改小组信息 +export function updateClassgroup(data) { + return request({ + url: '/education/classgroup', + method: 'put', + data: data + }) +} +//新增学生 +export function addStudentmain(data) { + return request({ + url: '/education/studentmain', + method: 'post', + data: data + }) +} +//修改学生信息 +export function updateStudentmain(data) { + return request({ + url: '/education/studentmain', + method: 'put', + data: data + }) +} +//获取学生信息 +export function getStudentmain(id) { + return request({ + url: '/education/studentmain/' + id, + method: 'get' + }) +} +//删除学生 +export function leaveClass(data) { + return request({ + url: '/education/classuser/leaveClass', + method: 'post', + data: data + }) +} +//删除学生所有数据 +export function removeStudentDataAll(id) { + return request({ + url: '/education/studentmain/removeStudent/' + id, + method: 'post' + }) +} +//删除教室 +export function delClassroom(id) { + return request({ + url: '/education/classroom/' + id, + method: 'delete' + }) +} +//导入学生 +export function addStudentmainByNameArray(data) { + return request({ + url: '/education/studentmain/addByNameArray', + method: 'post', + data: data + }) +} diff --git a/src/renderer/src/components/avatar-handle/index.vue b/src/renderer/src/components/avatar-handle/index.vue new file mode 100644 index 0000000..774955f --- /dev/null +++ b/src/renderer/src/components/avatar-handle/index.vue @@ -0,0 +1,75 @@ + + + + + diff --git a/src/renderer/src/components/classManage/select/index.vue b/src/renderer/src/components/classManage/select/index.vue new file mode 100644 index 0000000..b8959c3 --- /dev/null +++ b/src/renderer/src/components/classManage/select/index.vue @@ -0,0 +1,23 @@ + + + diff --git a/src/renderer/src/layout/components/Header.vue b/src/renderer/src/layout/components/Header.vue index e4642b3..18968b4 100644 --- a/src/renderer/src/layout/components/Header.vue +++ b/src/renderer/src/layout/components/Header.vue @@ -25,6 +25,7 @@