7.16
This commit is contained in:
@@ -4,21 +4,25 @@
|
||||
<view class="title">
|
||||
<view class="name">全部秒杀</view>
|
||||
<view class="time">
|
||||
<text class="num">12</text>
|
||||
<text class="num">{{ time.littleHour }}</text>
|
||||
<text class="mah">:</text>
|
||||
<text class="num">12</text>
|
||||
<text class="num">00</text>
|
||||
<text class="mah">:</text>
|
||||
<text class="num">12</text>
|
||||
<text class="num">00</text>
|
||||
<text>-</text>
|
||||
<text class="num">{{ time.bigHour }}</text>
|
||||
<text class="mah">:</text>
|
||||
<text class="num">00</text>
|
||||
<text class="mah">:</text>
|
||||
<text class="num">00</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="next">
|
||||
<view class="next" @click="viewMore">
|
||||
查看更多>
|
||||
</view>
|
||||
</view>
|
||||
<view class="list">
|
||||
<sitem></sitem>
|
||||
<sitem></sitem>
|
||||
<sitem></sitem>
|
||||
<sitem v-for="(item, index) in list.slice(0, 3)" :key="index" :item="item"></sitem>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -28,7 +32,15 @@ export default {
|
||||
name:"seckill",
|
||||
components:{
|
||||
sitem
|
||||
}
|
||||
},
|
||||
props: ['list', 'time'],
|
||||
methods: {
|
||||
viewMore() {
|
||||
this.$u.route({
|
||||
url: '/pageC/spike/index',
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@@ -46,15 +58,17 @@ export default {
|
||||
color: #333;
|
||||
}
|
||||
.time{
|
||||
margin-left: 39rpx;
|
||||
margin-left: 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 20rpx;
|
||||
.num{
|
||||
box-sizing: content-box;
|
||||
width: 25rpx;
|
||||
height: 25rpx;
|
||||
background-color: #bfbfbf;
|
||||
margin: 0 10rpx;
|
||||
padding: 2rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,25 +1,33 @@
|
||||
<template>
|
||||
<view class="item">
|
||||
<image class="head"></image>
|
||||
<text class="title">商品名</text>
|
||||
<image class="head" :src="item.groupbuy_image1"></image>
|
||||
<text class="title u-line-2">{{ item.goods_name }}</text>
|
||||
<view class="price">
|
||||
<text>¥99</text>
|
||||
<text>¥299</text>
|
||||
<text>¥{{ item.groupbuy_price }}</text>
|
||||
<text>¥{{ item.goods_price }}</text>
|
||||
</view>
|
||||
<view class="info">
|
||||
<text>剩余21件</text>
|
||||
<text>剩余{{ item.inventory | formatValue }}件</text>
|
||||
<text>立即购买</text>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
export default {
|
||||
name:"item"
|
||||
name:"item",
|
||||
props: ['item'],
|
||||
filters: {
|
||||
formatValue(value) {
|
||||
let temp = Number(value);
|
||||
if(temp > 999) temp = '999+';
|
||||
return temp;
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.item{
|
||||
width: 210rpx;
|
||||
width: 220rpx;
|
||||
.head{
|
||||
width: 210rpx;
|
||||
height: 131rpx;
|
||||
@@ -43,6 +51,7 @@ export default {
|
||||
>text:last-child{
|
||||
font-size: 24rpx;
|
||||
color: #999;
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -50,7 +59,7 @@ export default {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
font-size: 20rpx;
|
||||
margin-top: 19rpx;
|
||||
>text:first-child{
|
||||
color: #666;
|
||||
|
||||
Reference in New Issue
Block a user