|
@@ -7,7 +7,7 @@
|
|
|
<view class="two">
|
|
|
<scroll-view scroll-y="true" class="scroll-view" @scrolltolower="toPage">
|
|
|
<view class="list-scroll-view">
|
|
|
- <view class="list" v-for="(item, index) in list" :key="index">
|
|
|
+ <view class="list" v-for="(item, index) in list" :key="index" @click="toShare(item)">
|
|
|
<view class="image">
|
|
|
<image class="file" v-for="(tag, indexs) in item.persons.slice(0,7)" :key="indexs"
|
|
|
v-if="tag.status==0" :src="tag.icon&&tag.icon.length>0?tag.icon[0].url:''" mode="">
|
|
@@ -31,12 +31,15 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="other">
|
|
|
- <view v-if="item.status=='0'" class="btn" @click="onSubmit(item)">
|
|
|
- <text>{{item.zhStatus||'暂无状态'}}</text>立即参团
|
|
|
+ <view v-if="item.status=='0'" class="btn">
|
|
|
+ <text>{{item.zhStatus||'暂无状态'}}</text>
|
|
|
</view>
|
|
|
<view v-else-if="item.status=='-1'" class="button">
|
|
|
{{item.zhStatus||'暂无状态'}}
|
|
|
</view>
|
|
|
+ <view v-else-if="item.status=='2'" class="button">
|
|
|
+ 已退团
|
|
|
+ </view>
|
|
|
<view v-else class="button">
|
|
|
{{item.zhStatus||'暂无状态'}}
|
|
|
</view>
|
|
@@ -69,6 +72,14 @@
|
|
|
that.watchLogin()
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 分享
|
|
|
+ toShare(e) {
|
|
|
+ const that = this;
|
|
|
+ that.clearPage();
|
|
|
+ uni.navigateTo({
|
|
|
+ url: `/pagesHome/group/share?id=${e._id}`
|
|
|
+ })
|
|
|
+ },
|
|
|
// 监听用户是否登录
|
|
|
watchLogin() {
|
|
|
const that = this;
|
|
@@ -109,6 +120,10 @@
|
|
|
if (res.errcode == '0') {
|
|
|
let list = [...that.list, ...res.data];
|
|
|
for (let val of list) {
|
|
|
+ let personsstatus = val.persons.find(i => i.customer == user._id)
|
|
|
+ if (personsstatus.status == 1) {
|
|
|
+ val.status = '2';
|
|
|
+ }
|
|
|
val.persons = val.persons.filter(i => i.status == '0')
|
|
|
let status = that.statusList.find(i => i.value == val.status)
|
|
|
if (status) val.zhStatus = status.label;
|