小程序
小游戏
企业微信
微信支付
扫描小程序码分享
数据200条左右
1 个回答
加粗
标红
插入代码
插入链接
插入图片
上传视频
贴一下你这里循环的WXML
你好,麻烦通过点击下方“反馈信息”按钮,提供出现问题的。
<view class="cartpull">
<view class="carts-list {{item.isTouchMove ? 'touch-move-active' : ''}}" wx:for="{{carts}}" data-index="{{index}}" bindtouchstart="touchstart" bindtouchmove="touchmove" wx:key="{{carts}}" >
<view class="carts-item">
<view class="carts_height" bindtap="selectList" data-index="{{index}}"></view>
<icon class="item-select" wx:if="{{item.selected}}" type="success" color="#FF5000" bindtap="selectList" data-index="{{index}}" />
<icon class="item-select" wx:else type="circle" bindtap="selectList" data-index="{{index}}" />
<view bindtap='goodsDetail' id="{{item.id}}">
<view class="cart-thumbs">
<image src="{{config.smGoodsImgUrl}}{{item.pic}}"></image>
</view>
<view class="cant cants" wx:if='{{item.isShow}}'>购买数量超过最大库存{{item.bulkCount}}{{item.bulkUnits}},无法下单</view>
<view class="cant cants" wx:if='{{item.isMinShow}}'>购买数量小于起订量{{item.bulkStart}}{{item.bulkUnits}},无法下单</view>
<view class="column">
<view class="" bindtap='goodsDetail' id="{{item.id}}">
<text class="title">{{item.name}}</text>
<view class="item_right_good_specification">
<view class="flex">
<view class="promote-icon" wx:if="{{item.promotionType==1||item.promotionType==2}}">
<text>促销</text>
<view class="imported imported_bg" wx:if="{{item.persentType!=0}}">满赠</view>
<view class="imported" wx:if="{{item.importation==1}}">进口</view>
<view class="row">
<text class="sales" wx:if="{{item.sellType!=2}}">{{item.bulkStart}}{{item.bulkUnits}}起订</text>
<text class="sales" wx:else>不支持散装订货</text>
<view class="flex money">
<text class="price" wx:if="{{item.unitsType==2}}">¥{{item.promotionType==0?item.bulkPrice:item.promotionBulkPrice}}<text class="boxs">/{{item.bulkUnits}}</text></text>
<text class="price" wx:if="{{item.unitsType==1}}">¥{{item.promotionType==0?item.packPrice:item.promotionPackPrice}}<text class="boxs">/{{item.packUnits}}</text></text>
<view class="graydels" wx:if="{{(item.promotionType==1||item.promotionType==2)&&item.unitsType==2}}">¥{{item.bulkPrice!=null?item.bulkPrice:'?'}}
<text>/{{item.bulkUnits}}</text>
<view class="graydels" wx:elif="{{(item.promotionType==1||item.promotionType==2)&&item.unitsType==1}}">¥{{item.packPrice!=null?item.packPrice:'?'}}
<text>/{{item.packUnits}}</text>
<view class="stepper">
<text class="minus" bindtap="minusCount" data-index="{{index}}">-</text>
<!-- <input class="order-num" type="number" data-index="{{index}}" bindblur="numblur" bindinput="numInput" value="{{item.number}}"></input> -->
<span class="order-num" data-index="{{index}}" bindblur="numblur">{{item.number}}</span>
<text class="add" bindtap="addCount" data-index="{{index}}">+</text>
<view data-index="{{index}}" bindtap="deleteList" id="{{item.cartId}}" class="del">删除</view>
<!-- 底部操作栏 -->
<view class="carts-footer" wx:if="{{loginStatus}}">
<view class="cart-foot-left" hidden='{{allSelectt}}'>
<icon class="item-allselect" wx:if="{{selectAllStatus}}" type="success" color="#FF5000" bindtap="selectAll" />
<icon class="item-allselect" wx:else type="circle" bindtap="selectAll" />
<view class="small_text" bindtap="selectAll">全选</view>
<view class="carts-foot">
<text class="total">合计:</text>
<text class="prices">¥{{totalPrice}}</text>
<!-- <text class="species">{{item.price}}件{{item.price}}种</text> -->
<button class="button-red" bindtap="{{controller==true?'toBuy':''}}" style="{{controller==true?'':'background:#ccc;border:0'}}" formType="submit">结算</button>
没看出什么问题啊,贴到工具里试了下也是正常的。清下缓存试试?
关注后,可在微信内接收相应的重要提醒。
请使用微信扫描二维码关注 “微信开放社区” 公众号
贴一下你这里循环的WXML
<view class="cartpull">
<view class="carts-list {{item.isTouchMove ? 'touch-move-active' : ''}}" wx:for="{{carts}}" data-index="{{index}}" bindtouchstart="touchstart" bindtouchmove="touchmove" wx:key="{{carts}}" >
<view class="carts-item">
<view class="carts_height" bindtap="selectList" data-index="{{index}}"></view>
<icon class="item-select" wx:if="{{item.selected}}" type="success" color="#FF5000" bindtap="selectList" data-index="{{index}}" />
<icon class="item-select" wx:else type="circle" bindtap="selectList" data-index="{{index}}" />
<view bindtap='goodsDetail' id="{{item.id}}">
<view class="cart-thumbs">
<image src="{{config.smGoodsImgUrl}}{{item.pic}}"></image>
</view>
</view>
<view class="cant cants" wx:if='{{item.isShow}}'>购买数量超过最大库存{{item.bulkCount}}{{item.bulkUnits}},无法下单</view>
<view class="cant cants" wx:if='{{item.isMinShow}}'>购买数量小于起订量{{item.bulkStart}}{{item.bulkUnits}},无法下单</view>
<view class="column">
<view class="" bindtap='goodsDetail' id="{{item.id}}">
<text class="title">{{item.name}}</text>
<view class="item_right_good_specification">
<view class="flex">
<view class="promote-icon" wx:if="{{item.promotionType==1||item.promotionType==2}}">
<text>促销</text>
</view>
<view class="imported imported_bg" wx:if="{{item.persentType!=0}}">满赠</view>
<view class="imported" wx:if="{{item.importation==1}}">进口</view>
</view>
<view class="row">
<text class="sales" wx:if="{{item.sellType!=2}}">{{item.bulkStart}}{{item.bulkUnits}}起订</text>
<text class="sales" wx:else>不支持散装订货</text>
</view>
</view>
</view>
<view class="flex money">
<view bindtap='goodsDetail' id="{{item.id}}">
<text class="price" wx:if="{{item.unitsType==2}}">¥{{item.promotionType==0?item.bulkPrice:item.promotionBulkPrice}}<text class="boxs">/{{item.bulkUnits}}</text></text>
<text class="price" wx:if="{{item.unitsType==1}}">¥{{item.promotionType==0?item.packPrice:item.promotionPackPrice}}<text class="boxs">/{{item.packUnits}}</text></text>
<view class="graydels" wx:if="{{(item.promotionType==1||item.promotionType==2)&&item.unitsType==2}}">¥{{item.bulkPrice!=null?item.bulkPrice:'?'}}
<text>/{{item.bulkUnits}}</text>
</view>
<view class="graydels" wx:elif="{{(item.promotionType==1||item.promotionType==2)&&item.unitsType==1}}">¥{{item.packPrice!=null?item.packPrice:'?'}}
<text>/{{item.packUnits}}</text>
</view>
</view>
<view class="stepper">
<text class="minus" bindtap="minusCount" data-index="{{index}}">-</text>
<!-- <input class="order-num" type="number" data-index="{{index}}" bindblur="numblur" bindinput="numInput" value="{{item.number}}"></input> -->
<span class="order-num" data-index="{{index}}" bindblur="numblur">{{item.number}}</span>
<text class="add" bindtap="addCount" data-index="{{index}}">+</text>
</view>
</view>
</view>
</view>
<view data-index="{{index}}" bindtap="deleteList" id="{{item.cartId}}" class="del">删除</view>
<!-- 底部操作栏 -->
<view class="carts-footer" wx:if="{{loginStatus}}">
<view class="cart-foot-left" hidden='{{allSelectt}}'>
<icon class="item-allselect" wx:if="{{selectAllStatus}}" type="success" color="#FF5000" bindtap="selectAll" />
<icon class="item-allselect" wx:else type="circle" bindtap="selectAll" />
<view class="small_text" bindtap="selectAll">全选</view>
</view>
<view class="carts-foot">
<text class="total">合计:</text>
<text class="prices">¥{{totalPrice}}</text>
<!-- <text class="species">{{item.price}}件{{item.price}}种</text> -->
<button class="button-red" bindtap="{{controller==true?'toBuy':''}}" style="{{controller==true?'':'background:#ccc;border:0'}}" formType="submit">结算</button>
</view>
</view>
</view>
</view>
没看出什么问题啊,贴到工具里试了下也是正常的。清下缓存试试?