Commit 9d1ad93cf5e110742bb3b0e9ed99e8defa067069

Authored by 后端开发-许程
1 parent 3662e4d9

等级价显示

components/goods_list/goods_list.wxml
... ... @@ -23,7 +23,7 @@
23 23 <view class="flex xc-wc">
24 24 <view class="fs24">¥</view>
25 25 <view class="fs35">{{filter.toFix(item[card_field],2)}}</view>
26   - <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image><text>{{card_name}}</text></view>
  26 + <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image><view class="card_name">{{card_name}}</view></view>
27 27 </view>
28 28 </view>
29 29 <view class="flex" style="line-height: 28rpx;" >
... ...
components/goods_list/goods_list.wxss
... ... @@ -2,7 +2,7 @@
2 2 margin-top: 40rpx;
3 3 }
4 4 .ib{
5   - display: inline-block;
  5 + display: inline-block;
6 6 }
7 7 .fs20{
8 8 font-size: 20rpx;
... ... @@ -151,6 +151,11 @@ color: #b9b9b9;
151 151 }
152 152  
153 153 .line_th{ text-decoration: line-through}
154   -.card_bg {display: flex; padding: 0rpx 10rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;line-height: 28rpx;
  154 +.card_bg {display: flex; padding: 2rpx 10rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;line-height: 28rpx;max-width: 110rpx;
155 155 background: #333; color: #fff; justify-content: center; margin-left: 2rpx;}
156   -.card_bg image{ width: 19rpx; height: 19rpx; margin-right: 1rpx;}
157 156 \ No newline at end of file
  157 +.card_bg image{ width: 19rpx; height: 19rpx; margin-right: 1rpx;}.card_bg .card_name{
  158 + max-width: 76rpx;
  159 + width: auto;
  160 + overflow: hidden;
  161 + white-space:nowrap;
  162 +}
158 163 \ No newline at end of file
... ...
pages/goods/goodsList/goodsList.wxml
... ... @@ -47,7 +47,8 @@
47 47 <block wx:if="{{item[card_field]>0}}">
48 48 <view class="flex ai-center">
49 49 <view class="price">¥{{item[card_field]}}</view>
50   - <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image>{{card_name}}</view>
  50 + <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image>
  51 + <view class="card_name">{{card_name}}</view></view>
51 52 </view>
52 53 <view class="comment flex jc_sb">
53 54 <view class="word-line xc-ash">¥{{item.market_price}}</view>
... ...
pages/goods/goodsList/goodsList.wxss
... ... @@ -156,8 +156,17 @@
156 156 width: 300rpx;
157 157 }
158 158  
159   -.card_bg {display: flex; width: 110rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;
160   -background: #333; color: #fff; justify-content: center; margin-left: 3rpx; margin-top:7rpx; line-height: 28rpx;}
  159 +.card_bg {display: flex; max-width: 110rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;
  160 +background: #333; color: #fff; justify-content: center; margin-left: 3rpx; margin-top:7rpx; line-height: 28rpx;
  161 +padding: 2rpx 10rpx;width: auto;
  162 +
  163 +}
  164 +.card_bg .card_name{
  165 + max-width: 76rpx;
  166 + width: auto;
  167 + overflow: hidden;
  168 + white-space:nowrap;
  169 +}
161 170 .card_bg image{ width: 19rpx; height: 19rpx; margin-right: 1rpx; vertical-align: middle}
162 171 .mk_price{margin-left: 10rpx; font-size: 25rpx;}
163 172 .item-cont{ line-height: 38rpx}
164 173 \ No newline at end of file
... ...
pages/goods/search/search.wxml
... ... @@ -43,7 +43,9 @@
43 43 <block wx:if="{{item[card_field]>0}}">
44 44 <view class="flex ai-center">
45 45 <view class="price">¥{{item[card_field]}}</view>
46   - <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image>{{card_name}}</view>
  46 + <view class="card_bg"><image src="{{url}}/miniapp/images/plus/dj_icon.png"></image>
  47 + <view class="card_name">{{card_name}}</view>
  48 + </view>
47 49 </view>
48 50 <view class="comment flex jc_sb">
49 51 <view class="word-line xc-ash">¥{{item.market_price}}</view>
... ...
pages/goods/search/search.wxss
... ... @@ -227,8 +227,14 @@
227 227 margin-left: 15rpx;
228 228 }
229 229  
230   -.card_bg {display: flex; width: 110rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;
231   -background: #333; color: #fff; justify-content: center; margin-left: 3rpx; margin-top:7rpx; line-height: 28rpx;}
232   -.card_bg image{ width: 19rpx; height: 19rpx; margin-right: 1rpx; vertical-align: middle}
  230 +.card_bg {display: flex; max-width: 110rpx;height: 28rpx; align-items: center; border-radius: 26rpx; font-size: 19rpx;padding: 2rpx 10rpx;
  231 +background: #333; color: #fff; justify-content: center; margin-left: 3rpx; margin-top:7rpx; line-height: 28rpx; width: auto}
  232 +.card_bg image{ width: 19rpx; height: 19rpx; margin-right: 1rpx; vertical-align: middle}
  233 +.card_bg .card_name{
  234 + max-width: 76rpx;
  235 + width: auto;
  236 + overflow: hidden;
  237 + white-space:nowrap;
  238 +}
233 239 .mk_price{margin-left: 10rpx; font-size: 25rpx;}
234 240 .item-cont{ line-height: 38rpx}
... ...