0000
This commit is contained in:
7
pages/goodsDetails/recomondList/recomondList.js
Normal file
7
pages/goodsDetails/recomondList/recomondList.js
Normal file
@@ -0,0 +1,7 @@
|
||||
Component({
|
||||
properties: {
|
||||
list: Array
|
||||
},
|
||||
data: {},
|
||||
methods: {}
|
||||
});
|
||||
4
pages/goodsDetails/recomondList/recomondList.json
Normal file
4
pages/goodsDetails/recomondList/recomondList.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
39
pages/goodsDetails/recomondList/recomondList.wxml
Normal file
39
pages/goodsDetails/recomondList/recomondList.wxml
Normal file
@@ -0,0 +1,39 @@
|
||||
<view class="small-list">
|
||||
<navigator class="item router-link-active" hoverClass="hover" url="/pages/goodsDetails/goodsDetails?id={{item.id}}" wx:for="{{list}}" wx:key="index">
|
||||
<view class="inner">
|
||||
<view class="hd">
|
||||
<view class="image-box __56">
|
||||
<image lazy="loaded" mode="widthFix" src="{{item.image}}"></image>
|
||||
</view>
|
||||
<view class="issaled" wx:if="{{item.stock==0}}">
|
||||
<image src="/img/issaled.png"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="bd">
|
||||
<view style="margin: 0px 0px 4px;">
|
||||
<view style="overflow: hidden;">
|
||||
<view class="title __small" style="-webkit-line-clamp: 2; height: 2.6em;">{{item.name}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="bd-btm">
|
||||
<view class="_btm_lt">
|
||||
<view style="margin: 0px 0px -3px;">
|
||||
<view class="now-price __normal">
|
||||
<view class="symbol">¥</view>
|
||||
<view class="buck">{{item.price_buck}}.</view>
|
||||
<view class="cent">{{item.price_cent}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view style="margin: 3px 0px 0px; font-size: 0px; line-height: 1.2;">
|
||||
<view class="old-price">¥{{item.marketprice}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view style="text-align: right;">
|
||||
<view class="vip-price-wrap"></view>
|
||||
<view style="margin: 5px 0px 0px; font-size: 12px; line-height: 1.2; color: rgb(150, 150, 150);">{{item.num_buy}}已售</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</navigator>
|
||||
</view>
|
||||
140
pages/goodsDetails/recomondList/recomondList.wxss
Normal file
140
pages/goodsDetails/recomondList/recomondList.wxss
Normal file
@@ -0,0 +1,140 @@
|
||||
.small-list {
|
||||
display: -webkit-box;
|
||||
display: -ms-flexbox;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
margin: -5.333vw 0 0 -4vw;
|
||||
}
|
||||
|
||||
.small-list .item {
|
||||
-webkit-box-flex: 50%;
|
||||
box-sizing: border-box;
|
||||
flex: 50% 0 0;
|
||||
margin-top: 5.333vw;
|
||||
padding: 0 0 0 4vw;
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
.small-list .hd {
|
||||
border-radius: 1.067vw;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.image-box.__56 {
|
||||
padding-top: 56.25%;
|
||||
}
|
||||
|
||||
.image-box image {
|
||||
height: 100%;
|
||||
left: 0;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.small-list .bd {
|
||||
padding: 2.667vw 0 0;
|
||||
}
|
||||
|
||||
.small-list .title {
|
||||
-webkit-box-orient: vertical;
|
||||
color: #222;
|
||||
display: -webkit-box;
|
||||
line-height: 1.4em;
|
||||
margin: 0 0 .2em;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.small-list .title.__small {
|
||||
font-size: 3.733vw;
|
||||
}
|
||||
|
||||
.small-list .bd-btm {
|
||||
-webkit-box-align: end;
|
||||
-ms-flex-align: end;
|
||||
-webkit-box-pack: justify;
|
||||
-ms-flex-pack: justify;
|
||||
align-items: flex-end;
|
||||
height: 9.6vw;
|
||||
justify-content: space-between;
|
||||
margin: 0 0 .8vw;
|
||||
}
|
||||
|
||||
._btm_lt,.small-list .bd-btm {
|
||||
display: -webkit-box;
|
||||
display: -ms-flexbox;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
._btm_lt {
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-box-direction: normal;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.now-price {
|
||||
color: #eb5252;
|
||||
font-family: DIN;
|
||||
line-height: 1.75em;
|
||||
}
|
||||
|
||||
.now-price,.now-price.__normal {
|
||||
font-size: 3.2vw;
|
||||
}
|
||||
|
||||
.now-price .symbol {
|
||||
display: inline;
|
||||
margin: 0 .267vw 0 0;
|
||||
}
|
||||
|
||||
.now-price.__normal .buck {
|
||||
display: inline;
|
||||
font-size: 4.8vw;
|
||||
}
|
||||
|
||||
.cent {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.now-price .qi {
|
||||
display: inline;
|
||||
margin: 0 0 0 .267vw;
|
||||
}
|
||||
|
||||
.old-price {
|
||||
color: #9b9b9b;
|
||||
font-family: DIN;
|
||||
font-size: 3.2vw;
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.vip-price-wrap {
|
||||
height: 3.467vw;
|
||||
}
|
||||
|
||||
.issaled {
|
||||
align-items: center;
|
||||
background: rgba(0,0,0,.4);
|
||||
border-radius: 5px;
|
||||
display: flex;
|
||||
height: 100%;
|
||||
justify-content: center;
|
||||
left: 0;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.issaled image {
|
||||
height: 120rpx;
|
||||
width: 120rpx;
|
||||
}
|
||||
|
||||
.hover {
|
||||
background: transparent;
|
||||
}
|
||||
Reference in New Issue
Block a user