This commit is contained in:
lnn19986213 2024-01-29 14:03:30 +08:00
parent 9db8a73277
commit 58adeb08de
4 changed files with 38 additions and 7 deletions

View File

@ -137,6 +137,7 @@
</view> -->
</view>
<u-gap height="12"></u-gap>
<u-modal :show="isUnread" content='您有一条未读消息' :closeOnClickOverlay="true" @confirm="toMsg()" @close="isUnread=false"></u-modal>
<view class="not">
<view class="notice">
本服务由象山县文学艺术界联合会提供
@ -159,6 +160,7 @@
data() {
return {
load: true,
isUnread: false,
artValue: '',
statusHeight: 0,
titleHeight: 50,
@ -362,6 +364,7 @@
this.http.request('/indexImage/sybjt', {}, "GET").then(res => {
if (res.code == 200) {
this.background = res.data[0].imagePath
this.getTalkList()
this.load = false
}
}).catch(e => {
@ -371,6 +374,27 @@
});
})
},
//
getTalkList() {
let _this = this;
this.http
.request("/chat/lists", {}, "GET")
.then((res) => {
if (res.code == 200) {
if (res.data.length > 0) {
res.data.forEach(function(item) {
if (item.unread > 0) _this.isUnread = true;
});
}
}
})
.catch((e) => {
uni.showToast({
title: e.data.message,
icon: "none",
});
});
},
navigateToFun(url) {
uni.navigateTo({
url
@ -425,6 +449,11 @@
break;
}
},
toMsg(){
uni.navigateTo({
url: "/pagesA/msg/msg",
})
},
famouserDetaol(val) {
uni.navigateTo({
url: "/pagesC/famousArts/famousArts?id=" + val

View File

@ -195,7 +195,9 @@
this.userId = res.data.id;
this.yhsf = res.data.yhsf;
this.point = res.data.point;
this.association = res.data.association.name
if(this.yhsf == '文艺工作者' && res.data.association.name){
this.association = res.data.association.name
}
this.getCol();
}
})

View File

@ -20,8 +20,8 @@
this.http.request('/auth/logout', {}, "GET").then(res => {
if (res.code == 200) {
uni.redirectTo({
// url: "/pages/pageHome/shwxLogin", //h5
url: '/pagesC/Login/Login' //
url: "/pages/pageHome/shwxLogin", //h5
// url: '/pagesC/Login/Login' //
})
}
}).catch(e => {

View File

@ -5,10 +5,10 @@
export default {
config: {
baseUrl: "http://192.168.2.48:8080/h5/api", //俞燕红-小程序不能配跨域
// baseUrl: "http://192.168.2.48:8080/h5/api", //俞燕红-小程序不能配跨域
// baseUrl: "/pre", //俞燕红-跨域
// baseUrl: "https://yxx.ydool.net/h5/api", //线上
// baseUrl: "/h5/api", //h5
baseUrl: "/h5/api", //h5
header: {
'Content-Type': 'application/json;charset=UTF-8',
// 'Content-Type':'application/x-www-form-urlencoded'
@ -104,8 +104,8 @@ export default {
});
setTimeout(() => {
uni.navigateTo({
url: '/pagesC/Login/Login' //小程序跳转
// url: '/pages/pageHome/shwxLogin' //h5-山海万象跳转
// url: '/pagesC/Login/Login' //小程序跳转
url: '/pages/pageHome/shwxLogin' //h5-山海万象跳转
})
}, 1200)