From 650cbef2e3bdb1fdf82ca63407664360952055b9 Mon Sep 17 00:00:00 2001 From: wyx Date: Tue, 31 Jan 2023 16:14:16 +0800 Subject: [PATCH 01/13] fix --- src/views/learningpath/LevelAdd.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/views/learningpath/LevelAdd.vue b/src/views/learningpath/LevelAdd.vue index a0035749..b68da92b 100644 --- a/src/views/learningpath/LevelAdd.vue +++ b/src/views/learningpath/LevelAdd.vue @@ -1517,7 +1517,7 @@ export default { previewEndNum: 0, studyStartNum: 0, studyEndNum: 0, - + pjModelVisible: false, faceTeachModelVisible: false, examinationModelVisible: false, evaluationModelVisible: false, @@ -1525,7 +1525,6 @@ export default { commonModelVisible: false, voteModelVisible: false, projectModelVisible: false, - PjModelVisible: false, faceTeachModelVisibleTitle: "", examinationModelVisibleTitle: "", evaluationModelVisibleTitle: "", From 9e972b2ae4dcf29191fc6065e502d0570c4cca94 Mon Sep 17 00:00:00 2001 From: yuping <82253452@qq.com> Date: Tue, 31 Jan 2023 17:27:58 +0800 Subject: [PATCH 02/13] =?UTF-8?q?--fix=20=E6=B7=BB=E5=8A=A0=E5=BD=92?= =?UTF-8?q?=E5=B1=9E=E6=9D=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 3 ++- src/api/request.js | 14 +++++----- .../student/OwnerTableModelStudent.vue | 2 +- src/components/student/TableModelStudent.vue | 27 +++++++++++-------- src/views/projectcenter/ProjectAdd.vue | 1 + src/views/projectcenter/ProjectManage.vue | 2 +- 6 files changed, 28 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index 50050c3a..2b265fab 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,8 @@ "eslintConfig": { "root": true, "env": { - "node": true + "node": true, + "vue/setup-compiler-macros": true }, "extends": [ "plugin:vue/vue3-essential", diff --git a/src/api/request.js b/src/api/request.js index 707aba9f..54e2361d 100644 --- a/src/api/request.js +++ b/src/api/request.js @@ -121,11 +121,17 @@ export function usePage(_url, params, init = true) { }) if (isRef(params)) { - watch(params, () => { + watch(params.value, () => { fetch() }) } + if (isRef(_url)) { + watchEffect(fetch) + } else { + init && fetch() + } + function reset(){ state.data = [] state.loading = false @@ -142,12 +148,6 @@ export function usePage(_url, params, init = true) { }) } - if (isRef(_url)) { - watchEffect(fetch) - } else { - init && fetch() - } - return { ...toRefs(state), fetch, diff --git a/src/components/student/OwnerTableModelStudent.vue b/src/components/student/OwnerTableModelStudent.vue index 24e7d901..6785a73a 100644 --- a/src/components/student/OwnerTableModelStudent.vue +++ b/src/components/student/OwnerTableModelStudent.vue @@ -13,7 +13,7 @@ import {defineProps, ref} from "vue"; import TableModelStudent from "@/components/student/TableModelStudent"; import CommonStudent from "@/components/student/CommonStudent"; -const props = defineProps({ +defineProps({ id: String, type: Number, types: { diff --git a/src/components/student/TableModelStudent.vue b/src/components/student/TableModelStudent.vue index fb7aaa1d..acbf6d72 100644 --- a/src/components/student/TableModelStudent.vue +++ b/src/components/student/TableModelStudent.vue @@ -27,7 +27,7 @@ @@ -36,7 +36,7 @@ @@ -104,7 +104,7 @@ const visiable = ref(false); const initParams = { studentName: "", - page: 1, + pageNo: 1, pageSize: 10, type: props.type || '', types: props.types, @@ -112,6 +112,7 @@ const initParams = { } const searchParams = ref(initParams) +const searchName = ref('') const columns = ref([ { @@ -144,7 +145,7 @@ const columns = ref([ key: "type", width: 30, align: "center", - customRender: ({record: {type}}) => ({4: "查看权", 5: "管理权", 6: "归属权"}[type]), + customRender: ({record: {type}}) => ({4: "查看权", 5: "管理权", 6: "归属权",7: "查看权", 8: "管理权", 9: "归属权",10: "查看权", 11: "管理权", 12: "归属权"}[type]) }, { title: "操作", @@ -156,24 +157,28 @@ const columns = ref([ }, ]) -const {data: studentList, fetch: searchStu, total, loading} = usePage(STUDENT_LIST, searchParams.value) +const {data: studentList, fetch: searchStu, total, loading} = usePage(STUDENT_LIST, searchParams) const stuPagination = computed(() => ({ - total: total, + total:total.value, showSizeChanger: false, - current: searchParams.value.page, + current: searchParams.value.pageNo, pageSize: searchParams.value.pageSize, - onChange: changePagination, + onChange: changePagination })); + const openDrawer = () => { visiable.value = true; }; const changePagination = (page) => { - searchParams.value.page = page; - searchStu(); + searchParams.value.pageNo = page; }; +function search(){ + searchParams.value.studentName = searchName.value + searchParams.value.pageNo = 1 +} function del(id) { Modal.confirm({ title: () => '确定删除?', @@ -194,7 +199,7 @@ const closeDrawer = () => { function reset(){ searchParams.value = initParams - searchStu() + searchName.value='' } watch(visiable, () => { diff --git a/src/views/projectcenter/ProjectAdd.vue b/src/views/projectcenter/ProjectAdd.vue index 3aa6448b..a4c463c9 100644 --- a/src/views/projectcenter/ProjectAdd.vue +++ b/src/views/projectcenter/ProjectAdd.vue @@ -305,6 +305,7 @@ import {storage} from "../../api/storage"; import * as api2 from "../../api/indexAudit"; import {validateName} from "@/api/index1"; import dayjs from "dayjs"; +import {scrollLoad} from "@/api/method"; export default { name: "projectAdd", diff --git a/src/views/projectcenter/ProjectManage.vue b/src/views/projectcenter/ProjectManage.vue index c1e8a74a..74935a36 100644 --- a/src/views/projectcenter/ProjectManage.vue +++ b/src/views/projectcenter/ProjectManage.vue @@ -991,7 +991,7 @@ export default { message.destroy(); return message.warning("项目名称重复,请重新填写"); } - api.createProject(state.projectInfo).then((res) => { + api.createProject(state.projectInfo).then(() => { state.doublepro = false; message.destroy(); message.success("创建成功"); From f30300d326a4b895f44933e7efaee041177169c5 Mon Sep 17 00:00:00 2001 From: yuping <82253452@qq.com> Date: Tue, 31 Jan 2023 17:34:18 +0800 Subject: [PATCH 03/13] =?UTF-8?q?--fix=20=E6=B7=BB=E5=8A=A0=E5=BD=92?= =?UTF-8?q?=E5=B1=9E=E6=9D=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/learningpath/LevelAdd.vue | 1 - 1 file changed, 1 deletion(-) diff --git a/src/views/learningpath/LevelAdd.vue b/src/views/learningpath/LevelAdd.vue index 1bea6d69..4adfac7b 100644 --- a/src/views/learningpath/LevelAdd.vue +++ b/src/views/learningpath/LevelAdd.vue @@ -1388,7 +1388,6 @@ export default { const router = useRouter(); // const store = useStore(); const state = reactive({ - pjModelVisible: false, hasTask: false, stage: [], statess: [], From 7073c4addce267ca073106dbeaea78897f6a8581 Mon Sep 17 00:00:00 2001 From: yuping <82253452@qq.com> Date: Tue, 31 Jan 2023 17:46:59 +0800 Subject: [PATCH 04/13] =?UTF-8?q?--fix=20=E6=B7=BB=E5=8A=A0=E5=BD=92?= =?UTF-8?q?=E5=B1=9E=E6=9D=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/student/OwnerTableModelStudent.vue | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/student/OwnerTableModelStudent.vue b/src/components/student/OwnerTableModelStudent.vue index e7518bf0..8b02aa74 100644 --- a/src/components/student/OwnerTableModelStudent.vue +++ b/src/components/student/OwnerTableModelStudent.vue @@ -37,7 +37,6 @@ defineProps({ default: () => [], }, }); -console.log("props", props.types); const tableModelRef = ref(); function submitCall(flag) { From 08772c14f8ab5165b33228f8f692ea7e21fe7068 Mon Sep 17 00:00:00 2001 From: yuping <82253452@qq.com> Date: Tue, 31 Jan 2023 17:52:03 +0800 Subject: [PATCH 05/13] =?UTF-8?q?--fix=20=E6=B7=BB=E5=8A=A0=E5=BD=92?= =?UTF-8?q?=E5=B1=9E=E6=9D=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/student/TableModelStudent.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/student/TableModelStudent.vue b/src/components/student/TableModelStudent.vue index acbf6d72..0310229e 100644 --- a/src/components/student/TableModelStudent.vue +++ b/src/components/student/TableModelStudent.vue @@ -62,7 +62,7 @@ From 42fe8a07ec05fa314dc7aaf58cbf72314a7db468 Mon Sep 17 00:00:00 2001 From: wyx Date: Tue, 31 Jan 2023 18:42:39 +0800 Subject: [PATCH 06/13] =?UTF-8?q?feat:=E5=A2=9E=E5=8A=A0=E5=AD=A6=E4=B9=A0?= =?UTF-8?q?=E8=B7=AF=E5=BE=84=E5=9B=BE=20=E9=A1=B9=E7=9B=AE=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=A8=A1=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/indexTaskManage.js | 3 + .../drawers/router/RouterProjectManage.vue | 167 +++++++++++------- src/views/learningpath/LevelAdd.vue | 1 - 3 files changed, 102 insertions(+), 69 deletions(-) diff --git a/src/api/indexTaskManage.js b/src/api/indexTaskManage.js index e6690e52..9a9b70ca 100644 --- a/src/api/indexTaskManage.js +++ b/src/api/indexTaskManage.js @@ -43,3 +43,6 @@ export const AttendanceLeave = (obj) => http.post('/stu/task/attendance/leave', // 直播考勤签到 export const AttendanceSign = (obj) => http.post('/stu/task/attendance/sign', obj) + +// 查询项目管理的信息 +export const QueryProjectManageDetail = (obj) => http.post('/project/management/queryProjectManageDetail', obj) \ No newline at end of file diff --git a/src/components/drawers/router/RouterProjectManage.vue b/src/components/drawers/router/RouterProjectManage.vue index 2a968b41..32d2508d 100644 --- a/src/components/drawers/router/RouterProjectManage.vue +++ b/src/components/drawers/router/RouterProjectManage.vue @@ -112,24 +112,25 @@ --> - + + - + \ No newline at end of file diff --git a/src/components/common/DropDown.vue b/src/components/common/DropDown.vue new file mode 100644 index 00000000..efa20e47 --- /dev/null +++ b/src/components/common/DropDown.vue @@ -0,0 +1,20 @@ + + diff --git a/src/components/student/CommonStudent.vue b/src/components/student/CommonStudent.vue index a908f3d8..03f951a3 100644 --- a/src/components/student/CommonStudent.vue +++ b/src/components/student/CommonStudent.vue @@ -11,7 +11,7 @@
- {{ {1: "添加学员", 2: "添加学员", 3: "添加学员",4: "查看权",5: "管理权"}[type] || title }} + {{ {1: "添加学员", 2: "添加学员", 3: "添加学员"}[type] || title }}
-
- -
+
- -
- -
+