Commit f5184167 authored by youjie's avatar youjie

no message

parent d961c33d
......@@ -90,55 +90,17 @@
erpUserInfo:null,
userInfo:null,
loading:true,
Account:'',
form:{
Id:'',
AccountId:'',
StuId:'',
OpenId:'',
WeChatName:'',
WeChatImg:'',
UnionId:''
},
msg: {
pageIndex: 1,
pageSize: 1000,
KeyWords: '',//关键词
},
pageCount: 0,
dataList: [],
list:[],
pageState: "more",
timer: null, //防抖
});
const methods = {
clickChecked(item){
data.dataList.forEach(i=>{
i.checked=false
if(item.StuId==i.StuId){
data.list.push(i)
}
})
item.checked = true
data.form = {
Id: item.Id,
AccountId: item.AccountId,
StuId: item.StuId,
OpenId: item.OpenId,
WeChatName: item.WeChatName,
WeChatImg: item.WeChatImg,
UnionId: item.UnionId
}
},
clickIcon(){
that.getData()
},
usernameInput(val) {
data.msg.KeyWords = val.detail.value
that.getData()
},
async addFriend(){
return
data.loading = false
uni.showLoading()
let res = await SetMyChild(data.form);
......@@ -174,18 +136,13 @@
onShow(){
this.erpUserInfo = uni.getStorageSync('erpUserInfo')
this.userInfo = uni.getStorageSync('userInfo')
this.form = {
StuId: '',
UnionId: uni.getStorageSync('wxUserAuthInfo').unionid
}
},
onReachBottom() {
if (this.msg.pageIndex < this.pageCount) {
this.pageState = "loading";
if (this.timer) clearTimeout(this.timer);
this.timer = setTimeout(() => {
this.msg.pageIndex++;
this.getList();
}, 1000);
} else {
this.pageState = "none";
}
}
};
</script>
......@@ -193,8 +193,6 @@
item.checked = false
data.form = {
StuId: '',
// WeChatName: item.WeChatName,
// WeChatImg: item.WeChatImg,
UnionId: ''
}
}else{
......@@ -207,8 +205,6 @@
item.checked = true
data.form = {
StuId: item.StuId,
// WeChatName: item.WeChatName,
// WeChatImg: item.WeChatImg,
UnionId: uni.getStorageSync('wxUserAuthInfo').unionid
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment