|
|
@ -86,16 +86,20 @@ |
|
|
|
> |
|
|
|
<el-menu-item index="3" @click="fullscreenHandle()"> |
|
|
|
<div class="img-nav"> |
|
|
|
<img src="~@/assets/images/main/time.png" /> |
|
|
|
<div class="img-wrap"> |
|
|
|
<img src="~@/assets/images/main/time.png" /> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</el-menu-item> |
|
|
|
|
|
|
|
<el-menu-item index="2" @click="toRemindPage"> |
|
|
|
<el-menu-item index="2" @click="toNoticePage"> |
|
|
|
<div class="img-nav" :class="{ 'z-on': false }"> |
|
|
|
<span class="corner-dot" v-if="unreadMsgNum > 0">{{ |
|
|
|
unreadMsgNum |
|
|
|
}}</span> |
|
|
|
<img src="~@/assets/images/main/hint.png" /> |
|
|
|
<div class="img-wrap"> |
|
|
|
<img src="~@/assets/images/main/hint.png" /> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</el-menu-item> |
|
|
|
|
|
|
@ -136,6 +140,23 @@ |
|
|
|
></update-password-work> |
|
|
|
</nav> |
|
|
|
<nav v-else class="aui-navbar main-line"></nav> |
|
|
|
|
|
|
|
<div |
|
|
|
class="m-newMsg" |
|
|
|
v-if="noticeList.length > 0 && displayedNoticeList" |
|
|
|
> |
|
|
|
<div class="title">新提醒</div> |
|
|
|
<div class="btn-close" @click="displayedNoticeList = false"> |
|
|
|
<img src="~@/assets/images/main/close.png" /> |
|
|
|
</div> |
|
|
|
<div class="row"> |
|
|
|
<span class="date">{{ noticeList[0].createdTime }}</span> |
|
|
|
<i class="i-new">NEW</i> |
|
|
|
</div> |
|
|
|
<div class="cnt" @click="toNoticePage"> |
|
|
|
{{ noticeList[0].content }} |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
@ -157,6 +178,10 @@ export default { |
|
|
|
customerName: "", |
|
|
|
|
|
|
|
unreadMsgNum: 0, |
|
|
|
|
|
|
|
noticeList: [], |
|
|
|
|
|
|
|
displayedNoticeList: true, |
|
|
|
}; |
|
|
|
}, |
|
|
|
components: { |
|
|
@ -182,7 +207,8 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
toRemindPage() { |
|
|
|
toNoticePage() { |
|
|
|
this.displayedNoticeList = false; |
|
|
|
this.$router.replace("/main/home-notice"); |
|
|
|
}, |
|
|
|
|
|
|
@ -284,15 +310,39 @@ export default { |
|
|
|
const { data, code, msg } = await requestGet(url, {}); |
|
|
|
if (code === 0) { |
|
|
|
console.log("列表请求成功!!!!!!!!!!!!!!"); |
|
|
|
if (data.unreadNum > 0 && this.unreadMsgNum < data.unreadNum) { |
|
|
|
this.getNoticeList(); |
|
|
|
this.displayedNoticeList = true; |
|
|
|
} |
|
|
|
this.unreadMsgNum = data.unreadNum; |
|
|
|
} else { |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
//加载组织数据 |
|
|
|
async getNoticeList() { |
|
|
|
const url = "/message/intelligentMessage/page"; |
|
|
|
let params = { |
|
|
|
page: this.pageNo, |
|
|
|
limit: this.pageSize, |
|
|
|
readFlag: 0, |
|
|
|
}; |
|
|
|
|
|
|
|
const { data, code, msg } = await requestGet(url, params); |
|
|
|
|
|
|
|
if (code === 0) { |
|
|
|
this.noticeList = data.list; |
|
|
|
} else { |
|
|
|
this.$message.error(msg); |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
|
</script> |
|
|
|
|
|
|
|
<style lang="scss" scoped> |
|
|
|
@import "~@/assets/scss/c/function.scss"; |
|
|
|
|
|
|
|
.main-line { |
|
|
|
height: 50px; |
|
|
|
background: #eeeeee; |
|
|
@ -303,20 +353,90 @@ export default { |
|
|
|
.corner-dot { |
|
|
|
position: absolute; |
|
|
|
z-index: 100; |
|
|
|
display: block; |
|
|
|
display: block; |
|
|
|
top: -5px; |
|
|
|
right: -5px; |
|
|
|
right: 2px; |
|
|
|
padding: 0 3px; |
|
|
|
min-width: 16px; |
|
|
|
height: 16px; |
|
|
|
line-height: 16px; |
|
|
|
transform: translateX(50%); |
|
|
|
font-size: 12px; |
|
|
|
font-family: PingFangSC-Regular, PingFang SC; |
|
|
|
font-weight: 400; |
|
|
|
color: #ffffff; |
|
|
|
line-height: 16px; |
|
|
|
min-width: 16px; |
|
|
|
height: 16px; |
|
|
|
background: #ff4d4f; |
|
|
|
border-radius: 100%; |
|
|
|
border-radius: 8px; |
|
|
|
border: 1px solid #ffffff; |
|
|
|
text-align: center; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.m-newMsg { |
|
|
|
position: fixed; |
|
|
|
z-index: 2000; |
|
|
|
right: 30px; |
|
|
|
box-sizing: border-box; |
|
|
|
padding: 16px; |
|
|
|
width: 320px; |
|
|
|
background: #ffffff; |
|
|
|
box-shadow: 0px 6px 16px 0px rgba(0, 0, 0, 0.08), |
|
|
|
0px 3px 6px -4px rgba(0, 0, 0, 0.12); |
|
|
|
border-radius: 4px; |
|
|
|
.title { |
|
|
|
margin-bottom: 16px; |
|
|
|
height: 22px; |
|
|
|
font-size: 16px; |
|
|
|
font-family: PingFangSC-Medium, PingFang SC; |
|
|
|
font-weight: 500; |
|
|
|
color: rgba(0, 0, 0, 0.85); |
|
|
|
line-height: 22px; |
|
|
|
} |
|
|
|
.btn-close { |
|
|
|
position: absolute; |
|
|
|
top: 15px; |
|
|
|
right: 10px; |
|
|
|
padding: 6px; |
|
|
|
img { |
|
|
|
width: 16px; |
|
|
|
} |
|
|
|
} |
|
|
|
.row { |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
} |
|
|
|
.date { |
|
|
|
height: 17px; |
|
|
|
font-size: 12px; |
|
|
|
font-family: PingFangSC-Regular, PingFang SC; |
|
|
|
font-weight: 400; |
|
|
|
color: rgba(0, 0, 0, 0.45); |
|
|
|
line-height: 17px; |
|
|
|
} |
|
|
|
.i-new { |
|
|
|
margin-left: 8px; |
|
|
|
width: 40px; |
|
|
|
height: 16px; |
|
|
|
background: #eb512f; |
|
|
|
border-radius: 2px; |
|
|
|
font-size: 12px; |
|
|
|
font-family: Arial-BoldItalicMT, Arial; |
|
|
|
font-weight: normal; |
|
|
|
color: #ffffff; |
|
|
|
line-height: 16px; |
|
|
|
text-align: center; |
|
|
|
} |
|
|
|
.cnt { |
|
|
|
@include toeM(2); |
|
|
|
margin-top: 3px; |
|
|
|
padding-bottom: 0; |
|
|
|
width: 288px; |
|
|
|
height: 44px; |
|
|
|
font-size: 14px; |
|
|
|
font-family: PingFangSC-Regular, PingFang SC; |
|
|
|
font-weight: 400; |
|
|
|
color: rgba(0, 0, 0, 0.85); |
|
|
|
line-height: 22px; |
|
|
|
} |
|
|
|
} |
|
|
|
</style> |
|
|
|