添加默认头像

This commit is contained in:
luyuan 2020-08-15 15:42:00 +08:00
parent 686955424b
commit 05aa790d32
Signed by: theluyuan
GPG Key ID: A7972FD973317FF3
2 changed files with 10 additions and 0 deletions

View File

@ -437,6 +437,10 @@ export default {
friend_tomid:id
});
},
//获取默认头像
getDefaultAvatar(){
return vm.$u.post("member/getDefaultAvatar")
}
}
}

View File

@ -222,6 +222,7 @@
import zhiboItem from "@/components/index/zhibo-item/index"
import indexad from "@/components/index/ad/index"
import darenItem from "@/components/index/daren-item/index"
import chatVue from '../../pageD/chat/chat.vue'
export default {
name: "index",
@ -290,6 +291,11 @@
// console.log("lianjie")
that.imService.connectIM()
},2000)
}else{
this.$u.api.getDefaultAvatar().then((res)=>{
console.log(res)
uni.setStorageSync("morenimg",res.data.avatar)
})
}
},
onPullDownRefresh() {