lilei 4 лет назад
Родитель
Сommit
a176d39faa
2 измененных файлов с 16 добавлено и 4 удалено
  1. 14 2
      components/uni-coods/uni-coods.vue
  2. 2 2
      pages/toOrder/index.vue

+ 14 - 2
components/uni-coods/uni-coods.vue

@@ -18,8 +18,11 @@
 					<text>{{item.sellGold}}</text>
 					<u-image mode="scaleToFill" width="40rpx" height="40rpx" src="/static/ledou.png"></u-image>
 				</view>
-				<view @click="addCart(item)" v-if="item.inventoryQty > 0">
-					<u-image mode="scaleToFill" width="45rpx" height="45rpx" src="/static/addCart.png"></u-image>
+				<view v-if="item.inventoryQty > 0 && item.state == 1 ">
+					<!-- <u-image mode="scaleToFill" width="45rpx" height="45rpx" src="/static/addCart.png"></u-image> -->
+					<u-button size="mini" type="error" :custom-style="customStyle" @click="addCart(item)">
+						+
+					</u-button>
 				</view>
 			</view>
 		</view>
@@ -46,6 +49,15 @@
 		},
 		data() {
 			return {
+				customStyle:{
+					color: '#fff',
+					borderRadius: '150rpx',
+					border: 0,
+					width: '50rpx',
+					height: '50rpx',
+					lineHeight: '50rpx',
+					fontSize: '25px'
+				},
 				loadingImg: '/static/loading.gif',
 				errorImg: '/static/imgError.png',
 				timer: null,

+ 2 - 2
pages/toOrder/index.vue

@@ -111,8 +111,8 @@
 				toOrderButton: {
 					borderRadius:'100rpx',
 					fontSize:'30rpx',
-					width: '180rpx',
-					height: '60rpx'
+					width: '200rpx',
+					height: '80rpx'
 				},
 				goodsList: [], // 商品列表
 				// 用户信息