master
xy 2 years ago
parent 58840df292
commit 84b4284b81

Binary file not shown.

After

Width:  |  Height:  |  Size: 572 KiB

@ -10,7 +10,7 @@
<div class="container__login">
<i class="el-icon-user"></i>
<span>管理端登</span>
<span @click="$router.push('/')"></span>
</div>
</section>
</template>

@ -19,17 +19,20 @@
<div class="right">
<div class="search-bar">
<el-dropdown trigger="click" placement="bottom" @command="">
<el-dropdown trigger="click" placement="bottom-start" @command="searchCommand">
<el-button type="primary" class="dropdown-search-button">
<div class="btn-slot">
<span>任意词</span><i style="padding-left: 10px;" class="el-icon-arrow-down el-icon--right"></i>
<span>{{searchTypeText}}</span><i style="padding-left: 10px;" class="el-icon-arrow-down el-icon--right"></i>
</div>
</el-button>
<template #dropdown>
<el-dropdown-menu class="select-drop">
<el-dropdown-item command="任意词">
<el-dropdown-item :command="{key: 'keyword',label: '任意词'}">
<div style="text-align: center">任意词</div>
</el-dropdown-item>
<el-dropdown-item :command="{key: 'jianshu',label: '简述'}">
<div style="text-align: center">简述</div>
</el-dropdown-item>
<!-- <el-dropdown-item command="工作流程">-->
<!-- <div style="text-align: center">工作流程</div>-->
<!-- </el-dropdown-item>-->
@ -80,6 +83,8 @@
export default {
data() {
return {
searchTypeText: '任意词',
searchType: 'keyword',
popoverShow: false,
selectLabel: '',
selectValue: '',
@ -88,8 +93,19 @@ export default {
}
},
methods: {
searchCommand (e) {
this.searchTypeText = e.label
this.searchType = e.key
},
search () {
this.$store.commit('reception/SET_SELECTED',{ key: 'keyword', value: this.inputValue })
if (this.searchType === 'keyword') {
this.$store.commit('reception/SET_SELECTED',{ key: 'jianshu', value: '' })
this.$store.commit('reception/SET_SELECTED',{ key: 'keyword', value: this.inputValue })
}
if (this.searchType === 'jianshu') {
this.$store.commit('reception/SET_SELECTED',{ key: 'keyword', value: '' })
this.$store.commit('reception/SET_SELECTED',{ key: 'jianshu', value: this.inputValue })
}
this.$router.push(`/index/list1?${this.$store.getters.select}`)
}
@ -196,8 +212,9 @@ export default {
&::before {
content: '';
background: #1e9fff;
filter: blur(8px);
background: url('../../assets/reception/search-bkg.png') no-repeat center;
background-size: cover;
filter: blur(2px);
z-index: 0;
position: absolute;
@ -295,7 +312,7 @@ export default {
.select-drop > li:nth-child(1) {
border-radius: 6px 6px 0 0;
}
.select-drop > li:nth-child(4) {
.select-drop > li:nth-last-child(1) {
border-radius: 0 0 6px 6px;
}
</style>

@ -3,7 +3,9 @@ const state = {
tag_id: '',
dept_id: '',
keyword: '',
leixing: ''
jianshu: '',
leixing: '',
sort_name: '',
}
}

@ -23,7 +23,7 @@
<div>
<div class="list">
<div class="list__item" v-for="i in departments" @click="toList(i)">
{{ i.name }}
<p>{{ i.name }}</p>
<el-image class="list__item--icon" mode="coutain" :src="require('@/assets/reception/department-list-item-bkg.png')"></el-image>
</div>
</div>
@ -57,7 +57,7 @@ export default {
toList (i) {
this.$store.commit('reception/SET_SELECTED', { key: 'dept_id', value: i.id})
this.$store.commit('reception/SET_SELECTED', { key: 'dept_id', value: i.id, refresh: true})
this.$router.push(`/index/list1?${this.$store.getters.select}`)
}
},
@ -129,6 +129,9 @@ export default {
border: 1px solid #F8F8F8;
cursor: pointer;
transition: all .2s;
display: flex;
align-items: center;
justify-content: center;
padding: 34px 41px;
margin-bottom: 16px;

@ -5,7 +5,9 @@
<el-col :span="12">
<div class="news__header">
<div class="news__header--diamond">热点资料</div>
<div class="news__header--line"></div>
<div class="news__header--line">
<span @click="toList({ sort_name: 'dianjiliang' })">更多<i class="el-icon-d-arrow-right" style="font-weight: 600;"></i></span>
</div>
</div>
<el-skeleton animated :loading="loading">
<template #template>
@ -15,7 +17,7 @@
</template>
<template>
<ul class="news__list">
<li class="news__list--item" v-for="i in details.hot">
<li class="news__list--item" v-for="i in details.hot" @click="toList({ sort_name: 'dianjiliang' })">
<div>{{ i.biaoti }}</div>
<div>{{ $moment(new Date(i.created_at)).format("YYYY-MM-DD") }}</div>
</li>
@ -28,7 +30,9 @@
<el-col :span="12">
<div class="news__header">
<div class="news__header--diamond">最新资料</div>
<div class="news__header--line"></div>
<div class="news__header--line">
<span @click="toList({ sort_name: 'created_at' })">更多<i class="el-icon-d-arrow-right" style="font-weight: 600;"></i></span>
</div>
</div>
<el-skeleton animated :loading="loading">
@ -39,7 +43,7 @@
</template>
<template>
<ul class="news__list">
<li class="news__list--item" v-for="i in details.last">
<li class="news__list--item" v-for="i in details.last" @click="toList({ sort_name: 'created_at' })">
<div>{{ i.biaoti }}</div>
<div>{{ $moment(new Date(i.created_at)).format("YYYY-MM-DD") }}</div>
</li>
@ -75,7 +79,7 @@
<div>
<div class="department__list">
<div v-for="item in departments" class="department__list--item" @click="toList({ dept:item })">
<div>{{ item.name }}</div>
<p>{{ item.name }}</p>
</div>
<div class="department__list--item">
<div @click="$router.push('/index/department')">...</div>
@ -200,10 +204,12 @@ export default {
console.log(this.labelGroup);
},
toList ({ tag, dept }) {
tag?.id ? this.$store.commit('reception/SET_SELECTED',{ key: 'tag_id', value: tag.id }) : ''
dept?.id ? this.$store.commit('reception/SET_SELECTED',{ key: 'dept_id', value: dept.id }) : ''
toList ({ tag, dept, leixing, sort_name }) {
console.log(111, sort_name, leixing)
tag?.id ? this.$store.commit('reception/SET_SELECTED',{ key: 'tag_id', value: tag.id, refresh: true }) : ''
dept?.id ? this.$store.commit('reception/SET_SELECTED',{ key: 'dept_id', value: dept.id, refresh: true }) : ''
leixing ? this.$store.commit('reception/SET_SELECTED',{ key: 'leixing', value: leixing }) : ''
sort_name ? this.$store.commit('reception/SET_SELECTED',{ key: 'sort_name', value: sort_name, refresh: true }) : ''
this.$router.push(`/index/list1?${this.$store.getters.select}`)
}
},
@ -269,10 +275,14 @@ export default {
}
&--line {
flex: 1;
height: 1px;
background: #c7d9e5;
color: #999;
text-align: right;
border-bottom: 1px solid #c7d9e5;
margin-left: 10px;
& > span {
cursor: pointer;
}
}
}
@ -389,26 +399,29 @@ export default {
}
&__list {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-items: center;
display: grid;
grid-template-columns: repeat(5, 1fr);
grid-gap: 17px;
margin-top: 41px;
&--item {
background: #fff;
width: 176px;
//width: 176px;
height: 80px;
color: #1a5ca3;
font-size: 16px;
line-height: 80px;
text-align: center;
font-weight: 500;
cursor: pointer;
transition: all 0.2ms;
display: flex;
align-items: center;
box-sizing: border-box;
justify-content: center;
margin-bottom: 20px;
padding: 0 10px;
&:hover {
color: #fff;
@ -459,7 +472,7 @@ export default {
transition: all 0.4s;
&:hover {
transform: scale(1.1, 1.1);
transform: scale(1.05, 1.05);
}
}
&__left--single {

@ -75,7 +75,7 @@ export default {
},
toList (i) {
this.$store.commit('reception/SET_SELECTED', { key: 'tag_id', value: i.id })
this.$store.commit('reception/SET_SELECTED', { key: 'tag_id', value: i.id, refresh: true })
this.$router.push(`/index/list1?${this.$store.getters.select}`)
}
},

@ -1,6 +1,6 @@
<template>
<div class="list1">
<el-page-header class="header" @back="$router.back()" :content="type+':共搜索到'+total+'条'">
<el-page-header class="header" @back="$router.replace('/index')" :content="type+':共搜索到'+total+'条'">
</el-page-header>
<div class="container">
@ -17,7 +17,7 @@
<div>
<div class="list" v-if="list.length > 0">
<div class="list__item" v-for="i in list" :key="i.id">
<div class="list__item--pre" v-if="$route.query.leixing == 2">{{i.wenjian}}{{i.nianfen}}{{i.bianhao}}</div>
<div class="list__item--pre" v-if="$route.query.leixing == 5">{{i.wenjian}}{{i.nianfen}}{{i.bianhao}}</div>
<div class="list__item--name">{{i.biaoti}}</div>
<div class="list__item--date">{{ $moment(new Date(i.created_at)).format('YYYY-MM-DD') }}</div>
<el-dropdown trigger="click" placement="bottom-start" @command="open">
@ -101,10 +101,13 @@ export default {
keyword: '',
page: 1,
leixing: '',
jianshu: '',
page_size: 10,
table_name: 'materials',
tag_id: '',
dept_id: ''
dept_id: '',
sort_name: '',
sort_type: 'desc',
},
list: [],
total: 0,
@ -165,6 +168,8 @@ export default {
this.select.page = 1;
this.select.leixing = newVal.leixing;
this.select.keyword = newVal.keyword;
this.select.sort_name = newVal.sort_name;
this.select.jianshu = newVal.jianshu;
this.getMaterial()
},
deep: true
@ -172,11 +177,13 @@ export default {
},
created() {
this.select.page = 1;
let { leixing, keyword , tag_id, dept_id } = this.$route.query
let { leixing, keyword , tag_id, dept_id, sort_name, jianshu } = this.$route.query
this.select.leixing = leixing;
this.select.keyword = keyword;
this.select.tag_id = tag_id;
this.select.dept_id = dept_id;
this.select.sort_name = sort_name;
this.select.jianshu = jianshu;
this.getMaterial()
}
}

Loading…
Cancel
Save