feature: 首页三天内数据new标注
This commit is contained in:
@@ -34,7 +34,7 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
||||||
<span>{{ scope.row.standardName }}</span>
|
<span>{{ scope.row.standardName }}</span>
|
||||||
<img v-if="checkTime(scope.row.renewTime)" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -137,10 +137,8 @@ export default {
|
|||||||
this.total = res.data.total
|
this.total = res.data.total
|
||||||
this.loading = false
|
this.loading = false
|
||||||
if (res.data && res.data.records && res.data.records.length > 0) {
|
if (res.data && res.data.records && res.data.records.length > 0) {
|
||||||
if (res.data.records[0].renewTime && res.data.records[0].renewTime !== '') {
|
const isNew = res.data.records[0].threeDaysNew || false
|
||||||
const isNew = this.checkTime(res.data.records[0].renewTime)
|
this.$emit('isNew', isNew)
|
||||||
this.$emit('isNew', isNew)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}, e => {
|
}, e => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
|
|||||||
@@ -35,7 +35,10 @@
|
|||||||
label="标准名称"
|
label="标准名称"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span @click="handlePreview(scope.row)">{{ scope.row.standardName }}</span>
|
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
||||||
|
{{ scope.row.standardName }}
|
||||||
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -120,7 +123,7 @@ export default {
|
|||||||
getAdvice () {
|
getAdvice () {
|
||||||
this.loading = true
|
this.loading = true
|
||||||
this.$http.get('/lawss/NewsFeed/getNewsFeed', {
|
this.$http.get('/lawss/NewsFeed/getNewsFeed', {
|
||||||
messageType: 'GNWBZFG',
|
messageType: this.$route.query.messageType,
|
||||||
page: this.page,
|
page: this.page,
|
||||||
pageSize: this.pageSize
|
pageSize: this.pageSize
|
||||||
}, {
|
}, {
|
||||||
@@ -149,12 +152,12 @@ export default {
|
|||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
}
|
}
|
||||||
/deep/.more {
|
/deep/.more {
|
||||||
position: absolute;
|
//position: absolute;
|
||||||
right: 0;
|
//right: 0;
|
||||||
bottom: 2px;
|
//bottom: 2px;
|
||||||
font-size: 15px;
|
//font-size: 15px;
|
||||||
float: right;
|
//float: right;
|
||||||
color: #4788c0;
|
//color: #4788c0;
|
||||||
&:hover {
|
&:hover {
|
||||||
color: #3a8ee6;
|
color: #3a8ee6;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
||||||
<span>{{ scope.row.standardName }}</span>
|
<span>{{ scope.row.standardName }}</span>
|
||||||
<img v-if="checkTime(scope.row.releaseDate)" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -71,7 +71,7 @@ export default {
|
|||||||
loading: false,
|
loading: false,
|
||||||
pageVerify: false,
|
pageVerify: false,
|
||||||
page: 1,
|
page: 1,
|
||||||
pageSize: this.$store.getters.userInfo.configContent,
|
pageSize: 10,
|
||||||
total: 0,
|
total: 0,
|
||||||
putTime: '',
|
putTime: '',
|
||||||
standardReleaseList: [], // 标准发布数据
|
standardReleaseList: [], // 标准发布数据
|
||||||
@@ -130,6 +130,10 @@ export default {
|
|||||||
this.standardReleaseList = res.data.records
|
this.standardReleaseList = res.data.records
|
||||||
this.total = res.data.total
|
this.total = res.data.total
|
||||||
this.loading = false
|
this.loading = false
|
||||||
|
if (res.data && res.data.records && res.data.records.length > 0) {
|
||||||
|
const isNew = res.data.records[0].threeDaysNew || false
|
||||||
|
this.$emit('isNew', isNew)
|
||||||
|
}
|
||||||
}, e => {
|
}, e => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
this.standardReleaseList = []
|
this.standardReleaseList = []
|
||||||
|
|||||||
@@ -1,14 +1,6 @@
|
|||||||
<!-- 企标发布 -->
|
<!-- 企标发布 -->
|
||||||
<template>
|
<template>
|
||||||
<div class="release">
|
<div class="release">
|
||||||
<!-- <ul>-->
|
|
||||||
<!-- <li v-for="item in standardReleaseList" :key="item.id" class="time-title" >-->
|
|
||||||
<!-- <div style="height: 18px;">-->
|
|
||||||
<!-- <a @click="handlePreview(item)" style="color: #333333" class="table-jump">{{ item.standName }}</a>-->
|
|
||||||
<!-- <span class="time">{{item.issueTime ? $moment(item.issueTime).format('YYYY-MM-DD') : '' }}</span>-->
|
|
||||||
<!-- </div>-->
|
|
||||||
<!-- </li>-->
|
|
||||||
<!-- </ul>-->
|
|
||||||
<el-table
|
<el-table
|
||||||
ref="selection"
|
ref="selection"
|
||||||
:data="standardReleaseList"
|
:data="standardReleaseList"
|
||||||
@@ -45,7 +37,7 @@
|
|||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
<span style="display: flex;align-items: center" @click="handlePreview(scope.row)">
|
||||||
{{ scope.row.standardName }}
|
{{ scope.row.standardName }}
|
||||||
<img v-if="checkTime(scope.row.releaseDate)" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|||||||
@@ -32,7 +32,10 @@
|
|||||||
align="center"
|
align="center"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<a class="table-jump" @click="handleClick(scope.row.id)">{{ scope.row.problemDescription }}</a>
|
<span style="display: flex;align-items: center;justify-content: center">
|
||||||
|
<a class="table-jump" @click="handleClick(scope.row.id)">{{ scope.row.problemDescription }}</a>
|
||||||
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -104,6 +107,11 @@ export default {
|
|||||||
}
|
}
|
||||||
this.loading = false
|
this.loading = false
|
||||||
resolve(res)
|
resolve(res)
|
||||||
|
|
||||||
|
if (res.data && res.data.records && res.data.records.length > 0) {
|
||||||
|
const isNew = res.data.records[0].threeDaysNew || false
|
||||||
|
this.$emit('isNew', isNew)
|
||||||
|
}
|
||||||
}, e => {
|
}, e => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
reject(e)
|
reject(e)
|
||||||
|
|||||||
@@ -1,14 +1,6 @@
|
|||||||
<!-- 企标发布 -->
|
<!-- 企标发布 -->
|
||||||
<template>
|
<template>
|
||||||
<div class="release">
|
<div class="release">
|
||||||
<!-- <ul>-->
|
|
||||||
<!-- <li v-for="item in standardReleaseList" :key="item.id" class="time-title" >-->
|
|
||||||
<!-- <div style="height: 18px;">-->
|
|
||||||
<!-- <a @click="handlePreview(item)" style="color: #333333" class="table-jump">{{ item.standName }}</a>-->
|
|
||||||
<!-- <span class="time">{{item.issueTime ? $moment(item.issueTime).format('YYYY-MM-DD') : '' }}</span>-->
|
|
||||||
<!-- </div>-->
|
|
||||||
<!-- </li>-->
|
|
||||||
<!-- </ul>-->
|
|
||||||
<el-table
|
<el-table
|
||||||
ref="selection"
|
ref="selection"
|
||||||
:data="standardReleaseList"
|
:data="standardReleaseList"
|
||||||
@@ -42,7 +34,10 @@
|
|||||||
align="center"
|
align="center"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span style="cursor:pointer;color: #409eff" @click.stop="toDetail(scope.row)">{{ scope.row.dataTitle }}</span>
|
<span style="display: flex;align-items: center;justify-content: center">
|
||||||
|
<span style="cursor:pointer;color: #409eff" @click.stop="toDetail(scope.row)">{{ scope.row.dataTitle }}</span>
|
||||||
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -147,6 +142,10 @@ export default {
|
|||||||
this.standardReleaseList = res.data
|
this.standardReleaseList = res.data
|
||||||
this.total = res.data.total
|
this.total = res.data.total
|
||||||
this.loading = false
|
this.loading = false
|
||||||
|
if (res.data && res.data.length > 0) {
|
||||||
|
const isNew = res.data[0].threeDaysNew || false
|
||||||
|
this.$emit('isNew', isNew)
|
||||||
|
}
|
||||||
}, e => {
|
}, e => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
this.standardReleaseList = []
|
this.standardReleaseList = []
|
||||||
|
|||||||
@@ -1,14 +1,6 @@
|
|||||||
<!-- 标准征求意见 -->
|
<!-- 标准征求意见 -->
|
||||||
<template>
|
<template>
|
||||||
<div class="solicitopinions">
|
<div class="solicitopinions">
|
||||||
<!-- <ul>-->
|
|
||||||
<!-- <li v-for="item in domesticDynamics" :key="item.id" class="time-title">-->
|
|
||||||
<!-- <div style="height: 18px; border-bottom: dashed 1px #cccccc">-->
|
|
||||||
<!-- <a class="title" style="color: #333333;" :title="item.cname" @click="standForComments(item)">{{ item.cid }}</a>-->
|
|
||||||
<!-- <span class="time">{{ item.endTime }}</span>-->
|
|
||||||
<!-- </div>-->
|
|
||||||
<!-- </li>-->
|
|
||||||
<!-- </ul>-->
|
|
||||||
<el-table
|
<el-table
|
||||||
ref="selection"
|
ref="selection"
|
||||||
:data="domesticDynamics"
|
:data="domesticDynamics"
|
||||||
@@ -17,7 +9,6 @@
|
|||||||
style="cursor:pointer;"
|
style="cursor:pointer;"
|
||||||
:header-cell-style="{background: '#f8f8f9', color: '#515a6e'}"
|
:header-cell-style="{background: '#f8f8f9', color: '#515a6e'}"
|
||||||
>
|
>
|
||||||
style="width: 100%">
|
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="序号"
|
label="序号"
|
||||||
type="index"
|
type="index"
|
||||||
@@ -26,11 +17,13 @@
|
|||||||
/>
|
/>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="cid"
|
prop="cid"
|
||||||
show-overflow-tooltip
|
|
||||||
label="标准名称"
|
label="标准名称"
|
||||||
>
|
>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span @click="standForComments(scope.row)">{{ scope.row.cid }}</span>
|
<span style="display: flex;align-items: center" @click="standForComments(scope.row)">
|
||||||
|
<span>{{ scope.row.cid }}</span>
|
||||||
|
<img v-if="scope.row.threeDaysNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">
|
||||||
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
@@ -60,7 +53,6 @@ export default {
|
|||||||
mounted () {
|
mounted () {
|
||||||
this.getDate();
|
this.getDate();
|
||||||
this.getAdvice();
|
this.getAdvice();
|
||||||
// this.addDate();
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 截取时间
|
// 截取时间
|
||||||
@@ -76,6 +68,10 @@ export default {
|
|||||||
_this: this
|
_this: this
|
||||||
}, res => {
|
}, res => {
|
||||||
this.domesticDynamics = res.data.records
|
this.domesticDynamics = res.data.records
|
||||||
|
if (res.data && res.data.records && res.data.records.length > 0) {
|
||||||
|
const isNew = res.data.records[0].threeDaysNew || false
|
||||||
|
this.$emit('isNew', isNew)
|
||||||
|
}
|
||||||
}, e => {
|
}, e => {
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|||||||
+57
-18
@@ -5,43 +5,73 @@
|
|||||||
<search-group />
|
<search-group />
|
||||||
<div class="main-tabs" style="box-shadow:1px 1px 10px rgba(0,0,0,0.1);border-radius: 3px;">
|
<div class="main-tabs" style="box-shadow:1px 1px 10px rgba(0,0,0,0.1);border-radius: 3px;">
|
||||||
<div class="main-left-wrap">
|
<div class="main-left-wrap">
|
||||||
<!-- <el-button type="text" style="font-size: 14px" class="more" @click="MORE">MORE</el-button>-->
|
|
||||||
<el-tabs
|
<el-tabs
|
||||||
v-model="activeName"
|
v-model="activeName"
|
||||||
class="home-tabs"
|
class="home-tabs"
|
||||||
@tab-click="handleTabClick"
|
@tab-click="handleTabClick"
|
||||||
>
|
>
|
||||||
<el-tab-pane name="solicitOpinions">
|
<el-tab-pane name="solicitOpinions">
|
||||||
<span slot="label"><i class="el-icon-s-order" /> 标准征求意见</span>
|
<span slot="label" style="position: relative">
|
||||||
<solicitOpinions />
|
<i class="el-icon-s-order" />
|
||||||
|
标准征求意见
|
||||||
|
<span v-if="opinionIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<solicitOpinions @isNew="setIsNew($event, 'opinionIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="releaseZL" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="releaseZL" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label"><i class="el-icon-chat-line-round" /> 标准化动态</span>
|
<span slot="label" style="position: relative">
|
||||||
<releaseZL />
|
<i class="el-icon-chat-line-round" />
|
||||||
|
标准化动态
|
||||||
|
<span v-if="trendsIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<releaseZL @isNew="setIsNew($event, 'trendsIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="releaseUs" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="releaseUs" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label"><i class="el-icon-s-operation" /> 在研标准法规动态</span>
|
<span slot="label" style="position: relative">
|
||||||
<releaseUs />
|
<i class="el-icon-s-operation" />
|
||||||
|
在研标准法规动态
|
||||||
|
<span v-if="underResearchIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<!-- <releaseUs />-->
|
||||||
|
<release messageType="ZYBZFG" @isNew="setIsNew($event, 'underResearchIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="releaseCn" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="releaseCn" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label"><i class="el-icon-s-promotion" /> 国内标准法规动态</span>
|
<span slot="label" style="position: relative">
|
||||||
<release messageType="GNBZFG" />
|
<i class="el-icon-s-promotion" />
|
||||||
|
国内标准法规动态
|
||||||
|
<span v-if="domIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<release messageType="GNBZFG" @isNew="setIsNew($event, 'domIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="release" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="release" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label"><i class="el-icon-s-promotion" /> 国外标准法规动态</span>
|
<span slot="label" style="position: relative">
|
||||||
<release messageType="GWBZFG" />
|
<i class="el-icon-s-promotion" />
|
||||||
|
国外标准法规动态
|
||||||
|
<span v-if="abroadIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<release messageType="GWBZFG" @isNew="setIsNew($event, 'abroadIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="releaseBuss" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="releaseBuss" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label" style="position: relative"><i class="el-icon-s-promotion" />
|
<span slot="label" style="position: relative">
|
||||||
|
<i class="el-icon-s-promotion" />
|
||||||
企业标准发布
|
企业标准发布
|
||||||
<span v-if="isNew" class="more-doc" />
|
<span v-if="isNew" class="more-doc" />
|
||||||
<!--<img v-if="isNew" src="/static/images/new.png" style="width: 30px;margin-left: 5px">-->
|
|
||||||
</span>
|
</span>
|
||||||
<releaseBuss />
|
<releaseBuss @isNew="setIsNew($event, 'isNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
|
||||||
<el-tab-pane name="releaseQA" style="overflow-y: auto;height: 100%">
|
<el-tab-pane name="releaseQA" style="overflow-y: auto;height: 100%">
|
||||||
<span slot="label"><i class="el-icon-chat-line-round" /> 标准问答</span>
|
<span slot="label" style="position: relative">
|
||||||
<releaseQA />
|
<i class="el-icon-chat-line-round" />
|
||||||
|
标准问答
|
||||||
|
<span v-if="questionIsNew" class="more-doc" />
|
||||||
|
</span>
|
||||||
|
<releaseQA @isNew="setIsNew($event, 'questionIsNew')" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
</div>
|
</div>
|
||||||
@@ -88,13 +118,22 @@ export default {
|
|||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
activeName: 'solicitOpinions',
|
activeName: 'solicitOpinions',
|
||||||
isNew: false
|
opinionIsNew: false,
|
||||||
|
trendsIsNew: false,
|
||||||
|
underResearchIsNew: false,
|
||||||
|
domIsNew: false,
|
||||||
|
abroadIsNew: false,
|
||||||
|
isNew: false,
|
||||||
|
questionIsNew: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
this.getAdvice()
|
// this.getAdvice()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
setIsNew (isNew, key) {
|
||||||
|
this.$set(this, key, isNew)
|
||||||
|
},
|
||||||
getAdvice () {
|
getAdvice () {
|
||||||
this.$http.get('/lawss/NewsFeed/getNewsFeed', {
|
this.$http.get('/lawss/NewsFeed/getNewsFeed', {
|
||||||
messageType: 'QYBZFB',
|
messageType: 'QYBZFB',
|
||||||
|
|||||||
Reference in New Issue
Block a user