侧边导肮更换

master
yu 6 days ago
parent 38d69167c2
commit 2c4be2efb0
  1. 17002
      package-lock.json
  2. 56
      src/layouts/home/index.vue
  3. 4
      src/pages/achievement/list/project.vue
  4. 2
      src/router/modules/information.js
  5. 12
      vue.config.js

17002
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -3,8 +3,10 @@
<v-head></v-head>
<Navbar />
<div class="layout">
<Sidebar :class="{ show: showSidebar }" :path.sync="path" />
<!-- <Sidebar :class="{ show: showSidebar }" :path.sync="path" /> -->
<div class="content">
<el-page-header v-if="showSidebar" class="m-b-20" @back="back" :content="backName"></el-page-header>
<transition name="move" mode="out-in">
<router-view class="view"></router-view>
</transition>
@ -67,6 +69,49 @@ import { mapState, mapMutations, mapActions } from "vuex";
import util from "@/libs/util";
import Setting from "@/setting";
const backList = [
{
path: '/assessment/list',
name: '考核管理',
},
{
path: '/achievement/list',
name: '成绩管理',
},
{
path: '/evaluation/list',
name: '测评管理',
},
{
path: '/course/list',
name: '精品课程管理',
},
{
path: '/review/list',
name: '评阅中心',
},
{
path: '/information/list',
name: '资讯管理',
},
{
path: '/project/list',
name: '项目管理',
},
{
path: '/resourse/list',
name: '资源库',
},
// {
// path: '/exam/list',
// name: '',
// },
{
path: '/lesson/list',
name: '备课管理',
},
]
export default {
components: {
vHead,
@ -77,6 +122,7 @@ export default {
data () {
return {
showSidebar: false,
backName: '',
path: '',
logVisible: false,
list: [],
@ -121,7 +167,9 @@ export default {
handler (val) {
this.path = val
//
this.showSidebar = ['/assessment/list', '/achievement/list', '/evaluation/list', '/course/list', '/review/list', '/information/list', '/project/list', '/resourse/list', '/exam/list', '/review/list', '/lesson/list', '/resourse/list'].includes(val)
const item = backList.find(e => e.path === val)
this.backName = item ? item.name : ''
this.showSidebar = item
},
immediate: true
}
@ -195,6 +243,9 @@ export default {
setTimeout(this.logout, 1500);
}
}, 1000);
},
back() {
this.$router.push('/workbench/list')
}
}
};
@ -203,6 +254,7 @@ export default {
.main {
.layout {
display: flex;
min-height: calc(100vh - 173px);
}
.sidebar:not(.show) {

@ -183,7 +183,7 @@ export default {
//
async getCourse () {
if (this.$parent.active === 'tab2') {
if (this.$parent.active == 2) {
const { data } = await this.$get(this.api.getSchoolEffectiveCourse)
this.curs = data
this.form.curriculumId = this.form.curriculumId || data[0].cid
@ -210,7 +210,7 @@ export default {
...this.form,
mallId: cur.mallId || '',
systemId: cur.systemId || '',
courseType: this.$parent.active === 'tab2' ? 0 : 1,
courseType: this.$parent.active == 2 ? 0 : 1,
pageNum: this.page,
pageSize: this.pageSize,
};

@ -22,7 +22,7 @@ export default {
{
name: `${pre}addArticle`,
path: `addArticle`,
component: () => import("@/pages/information/addArticle"),
component: () => import("@/pages/information/addarticle"),
meta: { title: "新增文章" }
}
]

@ -18,11 +18,11 @@ module.exports = {
},
productionSourceMap: false,
chainWebpack: config => {
config.module
.rule("images")
.use("image-webpack-loader")
.loader("image-webpack-loader")
.options({ bypassOnDebug: true })
.end();
// config.module
// .rule("images")
// .use("image-webpack-loader")
// .loader("image-webpack-loader")
// .options({ bypassOnDebug: true })
// .end();
}
}
Loading…
Cancel
Save