diff --git a/src/assets/img/e.png b/src/assets/img/e.png new file mode 100644 index 0000000..5fa37b9 Binary files /dev/null and b/src/assets/img/e.png differ diff --git a/src/assets/img/gongzhu.png b/src/assets/img/gongzhu.png new file mode 100644 index 0000000..5de7986 Binary files /dev/null and b/src/assets/img/gongzhu.png differ diff --git a/src/assets/img/huoji.png b/src/assets/img/huoji.png new file mode 100644 index 0000000..87b7f1a Binary files /dev/null and b/src/assets/img/huoji.png differ diff --git a/src/assets/img/ji.png b/src/assets/img/ji.png new file mode 100644 index 0000000..4c31de6 Binary files /dev/null and b/src/assets/img/ji.png differ diff --git a/src/assets/img/lv.png b/src/assets/img/lv.png new file mode 100644 index 0000000..d70f411 Binary files /dev/null and b/src/assets/img/lv.png differ diff --git a/src/assets/img/muzhu.png b/src/assets/img/muzhu.png new file mode 100644 index 0000000..15b9306 Binary files /dev/null and b/src/assets/img/muzhu.png differ diff --git a/src/assets/img/niu.png b/src/assets/img/niu.png new file mode 100644 index 0000000..bff21c1 Binary files /dev/null and b/src/assets/img/niu.png differ diff --git a/src/assets/img/ya.png b/src/assets/img/ya.png new file mode 100644 index 0000000..2c7385d Binary files /dev/null and b/src/assets/img/ya.png differ diff --git a/src/assets/img/yang.png b/src/assets/img/yang.png new file mode 100644 index 0000000..b3fe8c5 Binary files /dev/null and b/src/assets/img/yang.png differ diff --git a/src/assets/img/zhu.png b/src/assets/img/zhu.png new file mode 100644 index 0000000..2b1602c Binary files /dev/null and b/src/assets/img/zhu.png differ diff --git a/src/router/index.js b/src/router/index.js index 2ec5a90..3259471 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -96,87 +96,70 @@ const routes = [ }, ] }, - { - path: '/login', - component: Login, - meta: { title: '登录', activeMenu: '/login' } - }, - { - path: '/', - component: Layout, - redirect: '/disease-resistance/disease-resistance', - meta: { title: '', activeMenu: '/disease-resistance/disease-resistance' } - }, { - // 首页 - path: '/index', - component: Layout, - children: [ - { - path: '/index/index', - component: () => - import('../views/index/index.vue'), - meta: { title: '首页', activeMenu: '/index/index' } - } - ] - }, - { - // 遗传病风险 - path: '/disease-resistance', - component: Layout, - children: [ - { - path: '/disease-resistance/disease-resistance', - component: () => - import('../views/disease-resistance/disease-resistance.vue'), - meta: { title: '遗传病风险', activeMenu: '/disease-resistance/disease-resistance' } - } - ] - }, - { - // 档案信息 - path: '/archive-information', - component: Layout, - children: [ - { - path: '/archive-information/archive-information', - component: () => - import('../views/archive-information/archive-information.vue'), - meta: { title: '档案信息', activeMenu: '/archive-information/archive-information' } - } - ] - }, - { - // 快速查询 + { + // 档案信息 + path: '/archive-information', + component: Layout, + children: [ + { + path: '/archive-information/archive-information', + component: () => + import('../views/archive-information/archive-information.vue'), + meta: { title: '档案信息', activeMenu: '/archive-information/archive-information' } + } + ] + }, + { + // 快速查询 + path: '/quick-Search/quick-Search', + component: Layout, + children: [ + { path: '/quick-Search/quick-Search', - component: Layout, - children: [ - { - path: '/quick-Search/quick-Search', - component: () => - import('../views/quick-Search/quick-Search.vue'), - meta: { title: '快速查询', activeMenu: '/quick-Search/quick-Search' } - } - ] - } + component: () => + import('../views/quick-Search/quick-Search.vue'), + meta: { title: '快速查询', activeMenu: '/quick-Search/quick-Search' } + } + ] + }, + { + // 品种资源 + path: '/variety-resources', + component: Layout, + children: [ + { + path: '/variety-resources/variety-resources', + component: () => + import('../views/variety-resources/variety-resources.vue'), + meta: { title: '品种资源', activeMenu: '/variety-resources/variety-resources' } + }, + { + path: '/variety-resources/pig-list', + component: () => + import('../views/variety-resources/pig-list.vue'), + meta: { title: '品种猪', activeMenu: '/variety-resources/pig-list' } + }, + ] + } ] const router = new VueRouter({ - routes + routes }) // 前置路由守卫 router.beforeEach((to, from, next) => { - // to到哪里取 from 从哪里来 next 放行 - const token = local.get('token_sd') - if (to.meta.title) { // 修改总标题 - document.title = '肉牛溯源系统' + '-' + to.meta.title // routes数组中--meta是关键 - } - if (token) { // ok - next() - } else { // no - if (to.path === '/login') { - next() - } - next('/login') + // to到哪里取 from 从哪里来 next 放行 + const token = local.get('token_sd') + if (to.meta.title) { // 修改总标题 + document.title = '肉牛溯源系统' + '-' + to.meta.title // routes数组中--meta是关键 + } + if (token) { // ok + next() + } else { // no + if (to.path === '/login') { + next() } + next('/login') + } }) export default router diff --git a/src/views/disease-resistance/disease-resistance.vue b/src/views/disease-resistance/disease-resistance.vue index ea08d06..8c98933 100644 --- a/src/views/disease-resistance/disease-resistance.vue +++ b/src/views/disease-resistance/disease-resistance.vue @@ -62,7 +62,7 @@ 快速查询 + + + 品种资源 + diff --git a/src/views/variety-resources/pig-list.vue b/src/views/variety-resources/pig-list.vue new file mode 100644 index 0000000..5c41bff --- /dev/null +++ b/src/views/variety-resources/pig-list.vue @@ -0,0 +1,961 @@ + + + + + diff --git a/src/views/variety-resources/variety-resources.vue b/src/views/variety-resources/variety-resources.vue new file mode 100644 index 0000000..2b14ad6 --- /dev/null +++ b/src/views/variety-resources/variety-resources.vue @@ -0,0 +1,169 @@ + + + + + \ No newline at end of file