zhengkaixin 1 rok temu
rodzic
commit
cd5617b841

+ 7 - 5
components/u-swiper/u-swiper.vue

@@ -5,23 +5,24 @@
 		<swiper :current="elCurrent" @change="change" @animationfinish="animationfinish" :interval="interval" :circular="circular" :duration="duration" :autoplay="autoplay"
 		 :previous-margin="effect3d ? effect3dPreviousMargin + 'rpx' : '0'" :next-margin="effect3d ? effect3dPreviousMargin + 'rpx' : '0'"
 		 :style="{
-				height: height + 'px',
-				backgroundColor: bgColor
+				height: height + 'rpx',
+				//backgroundColor: bgColor
 			}">
-			<swiper-item class="u-swiper-item" v-for="(item, index) in list" :key="index">
+			<slot></slot>
+		<!-- 	<swiper-item class="u-swiper-item" v-for="(item, index) in list" :key="index">
 				<view class="u-list-image-wrap" @tap.stop.prevent="listClick(index)" :class="[uCurrent != index ? 'u-list-scale' : '']" :style="{
 						borderRadius: `${borderRadius}rpx`,
 						transform: effect3d && uCurrent != index ? 'scaleY(0.9)' : 'scaleY(1)',
 						margin: effect3d && uCurrent != index ? '0 20rpx' : 0,
 					}">
-					<image class="u-swiper-image" :src="item[name] || item" :mode="imgMode"></image>
+						
 					<view v-if="title && item.title" class="u-swiper-title u-line-1" :style="[{
 							'padding-bottom': titlePaddingBottom
 						}, titleStyle]">
 						{{ item.title }}
 					</view>
 				</view>
-			</swiper-item>
+			</swiper-item> -->
 		</swiper>
 		<view class="u-swiper-indicator" :style="{
 				top: indicatorPos == 'topLeft' || indicatorPos == 'topCenter' || indicatorPos == 'topRight' ? '12rpx' : 'auto',
@@ -338,5 +339,6 @@
 		display: flex;
 		overflow: hidden;
 		align-items: center;
+		   
 	}
 </style>

+ 5 - 3
pages/index/index.vue

@@ -5,9 +5,9 @@
 		<!-- 头部图片 -->
 		<view class="background">
 			<view class="banner">
-				<ujp-swiper bg-color="#fff" :img-mode="'scaleToFill'" height="120" :list="bannerList"
+				<u-swiper bg-color="#fff" :img-mode="'scaleToFill'"   :list="bannerList"
 					@click="clickBanner" :name="'picUrl'">
-				</ujp-swiper>
+				</u-swiper>
 
 			</view>
 
@@ -1987,7 +1987,9 @@
 		height: 120px;
 		overflow: hidden;
 
-
+		/deep/uni-swiper{
+			height: 120px !important;
+		}
 	}
 
 

+ 32 - 19
pages/monthlyCardActivity/monthlyCardBuy.vue

@@ -36,14 +36,24 @@
 					</view>
 				</view>
 			</view>
-
-			<scroll-view class="scroll-view_H" scroll-x="true" :scrollWithAnimation="true" @scroll="scroll"
-				:scrollLeft="scrollLeftSet" @scrolltoupper="scrolltoupper" @scrolltolower="scrolltolower">
-				<view class="scroll-view-item_H" :style="cardList.length==1?'    width: 100%;':''"
+			<ujp-swiper v-if="!ispay"  :img-mode="'scaleToFill'" height="240" 
+			:effect3d="true" :autoplay="false" :circular="false"
+				@change="checkboxChangeBtn" :name="'picUrl'">
+				
+			
+				<swiper-item class="scroll-view-item_H u-swiper-item" 
 				 
-				 v-if="!ispay" v-for="(item,i) in cardList" :key="i">
-					<view :style="'background-image: url('+item.monthlyRentCard.image+') ;'"
-						:class="'cardtab card-'+i ">
+				  v-for="(item,i) in cardList" :key="i">
+					<view 
+					:style="{
+						backgroundImage:' url('+item.monthlyRentCard.image+') ',
+						
+							transform:  'scaleY(0.9)',
+							margin: '0 20rpx' ,
+						}"
+					
+				
+						:class="'cardtab ' ">
 						<view class="tag" v-if="item.monthlyRentCard.isVip">{{item.monthlyRentCard.platformText}}车主
 						</view>
 						<view class="tag" v-else-if="item.monthlyRentCard.remark">{{item.monthlyRentCard.remark}}</view>
@@ -67,9 +77,9 @@
 
 
 					</view>
-				</view>
+				</swiper-item>
 
-			</scroll-view>
+			</ujp-swiper>
 
 
 
@@ -570,6 +580,9 @@
 			openModal() {
 				this.show3 = true;
 			},
+			checkboxChangeBtn(e){
+				this.checkboxChange(this.cardList[e].monthlyRentCard)
+			},
 			checkboxChange(monthlyRentCard) {
 
 				this.detail = monthlyRentCard;
@@ -976,8 +989,8 @@
 
 	.scroll-view-item_H {
 		display: inline-block;
-		width: 85%;
-		//height: 300rpx;
+		//width: 85%;
+		height: 300rpx;
 		line-height: 300rpx;
 		text-align: center;
 		font-size: 36rpx;
@@ -1008,7 +1021,7 @@
 			text-align: center;
 			line-height: 40rpx;
 			padding: 0 12rpx;
-			right: 26rpx;
+			right: 0rpx;
 			top: 0rpx;
 			border-radius: 0 12px 0 12px;
 
@@ -1071,16 +1084,16 @@
 
 		.card-0 {}
 
-		.card-0 {
-			background-position-x: 40rpx;
-		}
+		// .card-0 {
+		// 	background-position-x: 40rpx;
+		// }
 
 		.cardtab {
 			margin-top: 32rpx;
 			position: relative;
-			background-size: 90% 100%;
+			background-size: 100% 100%;
 			background-repeat: no-repeat;
-			height: 200rpx;
+			height: 300rpx;
 
 
 			/deep/.u-checkbox__icon-wrap {
@@ -1107,7 +1120,7 @@
 		margin-top: -20rpx;
 		width: 100%;
 
-		bottom: 40px;
+		bottom: 0px;
 		border-radius: 16px 16px 0px 0px;
 
 		padding: 20px 20px 24px 20px;
@@ -1193,7 +1206,7 @@
 
 	// 须知
 	.notice {
-		top: -15px;
+		top: -10rpx;
 		border-radius: 15px 15px 0 0;
 		position: relative;