From 28515318fc2f17b69296779264c8b00b2c8dcb9b Mon Sep 17 00:00:00 2001 From: shijing Date: Wed, 14 Jun 2023 16:37:45 +0800 Subject: [PATCH] =?UTF-8?q?=E8=8F=9C=E5=8D=95=E6=95=B4=E5=90=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/layout/middle.vue | 26 + client/src/router/index.js | 128 ++-- client/src/store/getters.js | 1 + client/src/views/supervisionNew/basicGoal.vue | 179 +++--- client/src/views/supervisionNew/mytask.vue | 500 +++++++++------- .../src/views/supervisionNew/statistics.vue | 30 +- .../views/supervisionNew/statisticsGroup.vue | 562 ++++++++++++++++++ client/src/views/supervisionNew/task.vue | 16 +- client/src/views/supervisionNew/taskdo.vue | 33 +- 9 files changed, 1122 insertions(+), 353 deletions(-) create mode 100644 client/src/layout/middle.vue create mode 100644 client/src/views/supervisionNew/statisticsGroup.vue diff --git a/client/src/layout/middle.vue b/client/src/layout/middle.vue new file mode 100644 index 0000000..e11c465 --- /dev/null +++ b/client/src/layout/middle.vue @@ -0,0 +1,26 @@ + + + + + + \ No newline at end of file diff --git a/client/src/router/index.js b/client/src/router/index.js index bab0062..251e9c5 100644 --- a/client/src/router/index.js +++ b/client/src/router/index.js @@ -5,6 +5,7 @@ Vue.use(Router) /* Layout */ import Layout from '@/layout' +import Middle from '@/layout/middle.vue' /** * Note: sub-menu only appear when route children.length >= 1 @@ -206,6 +207,12 @@ export const asyncRoutes = [ meta: { title: '日常监督', icon: 'table', perms: ['supervision'] }, alwaysShow: true, children: [ + { + path: 'basicGoal', + name: 'basicGoal', + component: () => import('@/views/supervisionNew/basicGoal.vue'), + meta: { title: '年度基础目标' , perms: ['task2']} + }, { path: 'content', name: 'Content', @@ -214,15 +221,45 @@ export const asyncRoutes = [ }, { path: 'task', - name: 'Task', - component: () => import('@/views/supervision/task.vue'), - meta: { title: '报送任务', perms: ['task_view'] } + name: 'task', + component: Middle, + redirect: '/supervision/task', + meta: { title: '报送任务' }, + children: [ + { + path: 'goal', + name: 'goal', + component: () => import('@/views/supervisionNew/task.vue'), + meta: { title: '质量目标' , perms: ['task2']} + }, + { + path: 'other', + name: 'other', + component: () => import('@/views/supervision/task.vue'), + meta: { title: '其他任务'} + }, + ] }, { - path: 'mytask', - name: 'myTask', - component: () => import('@/views/supervision/mytask.vue'), - meta: { title: '我的报送任务', perms: ['record_view'] } + path: 'taskMy', + name: 'taskMy', + component: Middle, + redirect: '/supervision/task', + meta: { title: '我的报送任务' }, + children: [ + { + path: 'myGoalTask', + name: 'myGoalTask', + component: () => import('@/views/supervisionNew/mytask.vue'), + meta: { title: '质量目标', perms: ['task2do']} + }, + { + path: 'myOthertask', + name: 'myOthertask', + component: () => import('@/views/supervision/mytask.vue'), + meta: { title: '其他任务', perms: ['record_view'] } + }, + ] }, { path: 'record', @@ -237,47 +274,12 @@ export const asyncRoutes = [ meta: { title: '报送任务执行', perms: ['task_view'] }, hidden: true }, - ] - }, - { - path: '/supervisionNew', - component: Layout, - redirect: '/supervisionNew/task', - name: 'supervisionNew', - meta: { title: '日常监督(新)', icon: 'table'}, - alwaysShow: true, - children: [ - { - path: 'basicGoal', - name: 'basicGoal', - component: () => import('@/views/supervisionNew/basicGoal.vue'), - meta: { title: '年度基础目标' , perms: ['task2']} - }, - { - path: 'task', - name: 'Task', - component: () => import('@/views/supervisionNew/task.vue'), - meta: { title: '报送任务' , perms: ['task2']} - }, - { - path: 'myTask', - name: 'mytask', - component: () => import('@/views/supervisionNew/mytask.vue'), - meta: { title: '我的任务'} - }, { path: 'statistics', name: 'statistics', component: () => import('@/views/supervisionNew/statistics.vue'), meta: { title: '部门报告'}, }, - { - path: 'mytaskDo', - name: 'mytaskDo', - component: () => import('@/views/supervisionNew/mytaskDo.vue'), - meta: { title: '我的任务执行'}, - hidden: true - }, { path: 'task2do/:id', name: 'Task2do', @@ -287,6 +289,48 @@ export const asyncRoutes = [ }, ] }, + // { + // path: '/supervisionNew', + // component: Layout, + // redirect: '/supervisionNew/task', + // name: 'supervisionNew', + // meta: { title: '日常监督(新)', icon: 'table'}, + // alwaysShow: true, + // children: [ + // { + // path: 'basicGoal', + // name: 'basicGoal', + // component: () => import('@/views/supervisionNew/basicGoal.vue'), + // meta: { title: '年度基础目标' , perms: ['task2']} + // }, + // { + // path: 'task', + // name: 'Task', + // component: () => import('@/views/supervisionNew/task.vue'), + // meta: { title: '报送任务' , perms: ['task2']} + // }, + // { + // path: 'myTask', + // name: 'mytask', + // component: () => import('@/views/supervisionNew/mytask.vue'), + // meta: { title: '我的任务'} + // }, + // { + // path: 'statistics', + // name: 'statistics', + // component: () => import('@/views/supervisionNew/statistics.vue'), + // meta: { title: '部门报告'}, + // }, + // { + // path: 'mytaskDo', + // name: 'mytaskDo', + // component: () => import('@/views/supervisionNew/mytaskDo.vue'), + // meta: { title: '我的任务执行'}, + // hidden: true + // }, + + // ] + // }, { path: '/qualityinspect', component: Layout, diff --git a/client/src/store/getters.js b/client/src/store/getters.js index 1854b88..8563769 100644 --- a/client/src/store/getters.js +++ b/client/src/store/getters.js @@ -3,6 +3,7 @@ const getters = { device: state => state.app.device, token: state => state.user.token, avatar: state => state.user.avatar, + dept: state => state.user.dept, name: state => state.user.name, perms: state => state.user.perms, permission_routes: state => state.permission.routes diff --git a/client/src/views/supervisionNew/basicGoal.vue b/client/src/views/supervisionNew/basicGoal.vue index 31755c6..478ce88 100644 --- a/client/src/views/supervisionNew/basicGoal.vue +++ b/client/src/views/supervisionNew/basicGoal.vue @@ -33,11 +33,11 @@ >