合并代码
This commit is contained in:
@@ -1,20 +1,20 @@
|
||||
<template>
|
||||
<div class="account_systemMessage">
|
||||
<div class="account_systemMessage_title modal_title_text">
|
||||
系统消息
|
||||
<div class="account_generalMessage_title modal_title_text">
|
||||
<span>系统消息</span>
|
||||
<div class="account_generalMessage_title_setting" @click="allRead">全部已读</div>
|
||||
</div>
|
||||
<div class="account_systemMessage_item modal_title_text">
|
||||
<div class="account_systemMessage_item_title">
|
||||
<div>Open Call for International Young Fashion Talent</div>
|
||||
<div class="modal_title_text_intro">31 Aug 2024</div>
|
||||
<div class="account_generalMessage_item modal_title_text" v-for="item in dataList" :key="item.id" @click="setRead(item)">
|
||||
<a-badge dot></a-badge>
|
||||
<div class="account_generalMessage_item_title">
|
||||
<div class="account_generalMessage_item_title_text" :title="item.content">{{ item.content.title }}</div>
|
||||
<div class="modal_title_text_intro">{{ item.createTime }}</div>
|
||||
</div>
|
||||
<div class="modal_title_text_intro">
|
||||
10 selected young fashion talent will be mentored by the AiDA development team to learn and explore the possibilities of AiDA. Each selected young fashion talent will create a 4-outfit collection themed “Culture” with AiDA. They will receive full technical support and subsidies for the associated production fee. Selected International/ Mainland young talent will also be able to attend the Culture X AI Internation Fashion Show in Hong Kong that is scheduled on 11 March 2025.
|
||||
<span class="account_systemMessage_item_link">网页链接</span>
|
||||
{{ item.content.content }}
|
||||
<span v-if="item.content.link" class="account_generalMessage_item_link">{{ item.content.link }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
<div></div>
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
@@ -28,34 +28,38 @@ import { useI18n } from 'vue-i18n'
|
||||
export default defineComponent({
|
||||
components:{
|
||||
},
|
||||
setup() {
|
||||
emits:['setReadStatus','setAllmessage'],
|
||||
props:{
|
||||
},
|
||||
setup(prop,{emit}) {
|
||||
const router = useRouter()
|
||||
const store = useStore();
|
||||
let accountMessage = reactive({
|
||||
activeKey: ref('1'),
|
||||
dataList: [],
|
||||
})
|
||||
// let ws = new WebSocket('ws://127.0.0.1:3000')
|
||||
// console.log(ws);
|
||||
|
||||
// ws.onopen = ()=>{
|
||||
// console.log(222);
|
||||
// let data = {
|
||||
// cmd:4,
|
||||
// data:{
|
||||
// msg:'222'
|
||||
// }
|
||||
// }
|
||||
// ws.send(JSON.stringify(data))
|
||||
// // ws.onmessage = (data)=>{
|
||||
// // console.log(data);
|
||||
// // }
|
||||
// }
|
||||
let setmessageList = (data:any)=>{
|
||||
console.log(data);
|
||||
|
||||
data.content.forEach((item:any) => {
|
||||
item.content = JSON.parse(item.content)
|
||||
});
|
||||
accountMessage.dataList = data.content
|
||||
}
|
||||
let setRead = (item:any)=>{
|
||||
emit('setReadStatus',item)
|
||||
}
|
||||
let allRead = ()=>{
|
||||
emit('setAllmessage')
|
||||
}
|
||||
// provide('exhibitionList',exhibitionList)
|
||||
|
||||
onMounted (()=>{
|
||||
})
|
||||
return{
|
||||
...toRefs(accountMessage),
|
||||
setmessageList,
|
||||
setRead,
|
||||
allRead
|
||||
}
|
||||
},
|
||||
data(){
|
||||
@@ -68,37 +72,21 @@ export default defineComponent({
|
||||
<style lang="less" scoped>
|
||||
.account_systemMessage{
|
||||
width: 100%;
|
||||
.account_systemMessage_title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 2rem 5rem;
|
||||
border-bottom: 1px solid #e9eaec;
|
||||
box-shadow: 0 0px 10px 1px rgba(0, 0, 0, 0.12);
|
||||
border: 1px solid #e9eaec;
|
||||
border-radius: 5px;
|
||||
.account_systemMessage_title_setting{
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.account_systemMessage_item{
|
||||
box-shadow: 0 0px 10px 1px rgba(0, 0, 0, 0.12);
|
||||
border: 1px solid #e9eaec;
|
||||
border-radius: 5px;
|
||||
padding: 5rem 5rem;
|
||||
.account_systemMessage_item_title{
|
||||
.account_generalMessage_item{
|
||||
.account_generalMessage_item_title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 2rem;
|
||||
.account_generalMessage_item_title_text{
|
||||
max-width: 80%;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
.modal_title_text_intro{
|
||||
margin-left: 4rem;
|
||||
}
|
||||
}
|
||||
.account_systemMessage_item_link{
|
||||
color: #39215b;
|
||||
cursor: pointer;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user