<!--packageE/stargroup/stargroup.wxml-->
<view class="component-wrapper">

	<!--选项卡静态-->
	<view>
		<view class="tab">
			<view class="ul tab_list">
				<van-tabs active="{{active}}" swipeable bind:change="onClick"
					color="{{datas.tab_color_active}}" tab-class="tag">
					<van-tab title="全部参团" name="{{0}}"
						title-style="padding: 0;overflow: visible;white-space: nowrap;text-overflow: clip;background: {{datas.tab_bgcolor}};color:{{active==0?datas.tab_color_active:datas.tab_color}};">
					</van-tab>
					<van-tab title="积分参团" name="{{1}}"
						title-style="padding: 0;overflow: visible;white-space: nowrap;text-overflow: clip;background: {{datas.tab_bgcolor}};color:{{active==1?datas.tab_color_active:datas.tab_color}};">
					</van-tab>
				</van-tabs>

				<view wx:if="{{joinListData.length>0}}" class="join_list" style="background:{{datas.preview_color}}">

					<view class="join_item" wx:for="{{joinListData}}" wx:key="leader_id">
						<view class="name">
							<view class="c1">团长：{{item.nickname}}</view>
							<view class="c2">活动名称：{{item.activity_name}}</view>
						</view>
						<view class="join_container">
							<view class="join_face">
								<block wx:for="{{item.team}}" wx:for-item="item1" wx:for-index="index1">
									<view class="face" wx:key="{{index1}}">
										<image src="{{item1.avatar}}"></image>
									</view>
								</block>
							</view>
							<view class="time_box">
								<view class="time" style="font-size: 16px;font-weight: bold">
									还差<text class="font-color">{{item.surplus_num}}人</text>拼成
								</view>
								<view class="c2 text" style="display:flex;align-items:center;">距结束:
									<count now-time="{{currentTime}}" over-time="{{item.end_time}}"></count>
								</view>
							</view>
							<view class="btn" data-id="{{item.leader_id}}" bindtap="gotoStarGroupDetails" style="color:{{datas.group_once_color}};background:{{datas.group_once_bg}};">立即参团</view>
						</view>
						<!-- <view class="join_container">
							<view class="join_face">
								<block wx:for="{{item.team}}" wx:for-item="item1" wx:for-index="index1">
									<view class="face" wx:key="{{index1}}">
										<image src="{{item1.avatar}}"></image>
									</view>
								</block>
							</view>
						</view>
						<view class="desc">
							<view class="c2 text" style="display:flex;align-items:center;">距结束:
								<count now-time="{{currentTime}}" over-time="{{item.end_time}}"></count>
							</view>
							<view class="btn" data-id="{{item.leader_id}}" bindtap="gotoStarGroupDetails" style="color:{{datas.group_once_color}};background:{{datas.group_once_bg}};">立即参团</view>
						</view> -->

					</view>

					<view style="backgroundColor:{{datas.preview_color}};text-align:center;">
						<view class="loadMore" wx:if="{{isLoadMore}}" bindtap="getMoreData">
							加载更多
						</view>
						<view class="loadMore" wx:if="{{lastIndex == index && allLoaded}}">
							没有更多了~~
						</view>
					</view>

				</view>

				<block wx:if="{{joinListData.length<=0}}">
					<view
						style="padding: 10px 15px;text-align: center;">
						{{show_text}}
					</view>
				</block>
				
			</view>
		</view>
	</view>
</view>