123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171 |
- <template>
- <view class="container">
- <view class="top-img-box">
- <image class="top-img" :src="avatar" />
- <view class="top-name"> {{ nickname }} </view>
- </view>
- <view class="group-item-box">
- <view class="item-top">
- <view class="top-l">团队成员</view>
- <view class="top-r">></view>
- </view>
- <view class="item-content">
- <view class="person-item" v-for="item of teamPersonList">
- <image class="item-img" :src="item.inviteUserAvatar" mode="aspectFill" />
- <view class="item-name">{{ item.name }}</view>
- </view>
- </view>
- </view>
- <!-- <view class="group-item-box">
- <view class="item-top">
- <view class="top-l">最近动态</view>
- <view class="top-r">></view>
- </view>
- <view class="item-content dynamic-img-box">
- <img class="dynamic-img" src="@/static/logo.png" alt="" />
- </view>
- </view>
- <view class="group-item-box">
- <view class="item-top">
- <view class="top-l">团队任务</view>
- <view class="top-r">></view>
- </view>
- <view class="item-content">
- <img class="item-img" src="@/static/logo.png" alt="" :key="item" v-for="item of 3" />
- </view>
- </view> -->
- <button @click='handlerBind'>绑定</button>
- </view>
- </template>
- <script>
- import {
- getMyTeam,
- inviteBind
- } from "@/api/client/mine.js"
- import {
- mapGetters
- } from "vuex"
- export default {
- data() {
- return {
- queryParams: {
- paging: '1,10'
- },
- teamPersonList: []
- };
- },
- mounted() {
- this.handlerInitList()
- },
- computed: {
- ...mapGetters(['userId', 'gender', 'avatar', 'nickname'])
- },
- methods: {
- // 初始化我的团队列表
- handlerInitList() {
- getMyTeam(this.queryParams).then(res => {
- let {
- records
- } = res.data
- this.teamPersonList = records
- console.log("Res", res)
- })
- },
- // 测试绑定
- handlerBind() {
- let params = {
- userId: this.userId,
- targetId: '1774462327015325697',
- type: 1
- }
- inviteBind(params).then(res => {
- console.log("@@@@res", res)
- })
- }
- }
- };
- </script>
- <style lang="scss" scoped>
- .container {
- padding: 20rpx 10rpx 50rpx;
- .top-img-box {
- text-align: center;
- .top-img {
- width: 160rpx;
- height: 160rpx;
- border-radius: 100rpx;
- }
- .top-name {
- color: #6b7280;
- font-weight: bold;
- font-size: 32rpx;
- margin-top: 20rpx;
- }
- }
- .group-item-box {
- padding: 0 20rpx;
- margin-top: 60rpx;
- .item-top {
- display: flex;
- justify-content: space-between;
- .top-l,
- .top-r {
- color: #6b7280;
- font-weight: bold;
- font-size: 32rpx;
- margin-top: 20rpx;
- }
- }
- .item-content {
- display: flex;
- width: 100%;
- .person-item {
- margin-right: 20rpx;
- text-align: center;
- width: 25%;
- }
- .item-name {
- font-size: 28rpx;
- font-weight: bold;
- color: #000;
- width: 100%;
- text-overflow: ellipsis;
- white-space: nowrap;
- overflow: hidden;
- }
- .person-item:last-child {
- margin: 0;
- }
- .item-img {
- width: 160rpx;
- height: 160rpx;
- border-radius: 100rpx;
- margin: 60rpx 20rpx 0 0;
- }
- .dynamic-img {
- width: 100%;
- height: 500rpx;
- margin-top: 60rpx;
- }
- }
- }
- }
- </style>
|