12 changed files with 149 additions and 222 deletions
Unified View
Diff Options
-
11pages/mall/order-info/index.js
-
6pages/mall/order-info/index.wxml
-
22pages/mall/page-list/index.js
-
6pages/mall/page-list/index.json
-
23pages/mall/page-list/index.wxml
-
76pages/mall/page-list/index.wxss
-
3pages/mall/search-list/index.json
-
24pages/mall/search-list/index.wxml
-
75pages/mall/search-list/index.wxss
-
3pages/mall/shops/index.json
-
46pages/mall/shops/index.wxml
-
76pages/mall/shops/index.wxss
@ -0,0 +1,22 @@ |
|||||
|
// pages/message/index.js
|
||||
|
|
||||
|
Component({ |
||||
|
options: { |
||||
|
addGlobalClass: true, |
||||
|
multipleSlots: true |
||||
|
}, |
||||
|
properties: { |
||||
|
dataList: { // 必选,通知本组件收起
|
||||
|
type: Array, |
||||
|
value: null, |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
lookItem: function (e) { |
||||
|
var item = this.data.dataList[e.currentTarget.dataset.index] |
||||
|
wx.navigateTo({ |
||||
|
url: '/pages/mall/order-info/index?id=' + item.id |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
@ -0,0 +1,6 @@ |
|||||
|
{ |
||||
|
"component": true, |
||||
|
"usingComponents": { |
||||
|
"wux-image": "/components/image/index" |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,23 @@ |
|||||
|
<view class="flex content" wx:for="{{dataList}}" wx:key="index" data-index="{{index}}" bindtap="lookItem"> |
||||
|
<wux-image width="{{119}}" height="{{119}}" wux-class="page-icon" lazyLoad="true" src="{{item.litimgUrl}}" mode="aspectFill"> |
||||
|
<view class="image-load" slot="loading"> |
||||
|
<text class="icon--refresher"></text> |
||||
|
</view> |
||||
|
</wux-image> |
||||
|
<view style="flex:1;padding:16rpx 20rpx"> |
||||
|
<view class="flex flex-justify"> |
||||
|
<view class="page-name">{{item.name}}</view> |
||||
|
<view class="page-num" wx:if="{{item.sellMode == 1}}">{{item.viewNum}} 浏览</view> |
||||
|
<view class="page-num" wx:elif="{{item.sellMode == 2}}">已拼{{item.soldNum}}{{item.unit}}</view> |
||||
|
</view> |
||||
|
<view style="height:100rpx"> |
||||
|
<view class="page-outline">{{item.outline}}</view> |
||||
|
<view class="page-outline" style="margin-top: 8rpx">{{item.summary}}</view> |
||||
|
</view> |
||||
|
<view class="flex flex-justify" style="align-items:flex-end"> |
||||
|
<view class="page-price">¥{{item.price}}</view> |
||||
|
<view class="page-stock" style="margin-bottom:6rpx">库存:{{item.stockNumber}}{{item.unit}}</view> |
||||
|
<button class="cu-btn bg-red round shadow-blur page-btn">立即抢购</button> |
||||
|
</view> |
||||
|
</view> |
||||
|
</view> |
||||
@ -0,0 +1,76 @@ |
|||||
|
/* pages/message/index.wxss */ |
||||
|
|
||||
|
.content { |
||||
|
margin-top: 24rpx; |
||||
|
background: rgba(255, 255, 255, 1); |
||||
|
border-radius: 6px; |
||||
|
} |
||||
|
|
||||
|
.page-icon { |
||||
|
height: 240rpx; |
||||
|
width: 240rpx; |
||||
|
border-top-left-radius: 12rpx; |
||||
|
border-bottom-left-radius: 12rpx; |
||||
|
} |
||||
|
|
||||
|
.page-name { |
||||
|
font-size: 16px; |
||||
|
font-family: PingFang-SC-Medium, PingFang-SC; |
||||
|
font-weight: 500; |
||||
|
color: rgba(51, 51, 51, 1); |
||||
|
line-height: 22px; |
||||
|
} |
||||
|
|
||||
|
.page-num { |
||||
|
margin-top: 8rpx; |
||||
|
font-size: 10px; |
||||
|
font-family: PingFang-SC-Regular, PingFang-SC; |
||||
|
font-weight: 400; |
||||
|
color: rgba(51, 51, 51, 1); |
||||
|
} |
||||
|
|
||||
|
.page-outline { |
||||
|
margin-top: 8rpx; |
||||
|
font-size: 10px; |
||||
|
font-family: PingFang-SC-Regular, PingFang-SC; |
||||
|
font-weight: 400; |
||||
|
color: rgba(51, 51, 51, 1); |
||||
|
display: -webkit-box; |
||||
|
overflow: hidden; |
||||
|
text-overflow: ellipsis; |
||||
|
word-wrap: break-word; |
||||
|
white-space: normal !important; |
||||
|
-webkit-line-clamp: 2; |
||||
|
-webkit-box-orient: vertical; |
||||
|
} |
||||
|
|
||||
|
.page-btn { |
||||
|
height: 27px; |
||||
|
background: rgba(255, 66, 43, 1); |
||||
|
box-shadow: 0px 4px 14px -6px rgba(255, 43, 45, 0.8); |
||||
|
color: white; |
||||
|
font-size: 12px; |
||||
|
} |
||||
|
|
||||
|
.page-price { |
||||
|
font-size: 16px; |
||||
|
font-family: DINAlternate-Bold, DINAlternate; |
||||
|
font-weight: bold; |
||||
|
color: rgba(255, 66, 43, 1); |
||||
|
} |
||||
|
|
||||
|
.page-stock { |
||||
|
font-size: 10px; |
||||
|
font-family: PingFang-SC-Regular, PingFang-SC; |
||||
|
font-weight: 400; |
||||
|
color: rgba(153, 153, 153, 1); |
||||
|
line-height: 14px; |
||||
|
} |
||||
|
|
||||
|
.image-load { |
||||
|
width: 240rpx; |
||||
|
height: 240rpx; |
||||
|
display: flex; |
||||
|
align-items: center; |
||||
|
justify-content: center; |
||||
|
} |
||||
Write
Preview
Loading…
Cancel
Save