yuminge-app/yun-min-program-plugin-master/packageI/brand_resources/brandResourcesIndex/brandResourcesIndex.wxml

62 lines
2.0 KiB
Plaintext

<!--packageI/brand_resources/brandResourcesIndex/brandResourcesIndex.wxml-->
<view class="banner" wx:if="{{banner.length>0}}">
<swiper autoplay="{{true}}" interval="3000" circular="{{true}}">
<swiper-item catchtap='tapUrl' class="banner_item" wx:for="{{banner}}" wx:key="index"
data-url="{{item.mini_url}}">
<image src="{{item.image_url}}" mode="aspectFill"></image>
</swiper-item>
</swiper>
</view>
<view class="recommend">
<view class="recommend-title">
<i class="iconfont icon-fontclass-tuijian1"></i>
<text class="text">推荐商品</text>
</view>
<view class="recommend-goods">
<view class="recommend-good" wx:for="{{recommend}}" data-id="{{item.id}}" bindtap="toGood">
<view class="good-face">
<image src="{{item.thumb}}" />
</view>
<view class="good-title">
{{item.title}}
</view>
<view class="good-prices">
<view class="present-price">¥{{item.price}}</view>
<view class="original-price" wx:if="{{(item.market_price*1)>(item.price*1)}}">¥{{item.market_price}}</view>
</view>
</view>
</view>
</view>
<view class="category">
<view class="sticky" wx:if="{{category.length>0}}">
<van-tabs active="{{activeName}}" bind:click="changeTabName">
<van-tab name="{{index}}" title="{{item.name}}" wx:for="{{category}}"></van-tab>
</van-tabs>
</view>
<block wx:for="{{category}}" wx:for-item="cate">
<visible-item offsetTop="{{44}}" index="{{index}}" bind:display="ondisplay">
<view class="category-container category{{index}}">
<view class="category-title">{{cate.name}}</view>
<view class="category-list">
<view class="category-item" wx:for="{{cate.children}}" bindtap="toCate" data-id="{{item.id}}">
<view class="category-cover">
<image src="{{item.thumb}}" />
</view>
<view class="category-text">{{item.name}}</view>
</view>
</view>
</view>
</visible-item>
</block>
</view>