<template>
	<view class="container ">
		<au-custom :navbar-data='nvabarData' @navigateBack="hanldNavigateBack"></au-custom>
		<view class="vsit-content">
			<view class="list" v-for="(item,index) in list" :key="index" >
				<view class="list-title">{{ item.year }}年</view>
				<view class="list-main clear">
					<view class="list-main-item" v-for="(visit,index) in item.data">
						<view class="item-le">
							<view class="item-le-t none">{{ visit.month }}</view>
							<view class="item-le-t">{{ visit.day }}</view>
						</view>
						<view class="item-ri">
							<view class="item-ri-i">访问记录</view>
							<view class="item-ri-i none">{{ visit.num }}条</view>
						</view>
					</view>
				</view>
			</view>
		</view>
	</view>	
</template>

<script>
	export default{
		data(){
			return{
				nvabarData: {		//顶部自定义导航
					haveHome:true,
					haveBack:true,
					textColor:'#ffffff',
					showCapsule:1, // 是否显示左上角图标  1表示显示  0表示不显示,
					showSearch: 0,
					title: '',  // 导航栏 中间的标题
					textLeft:this.$store.state.isIphone
				},
				list:[
					{
						year:"2023",
						data:[
							{
								month:'三月',
								day:'03-27',
								num:5
							},
							{
								month:'三月',
								day:'03-27',
								num:5
							},
							{
								month:'三月',
								day:'03-27',
								num:5
							},
							{
								month:'三月',
								day:'03-27',
								num:5
							}
						]
					},
					{
						year:"2022",
						data:[
							{
								month:'十二月',
								day:'12-27',
								num:5
							},
							{
								month:'十二月',
								day:'12-27',
								num:15
							},
							{
								month:'十二月',
								day:'12-27',
								num:50
							},
							{
								month:'十二月',
								day:'12-27',
								num:5
							}
						]
					},
				]
			}
		},
		filters:{
			
		},
		onLoad(option) {
			
		},
		methods:{
			hanldNavigateBack(){
				uni.navigateBack({
					delta: 1
				})
			}
		},
		onShow() {
			
		}
	}
</script>

<style lang="scss">
	page{
		width: 100%;
		height: auto;
		background-color: #F7F7F7 !important;
	}
	.container{
		width: 100%;
		min-height: 700rpx;
		background: url(https://static.caimei365.com/app/img/bg/bg_visit@2x.png) top center no-repeat;
		background-size: contain;
		box-sizing: border-box;
		padding: 0 24rpx;
		padding-top: 441rpx;
	}
	.vsit-content{
		width: 100%;
		min-height: 1000rpx;
		background: #FFFFFF;
		border-radius: 24rpx;
		padding: 52rpx 24rpx;
		box-sizing: border-box;
		.list{
			width: 100%;
			height: auto;
			margin-bottom: 80rpx;
			.list-title{
				width: 100%;
				height: 58rpx;
				margin-bottom: 20rpx;
				font-size: 42rpx;
				color: #333;
			}
			.list-main{
				width: 100%;
				height: auto;
				padding: 24rpx 16rpx 24rpx 70rpx;
				box-sizing: border-box;
				position: relative;
				&::before{
					content:'';
					height: 100%; 
					border-left: 2px dashed #FFA880;
					position: absolute;
					left: 37rpx;
					top: 0;
				}
				.list-main-item{
					width: 565rpx;
					height: 120rpx;
					box-sizing: border-box;
					padding: 12rpx 35rpx;
					background: url(https://static.caimei365.com/app/img/bg/bg_visit_list@2x.png)no-repeat;
					background-size: cover;
					margin-bottom: 40rpx;
					position: relative;
					border-radius: 16rpx;
					&::after{
						content:'';
						width: 40rpx;
						height: 40rpx;
						background: url(https://static.caimei365.com/app/img/bg/bg_visit_radius@2x.png)no-repeat;
						background-size: cover;
						position: absolute;
						left: -52rpx;
					}
					.item-le{
						height: 100%;
						box-sizing: border-box;
						padding-right: 30rpx;
						position: relative;
						float: left;
						&::before{
							content: '';
							width: 1px;
							height: 48rpx;
							background-color: #CCC;
							position: absolute;
							top: 24rpx;
							right: 0;
						}
						.item-le-t{
							width: 120rpx;
							height: 48rpx;
							line-height: 48rpx;
							font-size: 30rpx;
							text-align: center;
							color: #333333;
							&.none{
								color: #999;
							}
						}
					}
					.item-ri{
						height: 96rpx;
						padding-left: 48rpx;
						float: left;
						.item-ri-i{
							padding-right: 60rpx;
							line-height: 96rpx;
							font-size: 28rpx;
							text-align: center;
							color: #999;
							float: left;
							&.none{
								font-size: 30rpx;
								color: #E15616;
							}
						}
					}
				}
			}
		}
	}
</style>