11
This commit is contained in:
@@ -14,89 +14,92 @@
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-row v-show="showSecond">
|
||||
<el-col :xs="2" :sm="2" :md="1.5" :lg="2" :xl="4">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
<el-col v-show="width" :md="6" :lg="6" :xl="4">
|
||||
<div class="left_lab" ref="lab">
|
||||
<div class="lab">
|
||||
<div v-for="(nav,index) in navList" class="lab_div">
|
||||
<div v-if="index === showIndex" class="lab_list lab_select" @click="navClick(nav,index)">
|
||||
<div class="lab_img">
|
||||
<img src="@/assets/school_profile/eji_icon_xz.png" alt="">
|
||||
<div style="background-color:#F8F8F8 ; padding-bottom: 19rem">
|
||||
<el-row v-show="showSecond">
|
||||
<el-col :xs="2" :sm="2" :md="1.5" :lg="2" :xl="4">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
<el-col v-show="width" :md="6" :lg="6" :xl="4">
|
||||
<div class="left_lab" ref="lab">
|
||||
<div class="lab">
|
||||
<div v-for="(nav,index) in navList" class="lab_div">
|
||||
<div v-if="index === showIndex" class="lab_list lab_select" @click="navClick(nav,index)">
|
||||
<div class="lab_img">
|
||||
<img src="@/assets/school_profile/eji_icon_xz.png" alt="">
|
||||
</div>
|
||||
<div class="lab_title">
|
||||
{{ nav.title }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="lab_title">
|
||||
{{ nav.title }}
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="index !== showIndex" class="lab_list" @click="navClick(nav,index)">
|
||||
<div class="lab_img">
|
||||
<img src="@/assets/school_profile/eji_icon_xz.png" alt="">
|
||||
</div>
|
||||
<div class="lab_title">
|
||||
{{ nav.title }}
|
||||
<div v-if="index !== showIndex" class="lab_list" @click="navClick(nav,index)">
|
||||
<div class="lab_img">
|
||||
<img src="@/assets/school_profile/eji_icon_xz.png" alt="">
|
||||
</div>
|
||||
<div class="lab_title">
|
||||
{{ nav.title }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :xs="20" :sm="20" :md="15" :lg="14" :xl="12">
|
||||
<el-row>
|
||||
<el-col>
|
||||
<div class="tab">
|
||||
<router-link to="/">首页</router-link>
|
||||
<span> > </span>
|
||||
<router-link to="">{{ crumbs.one.title }}</router-link>
|
||||
<span> > </span>
|
||||
<span style="color: #1956BC;font-size: 1.4rem">{{ crumbs.two.title }}</span>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col>
|
||||
<Introduction :value="contextData" v-if="type == 1"/>
|
||||
<List :value="contextData" v-if="type == 2"/>
|
||||
<DireData :value="contextData" v-if="type == 3"/>
|
||||
<Details :value="detailsData" v-if="type == null"/>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
<el-col :xs="2" :sm="2" :md="1.5" :lg="2" :xl="4">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row v-show="!showSecond">
|
||||
<el-col :xs="2" :sm="2" :md="2" :lg="4" :xl="5">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
<el-col :xs="20" :sm="20" :md="20" :lg="16" :xl="14">
|
||||
<el-row>
|
||||
<el-col>
|
||||
<div class="tab">
|
||||
<router-link to="/">首页</router-link>
|
||||
<span> > </span>
|
||||
<router-link to="">{{ crumbs.one.title }}</router-link>
|
||||
<span> > </span>
|
||||
<span style="color: #1956BC;font-size: 1.4rem">{{ crumbs.two.title }}</span>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col>
|
||||
<Introduction :value="contextData" v-if="type == 1"/>
|
||||
<List :value="contextData" v-if="type == 2"/>
|
||||
<DireData :value="contextData" v-if="type == 3"/>
|
||||
<Details :value="detailsData" v-if="type == null"/>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
<el-col :xs="2" :sm="2" :md="2" :lg="4" :xl="5">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
</el-col>
|
||||
<el-col :xs="20" :sm="20" :md="15" :lg="14" :xl="12">
|
||||
<el-row>
|
||||
<el-col>
|
||||
<div class="tab">
|
||||
<router-link to="/">首页</router-link>
|
||||
<span> > </span>
|
||||
<router-link to="">{{ crumbs.one.title }}</router-link>
|
||||
<span> > </span>
|
||||
<span style="color: #1956BC;font-size: 1.4rem">{{ crumbs.two.title }}</span>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col>
|
||||
<Introduction :value="contextData" v-if="type == 1"/>
|
||||
<List :value="contextData" v-if="type == 2"/>
|
||||
<FileList :value="contextData" v-if="type == 4"/>
|
||||
<DireData :value="contextData" v-if="type == 3"/>
|
||||
<Details :value="detailsData" v-if="type == null"/>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
<el-col :xs="2" :sm="2" :md="1.5" :lg="2" :xl="4">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row v-show="!showSecond">
|
||||
<el-col :xs="2" :sm="2" :md="2" :lg="4" :xl="5">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
<el-col :xs="20" :sm="20" :md="20" :lg="16" :xl="14">
|
||||
<el-row>
|
||||
<el-col>
|
||||
<div class="tab">
|
||||
<router-link to="/">首页</router-link>
|
||||
<span> > </span>
|
||||
<router-link to="">{{ crumbs.one.title }}</router-link>
|
||||
<span> > </span>
|
||||
<span style="color: #1956BC;font-size: 1.4rem">{{ crumbs.two.title }}</span>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col>
|
||||
<Introduction :value="contextData" v-if="type == 1"/>
|
||||
<List :value="contextData" v-if="type == 2"/>
|
||||
<FileList :value="contextData" v-if="type == 4"/>
|
||||
<DireData :value="contextData" v-if="type == 3"/>
|
||||
<Details :value="detailsData" v-if="type == null"/>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
<el-col :xs="2" :sm="2" :md="2" :lg="4" :xl="5">
|
||||
<div class="grid-content"></div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
@@ -107,6 +110,7 @@ import Introduction from './components/Introduction.vue'
|
||||
import List from './components/list.vue'
|
||||
import DireData from './components/dire_data.vue'
|
||||
import Details from './components/details.vue'
|
||||
import FileList from './components/file_list.vue'
|
||||
import {handleTree} from "@/utils/ebts";
|
||||
import {getParentNode} from "@/utils/sist";
|
||||
|
||||
@@ -116,7 +120,8 @@ export default {
|
||||
Introduction,
|
||||
List,
|
||||
DireData,
|
||||
Details
|
||||
Details,
|
||||
FileList
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@@ -128,7 +133,7 @@ export default {
|
||||
showSecond: true,
|
||||
contextData: {},
|
||||
type: 2,
|
||||
bgImage: null, crumbs: {
|
||||
bgImage: null, crumbs: {
|
||||
"two": {
|
||||
"title": "学院领导",
|
||||
},
|
||||
@@ -146,11 +151,11 @@ export default {
|
||||
let id = this.$route.params && this.$route.params.secondId
|
||||
this.type = this.$route.query && this.$route.query.type
|
||||
console.log("触发了 $route")
|
||||
if (this.type==3||this.type==1||this.type==2){
|
||||
if (this.type == 3 || this.type == 1 || this.type == 2) {
|
||||
this.secondId = id
|
||||
this.showSecond = false
|
||||
let info = getParentNode(this.secondId);
|
||||
console.log("获取到info",info)
|
||||
console.log("获取到info", info)
|
||||
if (arcId != undefined) {
|
||||
console.log("getContext")
|
||||
this.getContext(arcId)
|
||||
@@ -201,12 +206,12 @@ export default {
|
||||
})
|
||||
},
|
||||
getNav() {
|
||||
if (this.type==3||this.type==1||this.type==2){
|
||||
if (this.type == 3 || this.type == 1 || this.type == 2) {
|
||||
console.log("进入二级")
|
||||
this.showSecond = false
|
||||
let info =null
|
||||
let info = null
|
||||
info = getParentNode(this.secondId);
|
||||
if (info == null){
|
||||
if (info == null) {
|
||||
location.reload();
|
||||
}
|
||||
let arcId = null
|
||||
@@ -225,7 +230,7 @@ export default {
|
||||
this.getNodes()
|
||||
},
|
||||
|
||||
getNodes(){
|
||||
getNodes() {
|
||||
this.navList = []
|
||||
getNode({id: this.secondId}).then(res => {
|
||||
this.navList = res.data
|
||||
@@ -253,16 +258,13 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
|
||||
getContent(menu) {
|
||||
console.log("getContent内部,menu:",menu)
|
||||
console.log("getContent内部,menu:", menu)
|
||||
this.type = menu.type
|
||||
this.contextData = null
|
||||
this.bgImage = menu.link
|
||||
let data = null
|
||||
if (this.type == 2) {
|
||||
if (this.type == 2 || this.type == 4) {
|
||||
data = {
|
||||
id: menu.encodeId,
|
||||
pageNum: 1,
|
||||
@@ -274,8 +276,8 @@ export default {
|
||||
}
|
||||
}
|
||||
getNode(data).then(res => {
|
||||
console.log(res,"res值")
|
||||
if (this.type == 2) {
|
||||
console.log(res, "res值")
|
||||
if (this.type == 2 || this.type == 4) {
|
||||
this.contextData = {
|
||||
data: res.rows,
|
||||
total: res.total,
|
||||
@@ -303,6 +305,14 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.content {
|
||||
background-color: #F8F8F8 !important;
|
||||
}
|
||||
|
||||
.context {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.top {
|
||||
img {
|
||||
width: 100%;
|
||||
|
||||
Reference in New Issue
Block a user