<template>
	<view class="activity">
		<view  style="background-color: #F6F6F6;">
			<view class="b-f" style="padding: 20upx;border-radius: 10upx;margin-bottom: 30upx;" v-for="(item,index) in tabDataList" :key="index" @click="toSignUp(item)">
				<view class="dis-flex" >
					<view  style="flex: 0.3;">
						<image :src="item.logo" style="width: 200upx;height: 200upx;margin-right: 20upx;border-radius: 10upx;" mode=""></image>
					</view>
					<view  style="position: relative;flex: 0.7;">
						<view class="f-30" style="padding-bottom: 15upx;">
							{{item.goods_name}}
						</view>
						<view class="col-9 f-20" style="padding-bottom: 15upx;">
							<view class="dis-il-block" style="width: 350upx;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;">
								{{item.address}}
							</view>
							<view style="float: right;">{{item.distance}}</view>
						</view>
						<view class="f-22 col-9" style="height: 30upx;line-height: 30upx;padding-bottom: 15upx;" v-if="item.minprice && item.maxprice">
							<view >
								价格: <text style="color: #FF4444;font-size: 36upx;padding-left: 10upx;"><text class="f-20">¥</text>{{item.minprice}}</text>
								<text style="padding: 0 10upx;color: #FF4444;">~</text>
								<text style="color: #FF4444;font-size: 36upx;padding-left: 10upx;"><text class="f-20">¥</text>{{item.maxprice}}</text>
							</view>
							<!-- <view >
								最高价: 
							</view> -->
						</view>
						<view class="f-22 col-9" style="height: 30upx;line-height: 30upx;padding-bottom: 15upx;" v-else>
							<view >
								价格: <text style="color: #FF4444;font-size: 36upx;padding-left: 10upx;"><text class="f-20">¥</text>{{item.price}}</text>
							</view>
							<!-- <view >
								最高价: 
							</view> -->
						</view>
						<view >
							<view class="f-20 col-9 dis-il-block" style="margin: 10upx  0 10upx;background-color: #FFEBEB;color: #FF4444;border-radius: 60upx;height: 30upx;line-height: 30upx;padding: 5upx 20upx;">
								{{item.catename}}
							</view>
						</view>
		
						<view class="f-26 col-f t-c" 
						style="position: absolute;background-color: #FF4444;height: 50upx;line-height: 50upx;width: 150upx;border-radius: 60upx;right: 10upx;bottom: 10upx;">
							立即报名
						</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import App from '@/common/js/app.js'
	export default{
		data(){
			return{
				
			}
		},
		props:{
			tabDataList:{
				type:Array,
				default:[]
			}
		},
		methods:{
			toSignUp(item){
				console.log(item);
				debugger
				App.navigationTo({
					url: `pages/subPages2/coursegoods/coursegoods?id=${item.id}`
				})
			},
		}
	}
</script>

<style>
</style>
