<template>
	<!-- 开通一卡通 -->
	<loadlogo v-if="!HomeType"></loadlogo>
	<view class="memberCard"  v-else>
		<far-bottom></far-bottom>
		<scroll-view  :scroll-y="true" :lower-threshold="0" >
			<view class="memberCardTitle" :style="{ 'background-image': 'url(' + imageRoot + 'memberBacImg.png)' }">
				<!-- 搜索 -->
				<searchView :type="1"></searchView>
				<!-- 搜索 -->
				<view class="memberCardInfo" :style="memberCardInfoImg + ';color:' + memberCardHomeInfo.cardTextColor + ';'">
					<view class="memberCardInfoPackage">
						<view class="cardInfoLeft" v-if="card == 'have'">
							<view class="cardInfoLeftTitle">
								<view>
									<image :src="memberCardHomeInfo.info.avatar" />
								</view>
								<view>
									<view>
										<span>{{ memberCardHomeInfo.info.username }}</span>
									</view>
									<view v-if="memberCardHomeInfo.switch_set.levelstatus == '1'" :style="'border:' + '1rpx solid '+ memberCardHomeInfo.cardTextColor + ';'">
										<span>{{ memberCardHomeInfo.info.name }}</span>
									</view>
								</view>
							</view>
							<view class="cardInfoLeftFoot">
								<span>到期时间：{{ memberCardHomeInfo.info.endtime }}</span>
							</view>
							<view v-if="memberCardHomeInfo.info.banknum" class="cardInfoLeftFoot">
								<span>{{examineing==0?'银行卡号':'渠道2号'}}：{{ memberCardHomeInfo.info.banknum }}</span>
							</view>
							<view class="cardInfoLeftFoot1" v-if="!!memberCardHomeInfo.info.cardsn">
								<span>No.{{ memberCardHomeInfo.info.cardsn }}</span>
							</view>
						</view>
						<view class="cardInfoRight" v-if="card == 'have'">
							<view class="cardInfoRightTitle">
								<image :src="imgfixUrls+ 'merchant/qrS.png'" @click="payQrcodeShow = true" />
							</view>
							<view class="cardInfoRightFoot"><span></span></view>
						</view>
						<view class="memberPrice" v-if="card == 'nhave'" :style="'color:' + (memberCardHomeInfo.cardTextColor?memberCardHomeInfo.cardTextColor:'#333333') + ';'">
							<span>开通新的{{ halfcardtext }},享受更多{{ privilege }}</span>
						</view>
					</view>
					<view class="t-r" style="font-size: 26upx;padding-right: 30upx;" v-if="memberCardHomeInfo.payback && card == 'have' && memberCardHomeInfo.credit !== ''">
						{{moneytext}}:<text style="font-weight: 700;">{{memberCardHomeInfo.credit}}元</text>
					</view>
				</view>
			</view>

			<view class="memberEquity">
				<view class="memberEquityPackage">
					<view class="memberEquityTitle" v-if="card == 'have' && memberCardHomeInfo.switch_set.statistics == '1'">
						<view class="memberEquityMoney">
							<view>
								<span>{{ memberCardHomeInfo.info.total_price }}</span>
							</view>
							<view><span>已消费(元)</span></view>
						</view>
						<view class="line"></view>
						<view class="memberEquityMoney">
							<view>
								<span>{{ memberCardHomeInfo.info.price }}</span>
							</view>
							<view><span>已为您节省(元)</span></view>
						</view>
					</view>
					<view :class="card == 'have' ? 'memberEquityBody' : 'nMargin'">
						<view class="equityBodyTitle">
							<image :src="equityMemberImg" />
						</view>
						<view class="equityBodyFoot">
							<view v-for="(item, index) in memberCardHomeInfo.list" @click="goEquity(item.link)">
								<view>
									<image :src="item.thumb" />
								</view>
								<view>
									<span :style="colorEquity[index]">{{ item.name }}</span>
								</view>
							</view>
						</view>
					</view>
					<!-- <view class="renewButton" @click="goGetMember" v-if="textObj.flag074 == 1"><span>拥军专属优待卡</span></view> -->
					<view class="renewButton" @click="goGetMember" v-if="card == 'have'"><span>{{textObj.hljxftext}}</span></view>
					<view class="renewButton" @click="goGetMember" v-else-if="card == 'nhave'"><span>{{textObj.hljkttext}}</span></view>
				</view>
			</view>
			<view class="equity" v-if="memberCardHomeInfo.nodescribe">
				<view class="f-34 f-w t-c" style="padding-bottom: 20upx;">
					非会员权益说明
				</view>
				<!-- <rich-text :nodes="memberCardHomeInfo.nodescribe"></rich-text> -->
				<jyf-parser domain="https://6874-html-foe72-1259071903.tcb.qcloud.la" gesture-zoom lazy-load ref="article"
				 selectable show-with-animation use-anchor :html="memberCardHomeInfo.nodescribe"></jyf-parser>
			</view>
			<view class="discount" v-if="memberCardHomeInfo.switch_set.option_switch === 1 && memberCardHomeInfo.unshowtab != '1'">
				<view class="discountPackage">
					<view class="discountTitle" scroll-x="true">
						<!-- <view :class="[isActive == index ? 'acactiveClass' : 'errorClass']" @click="checkDiscount(index, item.type,item['sort'])"
						 v-if="item.status == 1" v-for="(item, index) in tabBarSetList">
							<span>{{ item.name }}</span>
							<view></view>
						</view> -->
						<v-tabs
						:lineScale="0.3" 
						:lineRadius="'100rpx'" 
						:lineHeight="'6rpx'" 
						:fontSize="'28rpx'" 
						:paddingItem="'0 22rpx 20rpx'" 
						:activeColor="'#FCDB36'" 
						:lineColor="'#FCDB36'"
						v-model="sort" 
						:scroll="true"
						field="name"
						@change="vtabschange"
						:tabs="tabBarSetList">
						</v-tabs>
					</view>
					<view class="discountBdoy"></view>
					<view class="mbTwoTitle" v-if="(type == 'zk' || memberCardHomeInfo.moreset == 1) && type !== 'pr'">
						<view :class="[mbTwoChecks == index ? 'mbTwoCheck' : 'mbTwoNCheck']" @click="checkMbTwoData(index, item.timeData,type)"
						 v-for="(item, index) in timeList">
							<view>
								<span>{{ weekList[index] }}</span>
							</view>
							<view>
								<span>{{ timeList[index].time }}</span>
							</view>
						</view>
					</view>
					<view class="mbThreeTitle1" v-if=" ((type == 'pr' && memberCardHomeInfo.switch_set.halfcard == '1') || memberCardHomeInfo.moreset == 1) && type !== 'lb'">
						<view>
							<view :class="[mbPr == 0 ? 'mbThreeCheck' : 'mbThreeNCheck']" @click="checkPr(0, '',type)"><span>全部</span></view>
							<view :class="[mbPr == index + 1 ? 'mbThreeCheck' : 'mbThreeNCheck']" @click="checkPr(index + 1, item.id,type)" v-for="(item, index) in homeList">
								<span>{{ item.name }}</span>
							</view>
						</view>
					</view>
					<view class="mbThreeTitle1" v-if=" !!memberCardHomeInfo.switch_set && memberCardHomeInfo.switch_set.package == '1' && type == 'lb'">
						<view>
							<view :class="[mbThreeChecks == 0 ? 'mbThreeCheck' : 'mbThreeNCheck']" @click="checkMbThree(0, '')"><span>全部</span></view>
							<view :class="[mbThreeChecks == index + 1 ? 'mbThreeCheck' : 'mbThreeNCheck']" @click="checkMbThree(index + 1, item.id)"
							 v-for="(item, index) in homeList">
								<span>{{ item.name }}</span>
							</view>
						</view>
					</view>
				</view>
			</view>
			<view v-if="memberCardHomeInfo.switch_set.option_switch === 1 && memberCardHomeInfo.unshowtab != '1'">
				<!-- 特权折扣 -->
				<view class="mbPackage" v-if="type == 'qg'">
					<!-- 特权折扣循环模板 -->
					<view class="mbOne " v-for="(item, index) in qgList">
						<view class="mbOneImg">
							<image :src="item.logo" />
						</view>
						<view class="mbOneInfo">
							<view class="mbOneInfoPackage">
								<veiw class="mbOneInfoTitle">
									<span>{{ item.goods_name }}</span>
									<!-- <span>关注</span> -->
								</veiw>
								<veiw class="mbOneInfoBody">
									<span>{{ item.storename }}</span>
								</veiw>
								<veiw class="mbOneInfoFoot">
									<view class="mbOneInfoFootLeft">
										<view>
											<span>¥{{ item.price }}</span>
										</view>
										<view>
											<view :style="{ width: item.buy_percentage + '%' }"></view>
											<view>
												<span>已售{{ item.buy_num }}份</span>
												<span>{{ item.buy_percentage }}%</span>
											</view>
										</view>
									</view>
									<view class="mbOneInfoFootRight" @click="go(item.url,item)">去购买</view>
								</veiw>
							</view>
						</view>
					</view>
					<!-- 特权折扣循环模板 -->
				</view>
				
				<!-- 拼团 -->
				<view class="mbPackage" v-if="type == 'pt'">
					<!-- 特权折扣循环模板 -->
					<view class="mbOne " v-for="(item, index) in ptList">
						<view class="mbOneImg" style="position: relative;">
							<image :src="item.logo" />
							<view class="mbOneImgtext" >
								拼团
							</view>
						</view>
						<view class="mbOneInfo" style="position: relative;">
							<view class="f-30">
								{{item.goods_name}}
							</view>
							<view  style="padding-top: 10upx;">
								<view class="dis-il-block" style="padding: 3upx;border-radius: 5upx;background-color: #FFF6F6;color: #FF4444;font-size: 24upx;">
									已团{{item.buy_num}}人
								</view>
								<view class="dis-il-block" style="padding: 1upx 10upx;border: 1upx solid #FF4444;color: #FF4444;margin-left: 10upx;font-size: 24upx;border-radius: 8upx;">
									{{item.peoplenum}}人团
								</view>
							</view>
							<view class="f-36" style="color: #FF4444;padding-top: 10upx;">
								<text style="font-size: 20upx;">¥</text>{{item.price}}
							</view>
							<view class="f-24" style="color: #999999; text-decoration:line-through;padding-top: 10upx;">
								市场价:{{item.oldprice}}
								<view class="t-c" @click="go(item.url,item)" style="height: 50upx;line-height: 50upx;width: 130upx;border-radius: 60upx;color: #FFFFFF;background-color: #FF4444;position: absolute;bottom: 0upx;right: 0upx;">
									去拼团
								</view>
							</view>
						</view>
					</view>
					<!-- 特权折扣循环模板 -->
				</view>
				
				<!-- 砍价 -->
				<view class="mbPackage" v-if="type == 'kj'">
					<!-- 特权折扣循环模板 -->
					<view class="mbOne " v-for="(item, index) in kjList">
						<view class="mbOneImg" style="position: relative;">
							<image :src="item.logo" />
							<view class="mbOneImgtext" >
								砍价
							</view>
						</view>
						<view class="mbOneInfo" style="position: relative;">
							<view class="f-30">
								{{item.goods_name}}
							</view>
							<view class="f-24" style="padding-top: 10upx;color: #999999;">
								{{item.buy_num}}人砍价成功
							</view>
							<view class="f-36" style="color: #FF4444;padding-top: 10upx;">
								<text style="font-size: 20upx;">可砍至¥</text>{{item.price}}
							</view>
							<view class="f-24" style="color: #999999; text-decoration:line-through;padding-top: 10upx;">
								市场价:{{item.oldprice}}
								<view class="t-c" @click="go(item.url,item)" style="height: 50upx;line-height: 50upx;width: 130upx;border-radius: 60upx;color: #FFFFFF;background-color: #FF4444;position: absolute;bottom: 0upx;right: 0upx;">
									去砍价
								</view>
							</view>
						</view>
					</view>
					<!-- 特权折扣循环模板 -->
				</view>
				
				<view class="mbPackage" v-if="type == 'kq'">
					<!-- 特权折扣循环模板 -->
					<view class="mbOne " v-for="(item, index) in kqList">
						<view class="mbOneImg">
							<image :src="item.logo" />
						</view>
						<view class="mbOneInfo">
							<view class="mbOneInfoPackage">
								<veiw class="mbOneInfoTitle">
									<span>{{ item.goods_name }}</span>
									<!-- <span>关注</span> -->
								</veiw>
								<veiw class="mbOneInfoFoot">
									<view class="mbOneInfoFootLeft">
										<view>
											<span>¥{{ item.price }}</span>
										</view>
										<view>
											<view :style="{ width: item.buy_percentage + '%' }"></view>
											<view>
												<span>已售{{ item.buy_num }}份</span>
												<span>{{ item.buy_percentage }}%</span>
											</view>
										</view>
									</view>
									<view class="mbOneInfoFootRight" @click="go(item.url,item)">
										{{ item.price == '0' ? '去领取' : '去购买' }}
									</view>
								</veiw>
							</view>
						</view>
					</view>
					<!-- 特权折扣循环模板 -->
				</view>
				<!-- 折扣 -->
				<view class="mbPackage" v-if="type == 'pr' || type == 'zk'">
					<view class="mbTwoPackage">
						<!-- 特权折扣日期模板 -->

						<!-- 特权折扣日期模板 -->
						<!-- 折扣循环模板 -->
						<view class="mbTwo" v-for="(item, index) in zkList" @click="goshop(item.shop_url,item.url)">
							<view class="mbTwoImg">
								<image :src="item.logo" />
							</view>
							<view class="mbTwoInfo">
								<view class="mbOneInfoPackage">
									<view class="mbTwoInfoTitle">
										<span>{{ item.name }}</span>
										<view>
											<image src="" />
											<span>{{ item.distance }}</span>
										</view>
									</view>
									<view class="mbTwoInfoBody">
										<span>{{ item.limit }}</span>
									</view>
									<view class="dis-flex f-24" style="position: relative;margin-top: 15upx;font-family: '黑体';" v-if="(users.halfcardflag == 0 && platformInfor.newpayonline == 1) || !platformInfor.newpayonline"><view class="dis-il-block" style="background-color: #E8C977;height: 40upx;line-height: 40upx;padding-left: 20upx;border-radius: 60upx 0upx 0upx 60upx;color: #333333;padding: 0 3upx 0 15upx;letter-spacing:2upx;">会员</view><view  style="position: relative;">	<view class="dis-il-block"	style="width: 0;	height: 0;	border-bottom: 40upx solid #E8C977;	border-right: 8upx solid transparent;	position: absolute;	left: 0;">	</view>	<view class="dis-il-block" 	style="width: 0;	height: 0;	border-top: 40upx solid #484743;	border-left: 8upx solid transparent;	position: absolute;	left: 0;">	</view></view><view class="dis-il-block" style="background-color: #484743;margin-left: 4upx;height: 40upx;line-height: 40upx;padding-right: 10upx;border-radius: 0upx 60upx 60upx 0upx;color: #FFFFFF;letter-spacing: 2upx;padding-left: 4upx;">	{{item.lowtip==1?'最低立享':'立享'}}	<text style="font-size: 24upx;">{{!platformInfor.newpayonline?item.discount:item.activediscount}}</text>折</view></view>
									<view class="mbTwoInfoFoot" :style="{marginTop: (users.halfcardflag == 0)?'0upx':'20upx'}" v-if="platformInfor.newpayonline == 1 && users.halfcardflag == 0 && token">
										<span>
											{{ item.discount }}
											<span>折</span>
										</span>
										<view @click.stop="getInfo(item.is_link, item.id, 0, item.url, item.use_where, item.payonline, item.sid)"><span>去买单</span></view>
									</view>
									<view class="mbTwoInfoFoot" :style="{marginTop: (users.halfcardflag == 0)?'0upx':'20upx'}" v-if="platformInfor.newpayonline == 1 && users.halfcardflag !== 0 && token">
										<span>
											{{ item.discount }}
											<span>折</span>
										</span>
										<view @click.stop="getInfo(item.is_link, item.id, 0, item.url, item.use_where, item.payonline, item.sid)"><span>去买单</span></view>
									</view>
									<view class="mbTwoInfoFoot" :style="{marginTop: (users.halfcardflag == 0)?'0upx':'20upx'}" v-if="platformInfor.newpayonline == 1 && !token">
										<span>
											{{ item.discount }}
											<span>折</span>
										</span>
										<view @click.stop="getInfo(item.is_link, item.id, 0, item.url, item.use_where, item.payonline, item.sid)"><span>去买单</span></view>
									</view>
									<view class="mbTwoInfoFoot" :style="{marginTop: (users.halfcardflag == 0)?'0upx':'20upx'}" v-if="!platformInfor.newpayonline">
										<span>
											<!-- {{ item.discount }} -->
											<span></span>
										</span>
										<view @click.stop="getInfo(item.is_link, item.id, 0, item.url, item.use_where, item.payonline, item.sid)"><span>去买单</span></view>
									</view>
									<!-- <view class="mbTwoInfoFoot" :style="{marginTop: (users.halfcardflag == 0)?'0upx':'20upx'}" v-else>
										<span>
											{{ item.discount }}
											<span>折</span>
										</span>
										<view @click.stop="getInfo(item.is_link, item.id, 0, item.url, item.use_where, item.payonline, item.sid)"><span>去买单</span></view>
									</view> -->
								</view>
							</view>
						</view>
						<!-- 折扣循环模板 -->
					</view>
				</view>
				<!-- 折扣 -->

				<!-- 免费礼包 -->
				<view class="mbPackage" v-if="type == 'lb'">
					<view class="mbTwoPackage">
						<view class="mbTwoBody">
							<!-- 免费礼包循环模板 -->
							<block v-for="(item, index) in lbList" :key="index" @click="goshop(item.shop_url.item.url)">
								<view class="mbThree " v-if="item.surplus != '0'">
									<view class="mbThreeTitle">
										<span>{{ item.name }}</span>
										<span>价值{{ item.price }}元</span>
									</view>
									<view class="mbThreeBody" v-if="item.exttype==='0'">
										<text v-if="item.datestatus == '1'">共{{ item.usetimes }}次</text>
										<text v-else-if="item.datestatus == '2'">每周{{ item.usetimes }}次</text>
										<text v-else-if="item.datestatus == '3'">每月{{ item.usetimes }}次</text>
										<text v-else-if="item.datestatus == '4'">每年{{ item.usetimes }}次</text>
										<text v-else></text>
										<text>
											
											当前剩余{{ item.surplus }}次
										</text>
									</view>
									<view class="mbThreeFoot">
										<view class="mbThreeFootLeft">
											<view>
												<image :src="item.shop_logo" />
											</view>
											<span v-if="item.storename">{{ item.storename }}</span>
										</view>
										<view v-if="!item.nolevel" class="mbThreeFootRight" @click.stop="getInfo(item.is_link, item.id, 1, item.url, item.use_where, item.payonline, item.id)">
											<span>去使用</span>
										</view>
										<view v-if="item.nolevel == 1" class="mbThreeFootRight" style="background-color: #999999;width: 220upx;"><span
											 style="color: #FFFFFF;">当前等级无法使用</span></view>
									</view>
								</view>
							</block>
							<!-- 免费礼包循环模板 -->
						</view>
					</view>
				</view>
				<!-- 免费礼包 -->

				<!-- 积分购买 -->
				<view class="mbPackage" v-if="type == 'jf'">
					<view class="mbFour " v-for="(item, index) in jfList"> 
						<view class="mbFourImg">
							<image :src="item.thumb" />
						</view>
						<view class="mbFourInfo">
							<view class="mbOneInfoPackage">
								<view class="mbFourInfoTitle">
									<span>{{ item.title }}</span>
								</view>
								<view class="mbFourInfoFoot">
									<view class="mbFourInfoFootLeft">
										<view>
											<span>{{ item.use_credit1 }}<text v-if="credittext">{{credittext}}</text><text v-else>{{credittext}}</text>
												+ {{ item.use_credit2 }}元</span>
										</view>
										<view>
											<span>市场价:{{ item.old_price }}元</span>
										</view>
									</view>
									<view class="mbFourInfoFootRight" @click="go(item.url,item)"><span>去兑换</span></view>
								</view>
							</view>
						</view>
					</view>
				</view>
				<!-- 积分购买 -->

				<!-- 专享卡券 -->
				<view class="mbPackage" v-if="type == 'tg'">
					<view class="mbFive " v-for="(item, index) in tgList">
						<!-- <view class="mbFiveTitle">
							<view><imgfixUrls:src="item.shop_logo" /></view>
							<span>{{ item.storename }}</span>
							<imgfixUrlssrc="" />
						</view> -->
						<view class="mbFiveBody">
							<view class="mbFiveImg">
								<image :src="item.logo" />
							</view>
							<view class="mbFiveInfo">
								<view class="mbFiveInfoTitle">
									<span>{{ item.goods_name }}</span>
								</view>
								<view class="mbFiveInfoBody">
									<span>
										<span>¥</span>
										{{ item.price }}
									</span>
								</view>
								<view class="mbFiveInfoFoot">
									<span style="text-decoration:line-through;">市场价：¥ {{ item.oldprice }}</span>
									<view @click="go(item.url,item)"><span>去购买</span></view>
								</view>
							</view>
						</view>
						<!-- <view class="mbFiveFoot">
							<span>结束时间：{{ item.endtime }}</span>
							
						</view> -->
					</view>
					<!-- 专享卡券 -->
				</view>
				<!-- 特权折扣 -->

				<!-- 填充层 -->
				<loadmore :isMore="isMore" v-if="memberCardHomeInfo.unshowtab!= '1'  "></loadmore>
				
				<view class="full"></view>
			</view>
			<!-- 填充层 -->

			<!-- 卡劵使用弹出框 -->
			<PopManager :show="show" @clickmask="closeShow">
				<view class="popPackage">
					<view class="popMain">
						<view class="popMainTitle">
							<view class="popMainImg">
								<image :src="itemInfo.shop_logo" />
							</view>
							<view class="storeName">
								<span v-if="itemInfo.storename">{{ itemInfo.storename }}</span>
							</view>
							<scroll-view class="storeMeal" :scroll-y="true">
								<text class="scorlltext">{{ itemInfo.limit }}</text>
							</scroll-view>
						</view>
						<view class="radiusDot">
							<view></view>
							<view></view>
						</view>
						<view class="popMainBody">
							<view class="checkPopBotton">
								<view :class="[popChecked == 0 ? 'popCheck' : '']" @click="popChecks(0)"><span>使用</span></view>
								<view :class="[popChecked == 1 ? 'popCheck' : '']" @click="popChecks(1)"><span>说明</span></view>
							</view>
							<view class="qrCodeType" v-if="popChecked == 0">
								<view class="qrCodeTypeTitle" v-if="!!itemInfo.discount">
									<span>{{ itemInfo.discount }}折(特权日)</span>
								</view>
								<view class="qrCode">
									<image :src="itemInfo.qrcode" />
								</view>
								<view class="qrCodeTypeFoot">
									<span>该服务项目由{{ itemInfo.storename }}提供</span>
								</view>
								<view class="f-28 t-c qrCodeAddress" @click="goAddress(itemInfo)">
									{{itemInfo.address}}
									<text class="iconfont icon-location" style="font-size: 26upx;color: #666666;padding-left: 10upx;"></text>
								</view>
							</view>
							<view class="qrCodeType" v-if="popChecked == 1">
								<scroll-view class="qrCodeTypeFoot1" scroll-y>
									<rich-text class="font24 color255" :nodes="itemInfo.describe"></rich-text>
								</scroll-view>
							</view>
						</view>
					</view>
					<view class="closeButton" @click="show = false">
						<image :src="imgfixUrls+ 'merchant/close.png'" />
					</view>
				</view>
			</PopManager>
			<!-- 卡劵使用弹出框 -->

			<!-- 在线买单弹出框 -->
			<PopManager :show="payQrcodeShow" :type="center" @clickmask="closePayQr" v-if="card == 'have'">
				<view class="payQrcodeView">
					<image :src="memberCardHomeInfo.info.qrcode" />
				</view>
			</PopManager>
			<!-- 在线买单弹出框 -->
			
			<!-- 富文本弹出框 -->
			<PopManager :show="showtetx" :type="center" @clickmask="showtetx = false">
				<view class="showtetxDiv">
					<view class="showparserDiv">
						<jyf-parser domain="https://6874-html-foe72-1259071903.tcb.qcloud.la" gesture-zoom lazy-load ref="article"
						 selectable show-with-animation use-anchor :html="exdetail"></jyf-parser>
					</view>
					<view class="showtetxBtn">
						<view class="flex-box tetxcolse"  @click="showtetx = false">
							取消
						</view>
						<view class="flex-box tetxsluo"  @click="shougo">
							确定
						</view>
					</view>
				</view>
				
			</PopManager>
			
			<!-- 弹幕 -->
			<barrage :barrageList="barrageList" v-if="!!memberCardHomeInfo.switch_set && memberCardHomeInfo.switch_set.noticestatus == '1' && barrageType == true"
			 ref="getset" :barrageType="barrageType"></barrage>
			<!-- 弹幕 -->

			<TabBars :tabBarAct="0" :pageType="'17'" />
			<follow  :followShow="followShow" :followType="followType" :followTitleShow="followTitleShow" @clickmask="openQrShow"
			 @closeFollowPop="closeFollowPop" @closeFollowTitle="closeFollowTitle"></follow>
		</scroll-view>
		<!-- 整页加载 -->

		<!-- 整页加载 -->
	</view>
</template>

<script>
	import App from '@/common/js/app.js';
	import util from '@/common/js/util.js';
	import Map from '@/common/js/ms-openMap/openMap.js'
	// #ifdef H5
	import wxApi from '@/common/js/wxApi.js';
	// #endif
	import jyfParser from '@/components/jyf-parser/jyf-parser.vue';
	import PopManager from '@/components/template/PopManager';
	import searchView from '@/components/template/searchView';
	import TabBars from '@/components/template/tabBar';
	import barrage from '@/components/template/barrage';
	import loadmore from '@/components/template/loadmore';
	import loadlogo from '@/components/template/loadlogo';
	import follow from '@/components/template/follow.vue';
	import vTabs from '@/components/v-tabs/v-tabs.vue';

	export default {
		components: {
			PopManager,
			searchView,
			TabBars,
			barrage,
			loadmore,
			loadlogo,
			follow,
			vTabs,
			jyfParser
		},
		data() {
			return {
				showtetx:false,
				followTitleShow: true,
				followShow: false,
				followType: '0',
				privilege: '',
				halfcardtext: '一卡通',
				credittext: '积分',
				scdpText: '',
				center: 'center',
				isActive: 0,
				type: 0,
				mbTwoChecks: 0,
				mbThreeChecks: 0,
				mbPr: 0,
				show: false,
				popChecked: 0,
				memberCardInfoImg: '',
				memberCardHomeInfo: {
					credit: ''
				},
				card: null,
				colorEquity: [],
				zkList: [],
				total: null,
				page: 1,
				cardpa: '',
				timeList: [],
				weekList: ['今日', '明日'],
				time: null,
				jfList: [],
				qgList: [],
				tgList: [],
				ptList:[],
				kjList:[],
				phoneHight: null,
				itemInfo: {},
				homeList: {},
				lbList: [],
				payQrcodeShow: false,
				kqList: [],
				mid: null,
				barrageList: [],
				isMore: true,
				loadingPop: true,
				HomeType: false,
				barrageType: true,
				sortType: "",
				img: '',
				credit2: 0,
				moneytext: '',
				platformInfor: {},
				users:{},
				token:'',
				curLoction:'',
				oldid:'',
				sort:0,
				textObj:{},
				goUrl:'',
				exdetail:'',
				examineing:1,
				equityMemberImg:''
			};
		},
		computed: {
			tabBarSetList() {
				let _this = this,
					option_set = _this.memberCardHomeInfo.option_set;
				if (!!option_set && option_set.length > 0) {
					let newOption_set = [];
					option_set.map(item => {
						if (item.status === '1') {
							newOption_set.push(item);
						}
					});
					return newOption_set;
				}
			}
		},
		onHide() {
			let _this = this;
		},
		onUnload() {
			let _this = this;
			_this.set = _this.$refs['getset'];
			_this.set.clearSet();
		},
		onReady() {
			let _this = this;
		},
		onShow() {
			let _this = this;
			uni.getStorage({
				key: 'TextSubstitution',
				success: function(res) {
					_this.halfcardtext = res.data.halfcardtext;
					_this.privilege = res.data.privilege;
					_this.credittext = res.data.credittext;
					_this.moneytext = res.data.moneytext;
					_this.textObj = res.data;
					_this.examineing = res.data.examineing || 0;
				}
			});
		},
		onLoad(e) {
			let _this = this;
			_this.img = _this.imgfixUrl;
			let TextSubstitution = uni.getStorageSync('TextSubstitution');
						this.examineing = TextSubstitution.examineing || 0;
			uni.getSystemInfo({
				success(res) {
					_this.phoneHight = res.windowHeight + 'px';
				}
			});
			_this.platformInfor = uni.getStorageSync('platformInfor');
			console.log(this.platformInfor.newpayonline,66666,!this.platformInfor.newpayonline)
			// this.platformInfor.newpayonline = 1;
			_this.token = uni.getStorageSync('weliam_user_token');
			
			_this.users = uni.getStorageSync('userinfo');
			_this.curLoction = uni.getStorageSync('curLoction');
			// uni.getStorage({
			// 	key: 'userinfo',
			// 	success: function(res) {
			// 		_this.mid = res.data.mid;
			// 		_this.credit2 = res.data.credit2;
			// 	}
			// });
			if (e.type == 6) {
				// 折扣卡使用信息获取
				let data = {
					id: e.id
				};
				App._post_form('&p=halfcard&do=useDiscountCard', data, res => {
					_this.showPup(res.data.is_link, res.data);
				});
			}
			if (e.type == 4) {
				// 折扣卡使用信息获取
				let data = {
					id: e.id
				};
				App._post_form('&p=halfcard&do=useGiftPackage', data, res => {
					_this.showPup(res.data.is_link, res.data);
				});
			}
			_this.init();
			_this.id = e.id;
			_this.openType = e.type;
		},
		watch: {
			barrageList: {
				handler() {
					let _this = this;
				},
				deep: true
			}
		},
		methods: {
			shougo(){
				App.navigationTo({
					url: this.goUrl
				});
				this.goUrl = '';
			},
			goAddress(item){
				let _this = this;
				// #ifdef MP-WEIXIN
				
						uni.openLocation({
						    latitude: Number(item.lat),
						    longitude: Number(item.lng),
							success: function () {
								console.log('success');
							},
							fail: function () {
								console.log('success');
							},
						})
				
				//#endif
				//#ifdef H5
				wxApi.WxopenLocation(Number(item.lat), Number(item.lng), '', item.address);
				//#endif
				//#ifdef APP-PLUS
				Map.openMap(Number(item.lat),Number(item.lng),item.address,'gcj02')
				//#endif
			},
			vtabschange(e){
				console.log(e);
				this.tabBarSetList.map((item,index)=>{
					if(index == e){
						this.checkDiscount(index, item.type,item['sort'])
					}
				})
			},
			closeFollowTitle() {
				let _this = this;
				_this.followTitleShow = false;
			},
			closeFollowPop() {
				let _this = this;
				_this.followShow = false;
			},
			openQrShow() {
				let _this = this;
				_this.followShow = true;
			},
			clickclick() {
				let _this = this;
				_this.barrageType = false;
				console.info(_this.barrageType);
			},
			closeShow() {
				let _this = this;
				_this.show = false;
			},
			goshop(url,urls){
				if(url.indexOf('sid') == -1){
					if(this.users.halfcardflag == 0){
						App.showError('对不起，您不符合使用要求');
						return
					}
					App.navigationTo({
						url: urls
					});
				}else{
					App.navigationTo({
						url: url
					});
				}
				
			},
			getInfo(islink, id, type, url, use_where, payonline, sid) {
				
				let _this = this;
				if (islink == 1) {
					if (payonline == '1') {
						if (type == '0') {
							if (_this.platformInfor.newpayonline == 1) {
								App.navigationTo({
									url: 'pages/subPages2/newBuyOrder/newBuyOrder?type=' + '' + '&sid=' + sid + '&mid=' + _this.mid
								});
							} else {
								App.navigationTo({
									url: 'pages/subPages2/newBuyOrder/buyOrder?type=' + '' + '&sid=' + sid + '&mid=' + _this.mid
								});
							}
						} else {
							if (_this.platformInfor.newpayonline == 1) {
								// debugger
								App.navigationTo({
									url: 'pages/subPages2/newBuyOrder/newBuyOrder?type=' + '' + '&pack_id=' + sid + '&mid=' + _this.mid
								});
							} else {
								// debugger
								App.navigationTo({
									url: 'pages/subPages2/newBuyOrder/buyOrder?type=' + '' + '&pack_id=' + sid + '&mid=' + _this.mid
								});
							}

						}
					} else {
						if (type == 0) {
							// 折扣卡使用信息获取
							let data = {
								id: id
							};
							App._post_form('&p=halfcard&do=useDiscountCard', data, res => {
								console.log(11111111)
								_this.showPup(res.data.is_link, res.data);
							}, fail => {
								console.log(fail);
								if (fail.data.message == '请先开通会员通') {
									App.navigationTo({
										url: 'pages/mainPages/memberCard/getMembership/getMembership?card=' + _this.card
									});
								}
							});
						}
						if (type == 1) {
							// 折扣卡使用信息获取
							let data = {
								id: id
							};
							App._post_form('&p=halfcard&do=useGiftPackage', data, res => {
								_this.showPup(res.data.is_link, res.data);
							});
						}
					}
				} else {
					if (use_where == 1) {
						App.navigationTo({
							url: url
						});
					} else {
						uni.showModal({
							title: '提示',
							content: '对不起，您不符合使用要求',
							showCancel: false,
							success: function(res) {
								if (res.confirm) {
									console.log('用户点击确定');
								} else if (res.cancel) {
									console.log('用户点击取消');
								}
							}
						});
					}
				}
			},
			init() {
				let _this = this;
				_this.memberCardHome();

				let one = new Date(new Date().setHours(0, 0, 0, 0)) / 1000;
				let week = new Date().getDay();
				for (let a = 0; a < 7; a++) {
					let w = week++;
					if (w > 5) {
						week = 0;
					}
					if (a > 1) {
						_this.weekList.push(_this.getWeek(w));
					}
				}
				for (let i = 0; i < 7; i++) {
					let t = _this.formDat(one + 86400 * i).substring(0, 5);
					let td = one + 86400 * i;
					let data = {
						time: t,
						timeData: td
					};
					_this.timeList.push(data);
					console.info(_this.timeList);
				}
				_this.time = _this.timeList[0].timeData;
				uni.getSystemInfo({
					success(res) {
						_this.phoneHight = res.windowHeight + 'px';
					}
				});
				_this.payBarrageList();
			},
			// 商品购买弹幕获取
			payBarrageList() {
				let _this = this;
				let data = {
					type: 4
				};
				App._post_form('&do=payBarrageList', data, res => {
					_this.barrageList = res.data;
				});
			},
			// 商户分类信息列表
			getHomeList() {
				let _this = this;
				let data = {
					type: 0
				};
				App._post_form('&p=store&do=cateList', data, res => {
					_this.homeList = res.data;
					_this.oldHomeList = res.data;
				});
			},
			// 其他分类获取
			getElseList(type) {
				let _this = this;
				if(type == 'qg'){
					App._post_form('&p=rush&do=cateList', {}, res => {
						_this.homeList = res.data;
					});
				}else if(type == 'tg'){
					App._post_form('&p=groupon&do=cateList', {}, res => {
						_this.homeList = res.data;
					});
				}else if(type == 'jf'){
					App._post_form('&p=consumption&do=cateList', {}, res => {
						_this.homeList = res.data;
					});
				}else if(type == 'pt'){
					App._post_form('&p=wlfightgroup&do=cateList', {}, res => {
						_this.homeList = res.data;
					});
				}else if(type == 'kj'){
					App._post_form('&p=bargain&do=cateList', {}, res => {
						_this.homeList = res.data;
					});
				}else{
					_this.homeList = _this.oldHomeList;
				}
				
			},
			closePayQr() {
				let _this = this;
				_this.payQrcodeShow = false;
			},
			// 权益跳转
			goEquity(url) {
				App.navigationTo({
					url: url
				});
			},
			// 跳转

			go(url,item) {
				if(item.exdetail){
					this.exdetail = item.exdetail;
					this.showtetx = true;
					this.goUrl = url;
					return
				}
				App.navigationTo({
					url: url
				});
			},
			// 列表无限加载
			load() {
				
			},
			formDat(time) {
				return util.formatTime(time, 'normal', '-');
			},
			getWeek(time) {
				if (time == 0) {
					return '周日';
				} else if (time == 1) {
					return '周一';
				} else if (time == 2) {
					return '周二';
				} else if (time == 3) {
					return '周三';
				} else if (time == 4) {
					return '周四';
				} else if (time == 5) {
					return '周五';
				} else if (time == 6) {
					return '周六';
				}
			},
			loadShow() {
				let _this = this;

				console.info('我才刚刚执行');
			},
			// 获取一卡通首页信息
			memberCardHome() {
				let _this = this;
				let data = {};
				App._post_form(
					'&p=halfcard&do=memberCardHome',
					data,
					res => {
						_this.HomeType = true;
						_this.barrageType = true;
						_this.memberCardHomeInfo = res.data;
						// _this.memberCardHomeInfo.moreset = 0;
						let checkType = !!_this.tabBarSetList && _this.tabBarSetList.length > 0 ? _this.tabBarSetList[0].type : 0,
							sortType = !!_this.tabBarSetList && _this.tabBarSetList.length > 0 ? _this.tabBarSetList[0]['sort'] : "";
						_this.sortType = sortType;
						_this.type = checkType;
						if (res.data.switch_set.option_switch === 1) {
							_this.getHomeList();
							_this.checkDiscount(0, checkType, sortType);
						}
						let TextSubstitution = uni.getStorageSync('TextSubstitution');
						if(TextSubstitution.flag074  == 1 && res.data.info.levelarmy == 1){							
							this.equityMemberImg = this.imgfixUrls + 'newmemberImg.png';						
						}else{							
							this.equityMemberImg = this.imageRoot + 'memberImg.png';
							// debugger						
						}
						if (!!res.data.info.id) {
							_this.card = 'have';
							if (res.data.info.cardimg == '') {
								_this.memberCardInfoImg = 'background-image:' + 'url(' + "'" + res.data.info.cardimg + "'" + ')';
							} else {
								_this.memberCardInfoImg = 'background-image:url(' + "'" + res.data.info.cardimg + "'" + ');';
							}
						} else {
							_this.card = 'nhave';
							_this.memberCardInfoImg = 'background-image:' + 'url(' + "'" + res.data.info.cardimg + "'" + ')';
						}
						for (let i = 0; i < res.data.list.length; i++) {
							_this.colorEquity.push('color:' + res.data.list[i].color);
							// console.info(_this.colorEquity);
						}
					},
					fail => {
						// console.info();
						if ( fail.data.message == '一卡通功能已关闭') {
							App.navigationTo({
								url: 'pages/mainPages/index/index'
							});
						}
					}
				);
			},
			goGetMember() {
				let _this = this;
				App.navigationTo({
					url: 'pages/mainPages/memberCard/getMembership/getMembership?card=' + _this.card
				});
			},
			popChecks(id) {
				let _this = this;
				_this.popChecked = id;
			},
			showPup(islink, itemInfo) {
				let _this = this;
				_this.itemInfo = itemInfo;
				if (islink == 1) {
					_this.show = true;
				}
				if (islink == 0) {
					console.info(String(itemInfo.url));
					window.open(itemInfo.url);
				}
			},
			checkPr(index, id,type) {
				let _this = this;
				_this.mbPr = index;
				_this.page = 1;
				_this.isMore = false;
				_this.oldid = id;
				let data = {
					page: _this.page,
					page_index: 5,
					lng: _this.curLoction.longitude,
					lat: _this.curLoction.latitude,
					time:_this.time,
					sort: _this.sortType,
					is_total: 1,
					cate_id: id,
					is_vip: 1
				};
				if(type == 'tg'){
					data.status = 2;
					App._post_form('&p=groupon&do=homeList', data, res => {
						
						if(type == 'tg'){
							_this.tgList = res.data.list;
						}else{
							_this.zkList = res.data.list;
						}
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'jf'){
					data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						time:_this.time,
						sort: _this.sortType,
						cate_id: id,
						is_vip: 1
					};
					App._post_form('&p=consumption&do=homeList', data, res => {
						
						
							_this.jfList = res.data.list;
						
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'kq'){
					App._post_form('&p=wlcoupon&do=homeList', data, res => {
						_this.kqList = res.data.list;
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'qg'){
					App._post_form('&p=rush&do=homeList', data, res => {
						_this.qgList = res.data.list;
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'zk'){
					data.type = 1;
					App._post_form('&p=halfcard&do=homeList', data, res => {
						_this.zkList = res.data.list;
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'pt'){
					App._post_form('&p=wlfightgroup&do=homeList', data, res => {
						_this.ptList = res.data.list;
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else if(type == 'kj'){
					App._post_form('&p=bargain&do=homeList', data, res => {
						_this.kjList = res.data.list;
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}else{
					data.type = 2;
					App._post_form('&p=halfcard&do=homeList', data, res => {
						
						if(type == 'tg'){
							_this.tgList = res.data.list;
						}else{
							_this.zkList = res.data.list;
						}
						_this.total = res.data.total;
						if (_this.page == res.data.total || res.data.total == 0) {
							_this.isMore = true;
						}
					});
				}
				
			},
			checkMbThree(index, id) {
				let _this = this;
				_this.mbThreeChecks = index;
				_this.page = 1;
				_this.isMore = false;
				console.log(123)
				let data = {
					page: _this.page,
					page_index: 5,
					lng: '',
					lat: '',
					status: 1,
					sort: _this.sortType,
					is_total: 1,
					cate_id: id
				};
				App._post_form('&p=halfcard&do=packageList', data, res => {
					_this.lbList = res.data.list;
					_this.total = res.data.total;
					console.info(_this.lbList);
					if (_this.page == res.data.total || res.data.total == 0) {
						_this.isMore = true;
					}
				});
			},
			checkDiscount(index, type, sortType) {
				let _this = this;
				_this.isActive = index;
				_this.page = 1;
				_this.type = type;
				_this.mbPr = 0;
				// _this.mbTwoChecks = 0;
				// _this.time = _this.timeList[0].timeData;
				_this.isMore = false;
				_this.sortType = sortType;
				_this.getElseList(type);
				// 折扣
				if (type == 'zk') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						type: 1,
						time: _this.time,
						sort: sortType,
						is_total: 1
					};
					App._post_form('&p=halfcard&do=homeList', data, res => {
						_this.zkList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 平日折扣
				if (type == 'pr') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						type: 2,
						time: _this.memberCardHomeInfo.moreset == 1?_this.time:'',
						sort: sortType,
						is_total: 1
					};
					App._post_form('&p=halfcard&do=homeList', data, res => {
						_this.zkList = res.data.list;
						_this.total = res.data.total;

						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 积分商品信息列表
				if (type == 'jf') {
					let data = {
						page: _this.page,
						page_index: 5,
						sort: sortType,
						type: '',
						cate_id: '',
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:'',
						is_vip: 1,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
					};
					App._post_form('&p=consumption&do=homeList', data, res => {
						_this.jfList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 抢购
				if (type == 'qg') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status:'',
						sort: sortType,
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:'',
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=rush&do=homeList', data, res => {
						_this.qgList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 拼团
				if (type == 'pt') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status:'',
						sort: sortType,
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:'',
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=wlfightgroup&do=homeList', data, res => {
						_this.ptList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 砍价
				if (type == 'kj') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status:'',
						sort: sortType,
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:'',
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=bargain&do=homeList', data, res => {
						_this.kjList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 团购
				if (type == 'tg') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: 2,
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:'',
						sort: sortType,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=groupon&do=homeList', data, res => {
						for (let i = 0; i < res.data.list.length; i++) {
							res.data.list[i].endtime = util.formatTime(res.data.list[i].endtime, 'rule', '-');
						}
						_this.tgList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 礼包
				if (type == 'lb') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: 1,
						sort: sortType,
						is_total: 1,
						cate_id: '',
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:''
					};
					App._post_form('&p=halfcard&do=packageList', data, res => {
						_this.lbList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
				// 卡劵
				if (type == 'kq') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						sort: sortType,
						is_total: 1,
						is_vip: 1,
						time:_this.memberCardHomeInfo.moreset == 1?_this.time:''
					};
					App._post_form('&p=wlcoupon&do=homeList', data, res => {
						_this.kqList = res.data.list;
						_this.total = res.data.total;
						_this.isMore = res.data.list.length === 0 || _this.page === res.data.total;
					});
				}
			},
			checkMbTwoData(id, time,type) {
				let _this = this;
				_this.mbTwoChecks = id;
				_this.zkList = [];
				_this.page = 1;
				_this.time = time;
				let datas = {
					page: _this.page,
					page_index: 5,
					lng: _this.curLoction.longitude,
					lat: _this.curLoction.latitude,
					type: 1,
					time: time,
					sort: _this.sortType,
					is_total: 1,
					cate_id: _this.oldid
				};
				if(type == 'lb'){
					// _this.lbList = [];
						App._post_form('&p=halfcard&do=packageList', datas, res => {
							_this.lbList = res.data.list;
							_this.total = res.data.total;
							// _this.isMore = true;
							if (res.data.list.length < 5) {
								_this.isMore = true;
								console.log('变成true了', _this.page, _this.total)
							}
						});
				}else{
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						time:_this.time,
						sort: _this.sortType,
						is_total: 1,
						cate_id: _this.oldid,
						is_vip: 1
					};
					if(type == 'tg'){
						data.status = 2;
						App._post_form('&p=groupon&do=homeList', data, res => {
							
							if(type == 'tg'){
								_this.tgList = res.data.list;
							}else{
								_this.zkList = res.data.list;
							}
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type == 'jf'){
						data = {
							page: _this.page,
							page_index: 5,
							lng: _this.curLoction.longitude,
							lat: _this.curLoction.latitude,
							time:_this.time,
							sort: _this.sortType,
							cate_id: id,
							is_vip: 1
						};
						App._post_form('&p=consumption&do=homeList', data, res => {
							
							
								_this.jfList = res.data.list;
							
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type == 'kq'){
						App._post_form('&p=wlcoupon&do=homeList', data, res => {
							
							
								_this.kqList = res.data.list;
							
							
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type == 'qg'){
						App._post_form('&p=rush&do=homeList', data, res => {
							if(type == 'tg'){
								_this.tgList = res.data.list;
							}else{
								_this.qgList = res.data.list;
							}
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type =='zk'){
						data.type = 1;
						App._post_form('&p=halfcard&do=homeList', data, res => {
							
							if(type == 'tg'){
								_this.tgList = res.data.list;
							}else{
								_this.zkList = res.data.list;
							}
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type =='pr'){
						data.type = 2;
						App._post_form('&p=halfcard&do=homeList', data, res => {
							
							if(type == 'tg'){
								_this.tgList = res.data.list;
							}else{
								_this.zkList = res.data.list;
							}
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type =='pt'){
						App._post_form('&p=wlfightgroup&do=homeList', data, res => {
							_this.ptList = res.data.list;
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}else if(type =='kj'){
						App._post_form('&p=bargain&do=homeList', data, res => {
							_this.kjList = res.data.list;
							_this.total = res.data.total;
							if (_this.page == res.data.total || res.data.total == 0) {
								_this.isMore = true;
							}
						});
					}
				};
				
				
			}
		},
		// 页面上拉触底事件的处理函数
		onReachBottom: function() {
			let _this = this,
				type = _this.type,
				sortType = _this.sortType;
				if(_this.total == _this.page){
					_this.isMore = true;
					return
				}
			if (_this.total !== _this.page) {
				_this.page++;
				_this.isMore = false;
				console.log('变成false了', _this.page, _this.total)
				// 折扣
				if (type == 'zk') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						type: 1,
						time: _this.time,
						sort: sortType,
						is_total: 1,
						cate_id: _this.oldid
					};
					App._post_form('&p=halfcard&do=homeList', data, res => {
						_this.zkList = [..._this.zkList, ...res.data.list];
						_this.total = res.data.total;
						// _this.isMore = true;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						};
					});
				}
				// 平日折扣
				if (type == 'pr') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						type: 2,
						time: '',
						sort: sortType,
						is_total: 1,
						cate_id: _this.oldid
					};
					App._post_form('&p=halfcard&do=homeList', data, res => {
						_this.zkList = [..._this.zkList, ...res.data.list];
						_this.total = res.data.total;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
						// _this.isMore = true;
					});
				}
				// 积分商品信息列表
				if (type == 'jf') {
					let data = {
						page: _this.page,
						page_index: 5,
						sort: sortType,
						type: '',
						cate_id: '',
						is_vip: 1,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
					};
					App._post_form('&p=consumption&do=homeList', data, res => {
						_this.jfList = [..._this.jfList, ...res.data.list];
						_this.total = res.data.total;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
						// _this.isMore = true;
					});
				}
				// 抢购
				// if (type == 'qg') {
				// 	let data = {
				// 		page: _this.page,
				// 		page_index: 5,
				// 		lng: _this.curLoction.longitude,
				// 		lat: _this.curLoction.latitude,
				// 		status: '',
				// 		sort: sortType,
				// 		is_total: 1,
				// 		is_vip: 1
				// 	};
				// 	App._post_form('&p=rush&do=homeList', data, res => {
				// 		_this.qgList = [..._this.qgList, ...res.data.list];
				// 		_this.total = res.data.total;
				// 		console.log()
				// 		if (res.data.list.length < 5) {
				// 			_this.isMore = true;
				// 			console.log('变成true了', _this.page, _this.total)
				// 		}
				// 		// _this.isMore = true;
				// 	});
				// }// 抢购
				if (type == 'qg') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: '',
						cate_id: _this.oldid,
						sort: sortType,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=rush&do=homeList', data, res => {
						_this.qgList = [..._this.qgList, ...res.data.list];
						_this.total = res.data.total;
						console.log()
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
						// _this.isMore = true;
					});
				}
				// 拼团
				if (type == 'pt') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: '',
						cate_id: _this.oldid,
						sort: sortType,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=wlfightgroup&do=homeList', data, res => {
						_this.ptList = [..._this.qgList, ...res.data.list];
						_this.total = res.data.total;
						console.log()
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
						// _this.isMore = true;
					});
				}
				// 砍价
				if (type == 'kj') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: '',
						cate_id: _this.oldid,
						sort: sortType,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=bargain&do=homeList', data, res => {
						// _this.kjList.concat(_this.kjList,res.data.list)
						_this.kjList = [..._this.kjList, ...res.data.list];
						// _this.qgList = res.data.list;
						_this.total = res.data.total;
						console.log(_this.kjList,'抢购下拉加载');
						if (res.data.list.length < 5) {
							_this.isMore = true;
						}
						// _this.isMore = true;
					});
				}
				// 团购
				if (type == 'tg') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: 2,
						cate_id: _this.oldid,
						sort: sortType,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=groupon&do=homeList', data, res => {
						for (let i = 0; i < res.data.list.length; i++) {
							res.data.list[i].endtime = util.formatTime(res.data.list[i].endtime, 'rule', '-');
						}
						_this.tgList = [..._this.tgList, ...res.data.list];
						_this.total = res.data.total;
						// _this.isMore = true;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
					});
				}
				// 礼包
				if (type == 'lb') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						status: 1,
						sort: sortType,
						is_total: 1,
						cate_id: ''
					};
					App._post_form('&p=halfcard&do=packageList', data, res => {
						_this.lbList = [..._this.lbList, ...res.data.list];
						_this.total = res.data.total;
						// _this.isMore = true;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
					});
				}
				// 卡劵
				if (type == 'kq') {
					let data = {
						page: _this.page,
						page_index: 5,
						lng: _this.curLoction.longitude,
						lat: _this.curLoction.latitude,
						sort: sortType,
						cate_id: _this.oldid,
						is_total: 1,
						is_vip: 1
					};
					App._post_form('&p=wlcoupon&do=homeList', data, res => {
						_this.kqList = [..._this.kqList, ...res.data.list];
						_this.total = res.data.total;
						// _this.isMore = true;
						if (res.data.list.length < 5) {
							_this.isMore = true;
							console.log('变成true了', _this.page, _this.total)
						}
					});
				}
			}
		}
	};
</script>

<style lang="less" scoped>
	@import '../memberCard/memberCard.less';

	.memberCard {
		background: #f6f6f6 !important;
		overflow-x: hidden;
	}

	.tips {
		height: 180upx;
		text-align: center;

		>span {
			line-height: 80upx;
			font-size: 28upx;
			color: black;
		}
	}

	.backW {
		background: #ffffff;
	}
	.equity{
		padding: 30upx;
		overflow: auto;
		margin: 30upx;
		border-radius: 10upx;
		background-color: #FFFFFF;
		width: 630upx;
		min-height: 350upx;
	}
</style>
