还有搜索好友申请模块处理

This commit is contained in:
2022-02-16 18:03:46 +08:00
parent e0893a897a
commit 9620278813
6 changed files with 188 additions and 27 deletions

View File

@@ -31,7 +31,7 @@
searchFriend,
pedingFriend
} from '@/apis/interfaces/im.js';
import applyFriend from '../components/friendApplyList.vue';
import applyFriend from '../components/friendSearchList.vue';
export default {
components: {
applyFriend
@@ -45,9 +45,15 @@
},
methods: {
search() {
// friendship: '' 没有好友关系
// accepted 好友
// pending 申请中
// denied 拒绝
// blocked 黑名单
searchFriend(this.searchValue)
.then(res => {
this.searchResult = res;
console.log(res)
})
.catch(err => {
uni.showToast({
@@ -56,9 +62,10 @@
});
});
},
action(e) {
action(e) {
uni.navigateTo({
url: '/pages/im/friends/info?targetId=' + e.item.userId
url: '/pages/im/friends/info?targetId=' + e.item.targetId
})
}
}