修改首页政策公告添加更多跳转(接口暂未对接)

This commit is contained in:
熊丽君
2021-09-15 09:52:37 +08:00
parent 3e970c59ec
commit 561091693b
4 changed files with 137 additions and 39 deletions

BIN
src/assets/image/icon4l.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 434 B

BIN
src/assets/image/notice.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 897 B

View File

@ -71,6 +71,24 @@
</div>
<div class="banner_r">
<!-- 政策列表 -->
<div class="title">
<div class="title_top_l">
<img src="@/assets/image/icon4l.png" alt="" />
<img src="@/assets/image/notice.png" alt="" />
</div>
<router-link
target="_blank"
:to="{
path: '/portrait',
query: { key: 'policyNotice', val: '政策公告' }
}"
>
<div class="title_top_r pointer">
更多<i class="el-icon-arrow-right"></i>
</div>
</router-link>
</div>
<div class="tab_list">
<el-tabs v-model="queryParams.labelId" @tab-click="handleClick">
<el-tab-pane
label="政策法规"
@ -84,9 +102,15 @@
label="政府公示"
name="1415157002090450944"
></el-tab-pane>
<el-tab-pane label="公告" name="1415157026115424256"></el-tab-pane>
<el-tab-pane label="其他" name="1415157049267982336"></el-tab-pane>
<div style="min-height: 290px">
<el-tab-pane
label="公告"
name="1415157026115424256"
></el-tab-pane>
<el-tab-pane
label="其他"
name="1415157049267982336"
></el-tab-pane>
<div style="min-height: 281px">
<div class="banner_r_list" v-for="item in list" :key="item.id">
<!-- <div class="text_18_333 pointer">{{ item.title }}</div> -->
<div class="text_18_333 pointer">
@ -104,6 +128,7 @@
</div>
</div>
</el-tabs>
</div>
<!-- 资讯快报 -->
<div class="bulletin">
<div class="title">
@ -455,7 +480,7 @@ export default {
// }
// }
/deep/.el-tabs__item {
padding: 0 30px;
padding: 0 25px;
font-size: 20px;
}
/deep/.el-tabs__item.is-active {
@ -551,6 +576,33 @@ export default {
.banner_r {
// width: 566px;
width: 48%;
.title {
position: relative;
display: flex;
justify-content: space-between;
align-items: center;
padding: 0 20px;
height: 40px;
line-height: 40px;
text-align: right;
background-color: #3394ff;
border-radius: 6px 6px 0px 0px;
img {
vertical-align: middle;
margin-right: 10px;
}
.title_top_r {
font-size: 16px;
color: #fff;
}
span {
font-size: 16px;
color: #666;
}
}
.tab_list {
padding: 0 18px;
}
// /deep/.el-tabs__item {
// padding: 0 30px;
// font-size: 20px;
@ -571,8 +623,8 @@ export default {
.banner_r_list {
padding: 0 18px;
position: relative;
height: 58px;
line-height: 58px;
height: 55px;
line-height: 55px;
div {
padding-right: 50px;
overflow: hidden;
@ -586,7 +638,7 @@ export default {
}
}
.bulletin {
margin-top: 30px;
// margin-top: 30px;
.title {
display: flex;
justify-content: space-between;

View File

@ -4,9 +4,10 @@
<div class="padding-top content min_h_241">
<div class="search">
<div class="search_input" style="display:flex">
<span v-if="type == 'policy'">政策画像检索</span>
<span v-if="type == 'policy'">企业画像检索</span>
<span v-if="type == 'policyRead'">政策解读检索</span>
<span v-if="type == 'information'">资讯快报检索</span>
<span v-if="type == 'policyNotice'">政策公告检索</span>
<el-input
v-model="queryParams.title"
placeholder="请输入搜索关键字"
@ -41,13 +42,28 @@
>{{ item.label }}</el-radio
>
</div>
<div class="header" v-else-if="type == 'policyNotice'">
<span class="span">{{ val }}</span>
<el-radio
v-model="queryParams.labelId"
v-for="item in policyNoticeOptions"
:key="item.value"
:label="item.value"
border
@change="handleClick"
>{{ item.label }}</el-radio
>
</div>
<div class="screen_l_b" v-for="item in portraitData" :key="item.id">
<div class="title text_hidden_one pointer">
<router-link
target="_blank"
:to="{
path: '/result',
query: { key: type, id: item.id }
query: {
key: type == 'policyNotice' ? 'policy' : type,
id: item.id
}
}"
>
{{ item.title }}
@ -88,7 +104,7 @@
import { getPolicyMatch } from '@/api/home/notice';
import { mapGetters } from 'vuex';
import { userInfo, getLabelSetting } from '@/api/home/info';
import { getPolicyRead2, getInformation2 } from '@/api/home/home';
import { getPolicy, getPolicyRead2, getInformation2 } from '@/api/home/home';
import footerPage from './components/footer';
import headerPage from './components/header';
export default {
@ -106,6 +122,28 @@ export default {
},
total: 0,
portraitList: [], // 企业画像
policyNoticeOptions: [
{
value: '1415156808053559296',
label: '政策法规'
},
{
value: '1415156963146338304',
label: '申报通知'
},
{
value: '1415157002090450944',
label: '政府公示'
},
{
value: '1415157026115424256',
label: '公告'
},
{
value: '1415157049267982336',
label: '其他'
}
],
// 归口选项
attributeOptions: [
{
@ -150,6 +188,11 @@ export default {
this.portraitData = data.list;
this.total = data.total;
});
} else if (this.type == 'policyNotice') {
getPolicy(this.queryParams).then(({ data }) => {
this.portraitData = data.list;
this.total = data.total;
});
}
},
handleClick() {
@ -191,6 +234,9 @@ export default {
this.getPortraitList();
} else if (key == 'information') {
this.getPortraitList();
} else if (key == 'policyNotice') {
this.queryParams.labelId = this.policyNoticeOptions[0].value;
this.getPortraitList();
} else {
this.msgError('非法进入');
}