<template>
	<view class="container activity">
		<view class="activity-content">
			<view class="activity-list" v-for="(activity,index) in activityList" :key="index" @click="NavigatorPath(activity)">
				<view class="activity-list-pic">
					<image class="activity-image" :src="activity.image" mode=""></image>
				</view>
				<view class="activity-list-msg">
					<view class="activity-title">{{ activity.name }}</view>
					<view class="activity-numbe">商品数：<text class="color">{{ activity.num }}</text> </view>
					<view class="activity-times">
						<text class="label">活动时间：</text>
						<text class="color">{{ activity.startTime }}~{{ activity.endTime }}</text>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default{
		data(){
			return{
				activityList:[
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
					{
						num:10,
						image:'https://img.caimei365.com/group1/M00/00/0A/rB-lGGBrzcmAbarfAG8gcPdEFtI777.jpg',
						name:'韩国恩盛进口氢洁气小气泡清韩国恩盛进口氢洁气小气泡清',
						startTime:'2021-04-12 15:19:32',
						endTime:'2021-06-31 15:19:32'
					},
				]
			}
		},
		onLoad() {
			
		},
		methods:{
			NavigatorPath(item){
				console.log(item)
				this.$api.navigateTo('/pages/user/activity/activity')
			}
		},
		onPullDownRefresh() {//下拉刷新
			uni.stopPullDownRefresh()
		},
		onShow() {
			
		}
	}
</script>

<style lang="scss">
	page{
		height: auto !important;
		background-color: $color-system;
	}
	.activity-content{
		width: 100%;
		height: auto;
		box-sizing: border-box;
		padding: 24rpx;
		.activity-list{
			width: 100%;
			height: 228rpx;
			box-sizing: border-box;
			padding: 24rpx 20rpx;
			background-color: #FFFFFF;
			border-radius: 16rpx;
			margin-bottom: 24rpx;
			.activity-list-pic{
				width: 180rpx;
				height: 180rpx;
				float: left;
				box-sizing: border-box;
				border: 1px solid #e1e1e1;
				border-radius: 8rpx;
				.activity-image{
					width: 178rpx;
					height: 178rpx;
					display: block;
					border-radius: 8rpx;
				}
			}
			.activity-list-msg{
				width: 460rpx;
				height: 100%;
				float: right;
				position: relative;
				.activity-title{
					width: 100%;
					height: auto;
					line-height: 36rpx;
					text-overflow: ellipsis;
					overflow: hidden;
					display: -webkit-box;
					-webkit-line-clamp: 2;
					line-clamp: 2;
					-webkit-box-orient: vertical;
					font-size: $font-size-26;
					color: #333333;
					text-align: justify;
					float: left;
				}
				.activity-numbe{
					width: 100%;
					height: 28rpx;
					float: left;
					margin-top: 4rpx;
					text-align: left;
					line-height: 28rpx;
					font-size: $font-size-24;
					color: #999999;
					.color{
						color: #666666;
					}
				}
				.activity-times{
					width: 100%;
					height: 44rpx;
					position: absolute;
					bottom: 0;
					left: 0;
					font-size:18rpx;
					color: #666666;
					line-height: 44rpx;
					.label{
						display: inline-block;
						float: left;
					}
					.color{
						display: inline-block;
						float: left;
						color: $color-system;
					}
				}
			}
		}
	}
	
</style>
