<template>
	<view class="">

		<view class="flex align-center "
			style="background-color: #FFFFFF; height: 100rpx; border-bottom: 1rpx #EEEEEE solid; ">

			<u-icon name='arrow-left' class="right_icon" style="margin-left: 33rpx;" size="40" @tap="navigateBack">
			</u-icon>
			<view class=""
				style="color: #111;font-size: 34rpx;font-weight: bold;margin-left: 15rpx;margin-right: 20rpx;">
				{{headerTittle}}
			</view>
			<view @click="gotoSearch" class="flex align-center"
				style="background-color: #F5F6F7;flex:1;height: 70rpx;margin-left: 60rpx;margin-right: 20rpx; border-radius: 34rpx;color: #999999;">
				<image src="../../../static/home_search_icon.png" mode=""
					style="width: 30rpx; height: 30rpx;margin-left: 30rpx;"></image>
				<view class="" style="margin-left: 10rpx;">
					<!-- <input  type="text" placeholder="请搜索" /> -->
					请搜索
				</view>
			</view>
		</view>
		<view>
			<scroll-view scroll-x="true" style="white-space: nowrap; padding: 35rpx 25rpx;">
				<view @click="selectHeadClick(index)" v-for="(item,index) in headerList" :key="item.id"
					style="display: inline-block; margin-right: 40rpx;">
					<view>
						<image :src="item.icon" mode="aspectFill"
							style="width: 100rpx;height: 100rpx;border-radius: 50%;"></image>
					</view>
					<view v-if="currentIndex == index"
						style="margin-top: 10rpx;font-size: 24rpx;color: #FC6035;font-weight: bold;text-align: center;">
						{{item.categoryName}}
					</view>
					<view v-else
						style="margin-top: 10rpx;font-size: 22rpx;color: #666666;font-weight: 500;text-align: center;">
						{{item.categoryName}}
					</view>
				</view>
			</scroll-view>
		</view>
		<view class="" style="background-color: #FFFFFF; margin-top:1rpx;">
			<view class="u-tabs-box padding-bottom-sm" :style="[{width:$bizType=='2'?'330rpx':'520rpx'}]">
				<u-tabs-swiper activeColor="#111" inactive-color="#111" ref="tabs" :list="serviceNameList"
					:current="current" @change="change" :is-scroll="false" :bar-style="barStyle"
					:active-item-style='activeitemstyle'>
				</u-tabs-swiper>
			</view>
			<scroll-view scroll-y="true" style="height:calc(100vh - 100rpx - 216rpx - 80rpx)" @scrolltolower='getChannelContentList(currentIndex)'>
				<view v-if="canLoadData&&!groupBuy" class="" style="">
					<view class="" v-if="headerList[currentIndex].childList[listCurrent].length>0">
						<view v-for="(contentItem,index) in headerList[currentIndex].childList[listCurrent]" :key="index" class="flex align-start" style="margin-left: 25rpx;margin-right: 25rpx;"
							@click="onCardClick(contentItem)" :class="listCurrent=='0'?'margin-top-sm':''">
							<view style="position: relative;" :style="{height:listCurrent==1?'224rpx':''}" :class="listCurrent==1?'flex align-center':''">
								<view v-if="listCurrent==0" :class="{'presonal_auth':contentItem.merchantType ==1, 'company_auth':contentItem.merchantType ==0}" style="position: absolute; top: 0;left: 0;z-index: 2;">
									{{contentItem.merchantType ==1?"个人认证":"企业认证"}}
								</view>

                                <image style="width: 240rpx; height: 180rpx; border-radius: 10rpx;" mode="aspectFill" v-if="!$isNull(contentItem.serverImgUrl)"
                                :src="contentItem.serverImgUrl"></image>

                                <image style="width: 240rpx; height: 180rpx; border-radius: 10rpx;" mode="aspectFill" v-if="listCurrent==0&&contentItem.goodsImageList[0].type=='001'&&$isNull(contentItem.serverImgUrl)"
                                :src="contentItem.goodsImageList[0].url"></image>
                                <image style="width: 240rpx; height: 180rpx; border-radius: 10rpx;" mode="aspectFill" v-if="listCurrent==0&&contentItem.goodsImageList[0].type=='002'&&$isNull(contentItem.serverImgUrl)"
                                :src="contentItem.goodsImageList[0].url+'?x-oss-process=video/snapshot,t_1000,f_jpg,w_0,h_0,m_fast,ar_auto'"></image>
                                <image src='../../../static/video.png' class="video-play-position" v-if="listCurrent==0&&contentItem.goodsImageList[0].type=='002'&&$isNull(contentItem.serverImgUrl)"></image>

								<image style="width: 240rpx; height: 180rpx; border-radius: 10rpx;" mode="aspectFill" :src="contentItem.avatar" v-if="listCurrent==1"></image>
							</view>
                            <view class="flex-sub padding-right">

							<view style="margin:0 0 24rpx 20rpx; width: 100%; display: flex;flex-direction: column;justify-content: space-between;word-break:break-all">
								<view class="wb_hide_2 font-weight6" v-if="listCurrent==0">{{contentItem.name}}</view>
                                <view class="wb_hide_2 margin-top-sm font-weight6" v-if="listCurrent==1">{{contentItem.merchantName}}</view>

                                <view style="margin-top: 15rpx;" class="flex align-center" v-if="listCurrent==0">
                                    <view class="age_tag"> {{contentItem.serverAge}}年工龄</view>
                                    <view class="content_comment" v-if="contentItem.rate>0">好评率{{contentItem.rate}}%</view>
                                </view>

                                <view style="margin-top: 15rpx;" class="flex align-center justify-between" v-if="listCurrent==1">
                                    <view class="age_tag"> {{contentItem.storeAge}}年店龄</view>
                                    <view>成交{{contentItem.sales}}单</view>
                                </view>

                                <view style="margin-top: 15rpx;" class="flex align-center justify-between" v-if="listCurrent==1">
                                    <view style="color:#FF481E;font-size:22rpx;" v-if="contentItem.score != '' && contentItem.score > 0"> 综合评分： <span style="font-size: 24rpx;" class="text-bold">{{contentItem.score}}</span> </view>
                                    <view class="content_comment" v-if="contentItem.rate>0">好评率{{contentItem.rate}}%</view>
                                </view>


								<view v-if="listCurrent == 0" class="flex align-center justify-between" style="margin-top: 6rpx;">
									<view class="flex flex-sub align-center">
										<text style="color: #111111; font-size: 24rpx;font-weight: 500;" class="break-word">{{contentItem.realName}}</text>
										<text v-if="contentItem.serverLevel == '001'" class="flex-sub" style="color: #D09A6C; font-size: 24rpx;margin-left: 20rpx;font-weight: 500;min-width:100rpx;">初级家政</text>
										<text v-else-if="contentItem.serverLevel == '002'" class="flex-sub" style="color: #D09A6C; font-size: 24rpx;margin-left: 20rpx;font-weight: 500;min-width:100rpx;">中级家政</text>
										<text v-else-if="contentItem.serverLevel == '003'" class="flex-sub" style="color: #D09A6C; font-size: 24rpx;margin-left: 20rpx;font-weight: 500;min-width:100rpx;">高级家政</text>
										<text v-else-if="contentItem.serverLevel == '004'" class="flex-sub" style="color: #D09A6C; font-size: 24rpx;margin-left: 20rpx;font-weight: 500;min-width:100rpx;">金牌家政</text>
									</view>
									<view class="flex align-center font-26 color-ff0" style="margin-top: 6rpx;">
                                        <span class="text-sm font-weight5">￥</span>
										<text style="font-size: 32rpx;margin-right:6rpx;" class="font-weight5">{{contentItem.goodsServerPrice}}</text>/{{contentItem.goodsUnit == "999"?contentItem.otherUnit:contentItem.goodsUnitName}}
									</view>
								</view>
                                 
								<view v-if="contentItem.merchantType  == 0&&listCurrent==0" style="margin-top: 10rpx;">
									<text style="font-size: 22rpx;color: #999999;"
										class="wb_hide_2">{{contentItem.merchantName}}</text>
								</view>
							</view>
                            <view style="margin-left: 20rpx; width: 100%;" v-if="listCurrent==1">
                                <view v-for="(good,goodIndex) in contentItem.goodsList" :key="good.goodsId">
                                    <view v-if="goodIndex<2" style="border-top: 2rpx solid #eee;" class="padding-top-sm" @tap.stop="serveDetail(good,good.isGroupGoods)">
                                        <view class="flex align-center">
                                            <image src="../../../static/group.png" style="width:36rpx;height:36rpx;left:0;top:0;margin-right:10rpx;" v-if="good.isGroupGoods==1"></image>
                                            <image src="../../../static/reserve.png" style="width:36rpx;height:36rpx;left:0;top:0;margin-right:10rpx;" v-if="good.isGroupGoods==0&&$bizType == 1"></image>
                                            <view style="white-space: nowrap;overflow: hidden;text-overflow: ellipsis;max-width: 380rpx;">{{good.name}}</view>
                                        </view>
                                        <view class="flex align-center" style="margin: 18rpx 0;" v-if="good.isGroupGoods==1">
                                            <view style="" class="font-weight5 text-lg color-ff0 flex align-center">
                                                <span class="text-sm font-weight5">￥</span>
                                                <span>{{good.currentPrice}}</span>
                                            </view>
                                            <view style="margin-left: 16rpx; text-decoration:line-through;color: #999;font-size: 26rpx; text-align: left;">
                                                <span>￥</span>{{good.scribingPrice}}
                                            </view>
                                        </view>
                                        <view style="margin: 18rpx 0;" class="flex flex-sub text-lg color-ff0 align-center" v-if="good.isGroupGoods==0">
                                            <span class="text-sm font-weight5">￥</span>
                                            <span class="font-weight5" style="margin-right:8rpx;">{{good.goodsServerPrice}}</span>
                                            <span style="font-size: 26rpx;">/{{good.goodsUnit == "999"?good.otherUnit:good.goodsUnitName}}</span>
                                        </view>
                                    </view>
                                    
                                </view>
                            </view>
                        </view>
						</view>

						<u-loadmore v-if="headerList[currentIndex].pageParam[listCurrent].showLoadMore" :margin-top="30" style="padding-bottom:20rpx;"
							:status="headerList[currentIndex].pageParam[listCurrent].status"  @loadmore="getChannelContentList(currentIndex)"/>
					</view>
					<view class=" flex align-center" v-else style="width: 100vw;">
						<image src="../../../static/nomore_icon.png" mode="" v-if="!emptyLoading"
							style="width: 370rpx;height: 370rpx;position: absolute;top:calc(50% - 185rpx) ;left:calc(50% - 185rpx);">
						</image>
                        <view class="flex flex-direction align-center justify-center" style="width:100%;margin-top:calc(50% - 185rpx);" v-if="emptyLoading">
                            <image src="../../../static/empty-loading.png" mode="" style="width: 256rpx;height: 158rpx;"></image>
                            <view style="color:#3A3A3A;font-size;34rpx;margin-top:46rpx;">加载中...</view>
                        </view>
					</view>
				</view>

                <view v-if="canLoadData&&groupBuy" style="min-height:100%;background:#f6f6f6;padding-bottom:20rpx;">
                    <u-waterfall v-model="flowList" ref="uWaterfall" style="padding-left:18rpx;">
                        <template v-slot:left="{leftList}">
                            <view @click="gotoDetails(item)" class="demo-warter" v-for="(item, index) in leftList" :key="index">
                                <view style="position: relative;">
                                    <u-lazy-load threshold="-450" borderRadiusLRTB="20rpx 20rpx 0 0" :height="260" img-mode="aspectFill" v-if="item.goodsImageList[0].type=='001'" loading-img="../../../static/lazy-loading.png"
                                    :image="item.goodsImageList[0].url" :index="index"></u-lazy-load>

                                    <u-lazy-load threshold="-450" borderRadiusLRTB="20rpx 20rpx 0 0" :height="260" img-mode="aspectFill" v-if="item.goodsImageList[0].type=='002'" loading-img="../../../static/lazy-loading.png"
                                    :image="item.goodsImageList[0].url+'?x-oss-process=video/snapshot,t_1000,f_jpg,w_0,h_0,m_fast,ar_auto'" :index="index"></u-lazy-load>
                                    <image src='../../../static/video.png' class="video-play-position" v-if="item.goodsImageList[0].type=='002'"></image>
                                </view>

                                <view class="padding-lr-sm padding-bottom">
                                    <view class="demo-title break-word wb_hide_2 font-weight6">
                                        {{item.name}}
                                    </view>
                                    <view v-if="item.rate>0" style="margin-top: 20rpx;color:#FF0000; font-size: 22rpx;" class="flex align-center justify-center rate-box">
                                        <view style=" text-align: left;">好评率</view>
                                        <view style="margin-left:6rpx;margin-top:4rpx;">{{item.rate}}%</view>
                                    </view>
                                    <view style="margin-top: 20rpx;" class="flex align-center flex-wrap">
                                        <view class="color-ff0 text-lg font-weight5 flex align-center">
                                            <span class="text-sm">￥</span>
                                            <span>{{item.currentPrice}}</span>
                                        </view>
                                        <view style="margin-left: 16rpx; text-decoration:line-through;color: #999;font-size: 26rpx; text-align: left;">
                                            <span>￥</span>{{item.scribingPrice}}
                                        </view>
                                    </view>
                                </view>
                            </view>
                        </template>

                        <template v-slot:right="{rightList}">
                            <view @click="gotoDetails(item)" class="demo-warter" v-for="(item, index) in rightList" :key="index">
                                <view style="position: relative;">
                                    <u-lazy-load threshold="-450" borderRadiusLRTB="20rpx 20rpx 0 0" :height="260" img-mode="aspectFill" v-if="item.goodsImageList[0].type=='001'" loading-img="../../../static/lazy-loading.png"
                                    :image="item.goodsImageList[0].url" :index="index"></u-lazy-load>

                                    <u-lazy-load threshold="-450" borderRadiusLRTB="20rpx 20rpx 0 0" :height="260" img-mode="aspectFill" v-if="item.goodsImageList[0].type=='002'" loading-img="../../../static/lazy-loading.png"
                                    :image="item.goodsImageList[0].url+'?x-oss-process=video/snapshot,t_1000,f_jpg,w_0,h_0,m_fast,ar_auto'" :index="index"></u-lazy-load>
                                    <image src='../../../static/video.png' class="video-play-position" v-if="item.goodsImageList[0].type=='002'"></image>
                                </view>
                                <view class="padding-lr-sm padding-bottom">
                                    <view class="demo-title break-word wb_hide_2">
                                        {{item.name}}
                                    </view>
                                    <view v-if="item.rate>0" style="margin-top: 20rpx;color:#FF0000; font-size: 22rpx;" class="flex align-center justify-center rate-box">
                                        <view style=" text-align: left;">好评率</view>
                                        <view style="margin-left:6rpx;margin-top:4rpx;">{{item.rate}}%</view>
                                    </view>
                                    <view style="margin-top: 20rpx;" class="flex align-center flex-wrap">
                                        <view class="color-ff0 text-lg font-weight5 flex align-center">
                                            <span class="text-sm">￥</span>
                                            <span>{{item.currentPrice}}</span>
                                        </view>
                                        <view style="margin-left: 16rpx; text-decoration:line-through;color: #999;font-size: 26rpx; text-align: left;">
                                            <span>￥</span>{{item.scribingPrice}}
                                        </view>
                                    </view>
                                </view>
                            </view>
                        </template>
                    </u-waterfall>
                    
                    <view class=" flex align-center" v-if="flowList.length==0" style="width: 100vw;">
						<image src="../../../static/nomore_icon.png" mode="" v-if="!emptyLoading"
							style="width: 370rpx;height: 370rpx;position: absolute;top:calc(50% - 185rpx) ;left:calc(50% - 185rpx);">
						</image>
                        <view class="flex flex-direction align-center justify-center" style="width:100%;margin-top:calc(50% - 185rpx);" v-if="emptyLoading">
                            <image src="../../../static/empty-loading.png" mode="" style="width: 256rpx;height: 158rpx;"></image>
                            <view style="color:#3A3A3A;font-size;34rpx;margin-top:46rpx;">加载中...</view>
                        </view>
					</view>
                    <u-loadmore v-if="showGroupLoadMore&&flowList.length!=0" :status="groupStatus" :margin-top="20"/>
                </view>

			</scroll-view>




		</view>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				activeitemstyle: {
					'font-size': '34rpx',
					'font-weight': 'blod'
				},
				barStyle: {
					'height': '14rpx',
					'background-color': 'transparent',
					'background-image': "url('../../static/tabbar_icon.png')",
					'background-size': '100% 100%'
				},
				canLoadData: false,
				headerTittle: '',
				currentIndex: 0,
				///临时存储list
				contentList: [{}, {}, {}, {}, {}, {}],
				headerList: [],
				current: 0,
                listCurrent: 0,
				serviceNameList: [],
				servicePersonList: [],
				shopList: [],
				tempList: [],
				lastServerType: -1,
				pageId: '',
                groupBuy: this.$bizType=='1',
                flowList: [],
                showGroupLoadMore: false,
                groupStatus: "loading",
                groupPageNum: 1,
                groupPageSize: 10,
                emptyLoading: true,
			}
		},
        
		onLoad(options) {
			// console.log(options.item)
			this.getserviceNameList();
			// debugger
			// const item = JSON.parse(options.item)
			const item = uni.getStorageSync('channelPage')
			this.headerTittle = item.categoryName
			// console.log(item,options)
			this.pageId = item.categoryId
			if (item.childrenCategory == undefined || item.childrenCategory.length == 0) {
				this.canLoadData = false
			} else {
				this.canLoadData = true
				item.childList = []
				this.headerList = item.childrenCategory
				this.headerList.unshift({
					categoryName: '全部',
					icon: item.icon,
					parentId: item.categoryId,
					pageParam: [{
						pageNum: 1,
						pageSize: 10,
                        status: "loadmore",
                        showLoadMore: false,
					}, {
						pageNum: 1,
						pageSize: 10,
                        status: "loadmore",
                        showLoadMore: false,
					}],
					childList: [
						[],
						[]
					],
				})
				this.headerList.forEach((e) => {
					e.pageParam = [{
						pageNum: 1,
						pageSize: 10,
                        status: "loadmore",
                        showLoadMore: false,
					}, {
						pageNum: 1,
						pageSize: 10,
                        status: "loadmore",
                        showLoadMore: false,
					}]
					e.childList = [
						[],
						[]
					]
				})
				this.currentIndex = item.selectIndex + 1

				this.getChannelContentList(this.currentIndex)
			}
		},

		methods: {
			//点击卡片跳转
			onCardClick(obj) {
				// console.log(obj)
				uni.removeStorageSync('indexDetails')
                obj.bizType = this.$bizType
                uni.setStorageSync('indexDetails', obj)
                if(this.groupBuy) {
                    uni.navigateTo({
                        url: '../../groupDetails'
                    })
                } else {
                    if (this.listCurrent == 0) {
                        uni.navigateTo({
                            url: '../../index/personDetails'
                        })
                    } else {
                        uni.navigateTo({
                            url: '../../index/shopDetails'
                        })
                    }
                }
			},
			selectHeadClick(index) {
				// console.log(index, 'selectHeadClick')
				this.currentIndex = index
				if (this.canLoadData) {
                    this.emptyLoading = true
					this.getChannelContentList(this.currentIndex,'selectHeadClick')
				}

			},
            ///点击tab转换index
			change(index) {
				this.current = index;
                if(this.$bizType=='1') {
                    this.listCurrent = index - 1
                } else {
                    this.listCurrent = index
                }
				if (this.canLoadData) {
                    if(this.$bizType=='1'&&index==0) {
                        this.groupBuy = true;
                    } else {
                        this.groupBuy = false;
                    }
                    
                    this.getChannelContentList(this.currentIndex)			
				}

			},
			//获取服务人员商家的数据
			async getChannelContentList(index,selectHeadClick) {
                // selectHeadClick 切换顶部分类时重新请求数据
                // index 上面头部分类的下标
                // listCurrent 下面团购 服务 商家 的下标
				if(!this.groupBuy) {
                    
                var item = this.headerList[index];
                
				// console.log(item, this.pageId)
				// if (item.childList[this.listCurrent].length > 0) return
                if(selectHeadClick) {
                    item.pageParam[this.listCurrent].pageNum=1;
                    item.childList[this.listCurrent] = []
                    item.pageParam[this.listCurrent].status = 'loading'
                    item.pageParam[this.listCurrent].showLoadMore = true
                }
                if(item.pageParam[this.listCurrent].status == 'nomore') return
                this.emptyLoading = true
				var param = {
					pageNum: item.pageParam[this.listCurrent].pageNum,
					pageSize: item.pageParam[this.listCurrent].pageSize,
					parentId: this.pageId, //分类id父id
					bizType: this.$bizType, //业务类型（1：家政；2：维修）
				}
				// 全部分类不需要cateid
				if (item.categoryName != '全部') {
					param.cateId = item.categoryId
				}
				var that = this
				item.pageParam[this.listCurrent].status = 'loading'
				item.pageParam[this.listCurrent].showLoadMore = true
				// console.log(index, 'index')
				if (this.listCurrent == 0) {
                    param.isGroupGoods = 0;
					this.$u.api.chanelCrewList(param).then(res => {
						if (res.code == 200) {
							if (res.rows.length == 0) {
								item.pageParam[this.listCurrent].status = 'nomore'
                                item.pageParam[this.listCurrent].showLoadMore = false
							} else {
								item.childList[that.listCurrent] = item.childList[that.listCurrent].concat(res.rows)
								item.pageParam[this.listCurrent].status = 'loadmore'
								item.pageParam[that.listCurrent].pageNum++
							}

							that.$forceUpdate()
						}
					}).finally(()=>{
                        that.emptyLoading = false
                    });
				} else {
					this.$u.api.seekMerchantMerchandiseList(param).then(res => {
						if (res.code == 200) {
							if (res.rows.length == 0) {
								item.pageParam[this.listCurrent].status = 'nomore'
                                item.pageParam[this.listCurrent].showLoadMore = false
							} else {
								item.childList[that.listCurrent] = item.childList[that.listCurrent].concat(res.rows)
                                item.pageParam[this.listCurrent].status = 'loadmore'
								item.pageParam[that.listCurrent].pageNum++
							}
                            console.log(item.childList)
							that.$forceUpdate()
						}
					}).finally(()=>{
                        that.emptyLoading = false
                    });

                }
                } else {
                    var that = this
                    var item = this.headerList[index];
                    
                    // console.log(item, this.pageId)
                    // if (this.flowList.length > 0) return
                     if(selectHeadClick) {
                        that.groupPageNum = 1;
                        that.flowList = []
                        that.groupStatus = 'loading'
                        this.$refs.uWaterfall.clear();
                    }
                    if(this.groupStatus == 'nomore') return
                    this.emptyLoading = true
                    var param = {
                        pageNum: this.groupPageNum,
                        pageSize: this.groupPageSize,
                        parentId: this.pageId, //分类id父id
                        bizType: this.$bizType, //业务类型（1：家政；2：维修）
                    }
                    // 全部分类不需要cateid
                    if (item.categoryName != '全部') {
                        param.cateId = item.categoryId
                    }
                    
                    that.groupStatus = 'loading'
                    that.showGroupLoadMore = true
                    // this.$api.msg('团购')
                    param.isGroupGoods = 1;
                   
                    this.$u.api.seekCrewList(param).then(res => {
                        if (res.code == 200) {
                            if (res.rows.length == 0) {
                                this.groupStatus = 'nomore'
                                if(this.groupPageNum==1) {
                                    this.showGroupLoadMore = false
                                }
                            } else {
                                this.flowList = this.flowList.concat(res.rows)
                                this.groupPageNum++
                                if(res.rows.length <this.groupPageSize) {
                                    this.groupStatus = 'nomore'
                                    this.showGroupLoadMore = false
                                } else {
                                    this.groupStatus = 'loadmore'
                                }
                            }
                            that.$forceUpdate()
                        }
                    }).finally(()=>{
                        that.emptyLoading = false
                    });
                    
							
                }



			},
			///获取list
			getserviceNameList() {
				this.serviceNameList = [{
						name: '预订服务'
					},
					{
						name: '商家'
					},
				];
                if(this.$bizType=='1') {
                    this.serviceNameList.unshift({name: '团购服务'})
                }
			},
			
			///回退页面
			navigateBack() {
				uni.navigateBack();
			},
			gotoSearch() {
				uni.navigateTo({
					url: '../../index/search'
				})
			},
            gotoDetails(obj) {
                uni.removeStorageSync("indexDetails");
                obj.bizType = this.$bizType;
                uni.setStorageSync("indexDetails", obj);
                uni.navigateTo({
                    url: "../../index/groupDetails",
                });
            },
            serveDetail(obj,isGroupGoods) {
                uni.removeStorageSync('indexDetails')
				// console.log(obj)
				if (isGroupGoods == 0) {
					obj.bizType = this.$bizType
					uni.setStorageSync('indexDetails', obj)
					uni.navigateTo({
						url: '/pages/index/personDetails'
					})
				} else if (isGroupGoods == 1){
					obj.bizType = this.$bizType
					uni.setStorageSync('indexDetails', obj)
					uni.navigateTo({
						url: '/pages/index/groupDetails'
					})
				}
            },
		},
	}
</script>
<style>
	page {
		background-color: #FFFFFF;
	}
</style>
<style scoped lang="scss">
	.twoLineStyle {
		overflow: hidden;
		-webkit-line-clamp: 2;
		text-overflow: ellipsis;
		display: -webkit-box;
		-webkit-box-orient: vertical;
		color: #111111;
		font-size: 29rpx;
		text-overflow: ellipsis;
	}

	.company_auth {
		// width: 98rpx;
		// height: 32rpx;
		padding: 4rpx 10rpx;
		background: linear-gradient(270deg, #009BF8 0%, #009BF8 0%, #97D5FF 100%, #97D5FF 100%);
		border-radius: 10rpx 0rpx 10rpx 0rpx;
		opacity: 1;
		color: #FFFFFF;
		text-align: center;
		font-size: 21rpx;
		// font-weight: bold;
	}
	
	.presonal_auth {
		// width: 98rpx;
		// height: 32rpx;
			padding: 4rpx 10rpx;
		background: linear-gradient(270deg, #FF6B00 0%, #FF6B00 0%, #FFB700 100%, #FFB700 100%);
		border-radius: 10rpx 0rpx 10rpx 0rpx;
		opacity: 1;
		color: #FFFFFF;
		text-align: center;
		font-size: 21rpx;
		// font-weight: bold;
	}
	.age_tag {
		// width: 98rpx;
		padding: 1rpx 10rpx;
		// height: 32rpx;
		background: linear-gradient(269deg, #E7C2A1 0%, #E7C2A1 0%, #F4EBE1 100%, #F4EBE1 100%);
		border-radius: 8rpx;
		opacity: 1;
		color: #885c4b;
		text-align: center;
		font-size: 22rpx;
	}

	.content_comment {
		border-radius: 8rpx;
		border: 1rpx solid #FF9999;
		color: #FF1414;
		font-size: 22rpx;
		padding: 2rpx 10rpx;
		margin-left: 17rpx;
	}


.demo-warter {
    border-radius: 20rpx;
    overflow: hidden;
    margin: 18rpx 18rpx 0 0;
    background-color: #ffffff;
    position: relative;
}

.u-close {
    position: absolute;
    top: 32rpx;
    right: 32rpx;
}

.demo-image {
    width: 100%;
    border-radius: 4px;
}

.demo-title {
    font-size: 30rpx;
    margin-top: 5px;
    color: #111;
    word-wrap: break-word;
}

.rate-box {
    border: 2rpx solid #ff8f96;
    border-radius: 8rpx;
    width: 150rpx;
    height: 36rpx;
}
</style>
