From 8adc27958d841e164480d0ac99dc43001ed99ddf Mon Sep 17 00:00:00 2001 From: zhl Date: Fri, 16 Apr 2021 15:19:21 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A2=98=E5=BA=93=E7=9A=84?= =?UTF-8?q?=E8=8F=9C=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lang/en.ts | 2 ++ src/lang/zh.ts | 2 ++ src/router/index.ts | 2 ++ src/router/modules/question.ts | 26 ++++++++++++++++++++++++++ src/views/question/list.vue | 0 5 files changed, 32 insertions(+) create mode 100644 src/router/modules/question.ts create mode 100644 src/views/question/list.vue diff --git a/src/lang/en.ts b/src/lang/en.ts index bc8257a..f8ae908 100644 --- a/src/lang/en.ts +++ b/src/lang/en.ts @@ -70,6 +70,8 @@ export default { marketing_coupon: 'Coupon', marketing_promo: 'Promo Code', marketing_points: 'Points Setting', + question: 'Question Set', + question_list: 'Question List', }, navbar: { logOut: 'Log Out', diff --git a/src/lang/zh.ts b/src/lang/zh.ts index b05dc35..8d32e78 100644 --- a/src/lang/zh.ts +++ b/src/lang/zh.ts @@ -70,6 +70,8 @@ export default { marketing_coupon: '优惠券设置', marketing_promo: '优惠码设置', marketing_points: '积分设置', + question: '题库管理', + question_list: '列表', }, navbar: { logOut: '退出登录', diff --git a/src/router/index.ts b/src/router/index.ts index a4df6ca..3ca0b0b 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -9,6 +9,7 @@ import tableRouter from './modules/table' import systemRoutes from '@/router/modules/system' import articleRouters from '@/router/modules/article' import marketingRoutes from '@/router/modules/marketing' +import questionRoutes from '@/router/modules/question' Vue.use(VueRouter) @@ -118,6 +119,7 @@ export const asyncRoutes: RouteConfig[] = [ systemRoutes, articleRouters, marketingRoutes, + questionRoutes, { path: '/error-log', component: Layout, diff --git a/src/router/modules/question.ts b/src/router/modules/question.ts new file mode 100644 index 0000000..aba993f --- /dev/null +++ b/src/router/modules/question.ts @@ -0,0 +1,26 @@ +import { RouteConfig } from 'vue-router' +import Layout from '@/layout/index.vue' + +const questionRoutes: RouteConfig = { + path: '/question', + component: Layout, + meta: { + title: 'question', + icon: 'component', + alwaysShow: true + }, + children: [ + { + path: 'list', + component: () => import('@/views/question/list.vue'), + name: 'QuestionList', + meta: { + title: 'question_list', + permissions: ['question:read'], + elicon: 'el-icon-arrow-right' + } + }, + ] +} + +export default questionRoutes diff --git a/src/views/question/list.vue b/src/views/question/list.vue new file mode 100644 index 0000000..e69de29