搜索好友,新增好友,模块好友列表
This commit is contained in:
@@ -2,9 +2,12 @@
|
||||
<view class="content">
|
||||
<!-- 用户信息 -->
|
||||
<view class="user-info">
|
||||
<u-avatar :src="userInfo.portraitUrl" size="100"></u-avatar>
|
||||
<u-avatar
|
||||
:src="userInfo.portraitUrl"
|
||||
size="100"
|
||||
></u-avatar>
|
||||
|
||||
<view class="nickname">{{ userInfo.name }}111</view>
|
||||
<view class="nickname">{{ userInfo.name }}</view>
|
||||
<!-- <view class="sex">
|
||||
<u-tag text="男" color="#fff" borderColor="#5db6ee" size="mini" icon="man" bgColor="#5db6ee"></u-tag>
|
||||
<u-tag text="女" color="#fff" borderColor="#e4867a" size="mini" icon="woman" bgColor="#e4867a"></u-tag>
|
||||
@@ -12,6 +15,7 @@
|
||||
<view class="address">
|
||||
{{ userInfo.address}}
|
||||
</view>
|
||||
<!-- 通过/拒绝/已通过/已拒绝 -->
|
||||
</view>
|
||||
<!-- <view class="user-lists">
|
||||
<view class="user-lists-item">
|
||||
@@ -21,123 +25,126 @@
|
||||
</view> -->
|
||||
<!-- 发送消息 -->
|
||||
<view class="info-footer">
|
||||
<button class="open-btn" @click="toPrivate">发送消息</button>
|
||||
<button
|
||||
class="open-btn"
|
||||
@click="toPrivate"
|
||||
>发送消息</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
getUserInfo
|
||||
} from '@/apis/interfaces/im.js'
|
||||
import { getUserInfo } from "@/apis/interfaces/im.js";
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
targetId: '',
|
||||
userInfo: {}
|
||||
}
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
targetId: "",
|
||||
userInfo: {},
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
getUserInfo(this.$Route.query.id).then((res) => {
|
||||
this.userInfo = res;
|
||||
uni.setNavigationBarTitle({
|
||||
title: res.name,
|
||||
});
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
toPrivate() {
|
||||
uni.redirectTo({
|
||||
url:
|
||||
"/pages/im/private/index?conversationType=1&targetId=" +
|
||||
this.targetId,
|
||||
});
|
||||
},
|
||||
mounted() {
|
||||
getUserInfo(this.$Route.query.id).then(res => {
|
||||
this.userInfo = res
|
||||
uni.setNavigationBarTitle({
|
||||
title: res.name
|
||||
})
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
toPrivate() {
|
||||
uni.redirectTo({
|
||||
url: '/pages/im/private/index?conversationType=1&targetId=' + this.targetId
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.content {
|
||||
min-height: 100vh;
|
||||
background: $window-color;
|
||||
.content {
|
||||
min-height: 100vh;
|
||||
background: $window-color;
|
||||
}
|
||||
|
||||
// 用户信息
|
||||
.user-info {
|
||||
padding: $padding * 3 $padding;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
background: white;
|
||||
|
||||
.nickname {
|
||||
font-size: 42rpx;
|
||||
padding-top: $padding;
|
||||
}
|
||||
|
||||
// 用户信息
|
||||
.user-info {
|
||||
padding: $padding*3 $padding;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
background: white;
|
||||
.address {
|
||||
line-height: 64rpx;
|
||||
font-size: 26rpx;
|
||||
color: $text-gray;
|
||||
}
|
||||
|
||||
.nickname {
|
||||
font-size: 42rpx;
|
||||
padding-top: $padding;
|
||||
.sex {
|
||||
padding-top: $padding/2;
|
||||
|
||||
text {
|
||||
font-size: $title-size-sm;
|
||||
background: #303133;
|
||||
padding: 0 10rpx;
|
||||
color: white;
|
||||
border-radius: $radius-m;
|
||||
line-height: 30rpx;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.user-lists {
|
||||
margin-top: $margin;
|
||||
background: white;
|
||||
|
||||
.user-lists-item {
|
||||
padding: 0 $padding;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
line-height: 90rpx;
|
||||
font-size: $title-size-lg;
|
||||
|
||||
label {
|
||||
color: $text-color;
|
||||
}
|
||||
|
||||
.address {
|
||||
line-height: 64rpx;
|
||||
font-size: 26rpx;
|
||||
text {
|
||||
color: $text-gray;
|
||||
}
|
||||
|
||||
.sex {
|
||||
padding-top: $padding/2;
|
||||
|
||||
text {
|
||||
font-size: $title-size-sm;
|
||||
background: #303133;
|
||||
padding: 0 10rpx;
|
||||
color: white;
|
||||
border-radius: $radius-m;
|
||||
line-height: 30rpx;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.user-lists {
|
||||
margin-top: $margin;
|
||||
background: white;
|
||||
// 发送消息
|
||||
.info-footer {
|
||||
padding: $padding;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
|
||||
.user-lists-item {
|
||||
padding: 0 $padding;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
line-height: 90rpx;
|
||||
font-size: $title-size-lg;
|
||||
|
||||
label {
|
||||
color: $text-color;
|
||||
}
|
||||
|
||||
text {
|
||||
color: $text-gray;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 发送消息
|
||||
.info-footer {
|
||||
padding: $padding;
|
||||
.open-btn {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
background: $main-color;
|
||||
border-radius: $radius-lg;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
color: white;
|
||||
font-size: $title-size;
|
||||
|
||||
.open-btn {
|
||||
width: 100%;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
background: $main-color;
|
||||
border-radius: $radius-lg;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
color: white;
|
||||
font-size: $title-size;
|
||||
|
||||
&::after {
|
||||
display: none;
|
||||
}
|
||||
&::after {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user