微信小程序分类优化
parent
e6631cd440
commit
120a0b8f27
|
|
@ -129,11 +129,11 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav wh-auto bg-white">
|
||||
<view class="shop fl tc" onTap="shop_event">
|
||||
<view class="shop fl tc br-t" onTap="shop_event">
|
||||
<image src="/images/goods-detail-home-icon.png" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">首页</text>
|
||||
</view>
|
||||
<view class="collect fl tc" onTap="goods_favor_event">
|
||||
<view class="collect fl tc br-t" onTap="goods_favor_event">
|
||||
<image src="{{goods_favor_icon}}" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">{{goods_favor_text}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -122,11 +122,11 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav wh-auto bg-white">
|
||||
<view class="shop fl tc" bindtap="shop_event">
|
||||
<view class="shop fl tc br-t" bindtap="shop_event">
|
||||
<image src="/images/goods-detail-home-icon.png" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">首页</text>
|
||||
</view>
|
||||
<view class="collect fl tc" bindtap="goods_favor_event">
|
||||
<view class="collect fl tc br-t" bindtap="goods_favor_event">
|
||||
<image src="{{goods_favor_icon}}" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">{{goods_favor_text}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -129,11 +129,11 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav wh-auto bg-white">
|
||||
<view class="shop fl tc" bindtap="shop_event">
|
||||
<view class="shop fl tc br-t" bindtap="shop_event">
|
||||
<image src="/images/goods-detail-home-icon.png" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">首页</text>
|
||||
</view>
|
||||
<view class="collect fl tc" bindtap="goods_favor_event">
|
||||
<view class="collect fl tc br-t" bindtap="goods_favor_event">
|
||||
<image src="{{goods_favor_icon}}" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">{{goods_favor_text}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -129,11 +129,11 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav wh-auto bg-white">
|
||||
<view class="shop fl tc" bindtap="shop_event">
|
||||
<view class="shop fl tc br-t" bindtap="shop_event">
|
||||
<image src="/images/goods-detail-home-icon.png" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">首页</text>
|
||||
</view>
|
||||
<view class="collect fl tc" bindtap="goods_favor_event">
|
||||
<view class="collect fl tc br-t" bindtap="goods_favor_event">
|
||||
<image src="{{goods_favor_icon}}" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">{{goods_favor_text}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ App({
|
|||
// 请求地址
|
||||
request_url: "{{request_url}}",
|
||||
request_url: 'http://shopxo.com/',
|
||||
// request_url: 'https://dev.shopxo.net/',
|
||||
request_url: 'https://dev.shopxo.net/',
|
||||
|
||||
// 基础信息
|
||||
application_title: "{{application_title}}",
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{
|
||||
"enablePullDownRefresh": true,
|
||||
"usingComponents": {
|
||||
}
|
||||
}
|
||||
|
|
@ -1,11 +1,13 @@
|
|||
<view wx:if="{{data_list.length > 0}}">
|
||||
<block wx:if="{{category_show_level == 1}}">
|
||||
<!-- 一级模式 -->
|
||||
<view class="model-one bg-white oh">
|
||||
<view class="model-one oh">
|
||||
<block wx:for="{{data_list}}" wx:key="key" wx:for-item="v">
|
||||
<view class="content-item br-b br-r" data-value="{{v.id}}" bindtap="category_event">
|
||||
<image wx:if="{{(v.icon || null) != null}}" src="{{v.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{v.name}}</view>
|
||||
<view class="content-item" data-value="{{v.id}}" bindtap="category_event">
|
||||
<view class="content bg-white wh-auto">
|
||||
<image wx:if="{{(v.icon || null) != null}}" src="{{v.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{v.name}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
|
|
@ -30,11 +32,13 @@
|
|||
<block wx:if="{{data_content.items.length > 0}}">
|
||||
<!-- 二级模式 -->
|
||||
<block wx:if="{{category_show_level == 2}}">
|
||||
<view class="bg-white oh">
|
||||
<view class="two-content bg-white oh">
|
||||
<block wx:for="{{data_content.items}}" wx:key="key" wx:for-item="v">
|
||||
<view class="content-item" data-value="{{v.id}}" bindtap="category_event">
|
||||
<image wx:if="{{(v.icon || null) != null}}" src="{{v.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{v.name}}</view>
|
||||
<view class="content wh-auto">
|
||||
<image wx:if="{{(v.icon || null) != null}}" src="{{v.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{v.name}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
|
|
@ -47,8 +51,10 @@
|
|||
<block wx:if="{{v.items.length > 0}}">
|
||||
<block wx:for="{{v.items}}" wx:key="key" wx:for-item="vs">
|
||||
<view class="content-item" data-value="{{vs.id}}" bindtap="category_event">
|
||||
<image wx:if="{{(vs.icon || null) != null}}" src="{{vs.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{vs.name}}</view>
|
||||
<view class="content wh-auto">
|
||||
<image wx:if="{{(vs.icon || null) != null}}" src="{{vs.icon}}" mode="aspectFit" class="icon" />
|
||||
<view class="text single-text">{{vs.name}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
</block>
|
||||
|
|
|
|||
|
|
@ -26,10 +26,9 @@
|
|||
background: #f5f5f5;
|
||||
border-left: 3px solid #e23f36 !important;
|
||||
border-right: 3px solid #f5f5f5 !important;
|
||||
color: #e23f36;
|
||||
color: #e23f36 !important;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 右侧内容
|
||||
*/
|
||||
|
|
@ -43,9 +42,14 @@
|
|||
right: 0;
|
||||
background: #f5f5f5;
|
||||
}
|
||||
.right-content, .one-content {
|
||||
.right-content {
|
||||
padding: 0 20rpx 20rpx 20rpx;
|
||||
}
|
||||
.one-content {
|
||||
padding: 20rpx;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
.one-content, .two-content {
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
.one-vice-name {
|
||||
font-size: 30rpx;
|
||||
|
|
@ -62,11 +66,15 @@
|
|||
padding: 20rpx 10rpx;
|
||||
}
|
||||
.content-item {
|
||||
float: left;
|
||||
display: -webkit-inline-box;
|
||||
width: calc(33.33% - 20rpx);
|
||||
padding: 25rpx 10rpx;
|
||||
padding: 10rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.content-item .content {
|
||||
margin: 0 auto;
|
||||
padding: 15rpx 0;
|
||||
}
|
||||
.content-item .text {
|
||||
font-size: 28rpx;
|
||||
line-height: 46rpx;
|
||||
|
|
@ -75,8 +83,8 @@
|
|||
width: 100%;
|
||||
height: 120rpx;
|
||||
}
|
||||
.model-one .content-item {
|
||||
width: calc(33.33% - 21.1rpx);
|
||||
.model-one {
|
||||
padding: 10rpx;
|
||||
}
|
||||
.model-one .content-item:nth-child(3n) {
|
||||
border-right: 0;
|
||||
|
|
|
|||
|
|
@ -127,11 +127,11 @@
|
|||
|
||||
<!-- 底部操作 -->
|
||||
<view class="goods-buy-nav wh-auto bg-white">
|
||||
<view class="shop fl tc" bindtap="shop_event">
|
||||
<view class="shop fl tc br-t" bindtap="shop_event">
|
||||
<image src="/images/goods-detail-home-icon.png" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">首页</text>
|
||||
</view>
|
||||
<view class="collect fl tc" bindtap="goods_favor_event">
|
||||
<view class="collect fl tc br-t" bindtap="goods_favor_event">
|
||||
<image src="{{goods_favor_icon}}" mode="scaleToFill" />
|
||||
<text class="dis-block cr-888">{{goods_favor_text}}</text>
|
||||
</view>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<view class="item spacing-mt bg-white {{item.is_operable == 0 ? 'item-disabled' : ''}}" style="border:1px solid {{item.bg_color_value}};">
|
||||
<view class="v-left fl">
|
||||
<view class="base single-text" style="color:{{item.bg_color_value}};">
|
||||
<text class="symbol">{{price_symbol}}</text>
|
||||
<text wx:if="{{item.type == 0}}" class="symbol">{{price_symbol}}</text>
|
||||
<text class="price">{{item.discount_value}}</text>
|
||||
<text class="unit">{{item.type_unit}}</text>
|
||||
<text wx:if="{{(item.desc || null) != null}}" class="desc cr-888">{{item.desc}}</text>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
<view class="item spacing-mt bg-white" style="border:1px solid {{item.coupon.bg_color_value}};">
|
||||
<view class="v-left fl">
|
||||
<view class="base single-text" style="color:{{item.coupon.bg_color_value}};">
|
||||
<text class="symbol">{{price_symbol}}</text>
|
||||
<text wx:if="{{item.coupon.type == 0}}" class="symbol">{{price_symbol}}</text>
|
||||
<text class="price">{{item.coupon.discount_value}}</text>
|
||||
<text class="unit">{{item.coupon.type_unit}}</text>
|
||||
<text wx:if="{{(item.coupon.desc || null) != null}}" class="desc cr-888">{{item.coupon.desc}}</text>
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
<view class="item spacing-mt bg-white item-disabled">
|
||||
<view class="v-left fl">
|
||||
<view class="base single-text">
|
||||
<text class="symbol">{{price_symbol}}</text>
|
||||
<text wx:if="{{item.coupon.type == 0}}" class="symbol">{{price_symbol}}</text>
|
||||
<text class="price">{{item.coupon.discount_value}}</text>
|
||||
<text class="unit">{{item.coupon.type_unit}}</text>
|
||||
<text wx:if="{{(item.coupon.desc || null) != null}}" class="desc cr-888">{{item.coupon.desc}}</text>
|
||||
|
|
@ -60,7 +60,7 @@
|
|||
<view class="item spacing-mt bg-white item-disabled">
|
||||
<view class="v-left fl">
|
||||
<view class="base single-text">
|
||||
<text class="symbol">{{price_symbol}}</text>
|
||||
<text wx:if="{{item.coupon.type == 0}}" class="symbol">{{price_symbol}}</text>
|
||||
<text class="price">{{item.coupon.discount_value}}</text>
|
||||
<text class="unit">{{item.coupon.type_unit}}</text>
|
||||
<text wx:if="{{(item.coupon.desc || null) != null}}" class="desc cr-888">{{item.coupon.desc}}</text>
|
||||
|
|
|
|||
Loading…
Reference in New Issue