|
|
@ -1,24 +1,21 @@ |
|
|
|
<template> |
|
|
|
<view class="page"> |
|
|
|
<navbar title="商品详情" leftClick @leftClick="$utils.navigateBack" /> |
|
|
|
|
|
|
|
|
|
|
|
<view class="swipe"> |
|
|
|
<uv-swiper |
|
|
|
:list="productDetail.image.split(',')" |
|
|
|
indicator |
|
|
|
height="350rpx"></uv-swiper> |
|
|
|
<uv-swiper :list="productDetailList.waresImage.split(',')" indicator height="350rpx"></uv-swiper> |
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
<view class="info"> |
|
|
|
<view class="title"> |
|
|
|
桌布租赁 |
|
|
|
{{productDetailList.waresTitle}} |
|
|
|
</view> |
|
|
|
<view class="info-line"> |
|
|
|
<view class="price"> |
|
|
|
¥<text>45.9</text>起 |
|
|
|
¥<text>{{productDetailList.waresPrice}}</text>起 |
|
|
|
</view> |
|
|
|
<view class="num"> |
|
|
|
已售1000+ |
|
|
|
{{productDetailList.waresSales}} |
|
|
|
<image src="../static/product/like.png" mode=""></image> |
|
|
|
</view> |
|
|
|
</view> |
|
|
@ -34,35 +31,33 @@ |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
<view class="info-unit"> |
|
|
|
<uv-cell title="服务" isLink> |
|
|
|
<template #icon> |
|
|
|
<text class="text">免费上门退·7天无理由退货·快递发货</text> |
|
|
|
</template> |
|
|
|
</uv-cell> |
|
|
|
|
|
|
|
|
|
|
|
<uv-cell title="参数" isLink> |
|
|
|
<template #icon> |
|
|
|
<text class="text">品牌;适应人群</text> |
|
|
|
</template> |
|
|
|
</uv-cell> |
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
<view class="content"> |
|
|
|
<view class="title"> |
|
|
|
详情 |
|
|
|
</view> |
|
|
|
<uv-parse :content="productDetail.content"></uv-parse> |
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
<!-- 分享和租赁按钮 --> |
|
|
|
<submit |
|
|
|
@submit="$refs.submitUnitSelect.open()" |
|
|
|
@share="share"/> |
|
|
|
|
|
|
|
<submit @submit="$refs.submitUnitSelect.open()" @share="share" /> |
|
|
|
|
|
|
|
<!-- 选择规格 --> |
|
|
|
<submitUnitSelect ref="submitUnitSelect"/> |
|
|
|
<submitUnitSelect ref="submitUnitSelect" /> |
|
|
|
</view> |
|
|
|
</template> |
|
|
|
|
|
|
@ -70,94 +65,120 @@ |
|
|
|
import submit from '../components/product/submit.vue' |
|
|
|
import submitUnitSelect from '../components/product/submitUnitSelect.vue' |
|
|
|
export default { |
|
|
|
components : { |
|
|
|
components: { |
|
|
|
submit, |
|
|
|
submitUnitSelect |
|
|
|
}, |
|
|
|
data() { |
|
|
|
return { |
|
|
|
productDetail : { |
|
|
|
image : 'https://cdn.uviewui.com/uview/swiper/swiper3.png,https://cdn.uviewui.com/uview/swiper/swiper2.png', |
|
|
|
content : '', |
|
|
|
productDetail: { |
|
|
|
image: 'https://cdn.uviewui.com/uview/swiper/swiper3.png,https://cdn.uviewui.com/uview/swiper/swiper2.png', |
|
|
|
content: '', |
|
|
|
productId: '', |
|
|
|
productDetailList:'' |
|
|
|
}, |
|
|
|
} |
|
|
|
}, |
|
|
|
onLoad(args) { |
|
|
|
console.log(args); |
|
|
|
this.productId = args.id |
|
|
|
this.queryWaresById() |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
// 分享商品 |
|
|
|
share(){ |
|
|
|
|
|
|
|
share() { |
|
|
|
|
|
|
|
}, |
|
|
|
// 选择完成规格立即租赁下单 |
|
|
|
submit(){ |
|
|
|
|
|
|
|
submit() { |
|
|
|
|
|
|
|
}, |
|
|
|
queryWaresById() { |
|
|
|
this.$api('queryWaresById', { |
|
|
|
waresId: this.productId |
|
|
|
}, |
|
|
|
res => { |
|
|
|
if (res.code == 200) { |
|
|
|
console.log(res); |
|
|
|
this.productDetailList = res.result |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
|
|
|
|
<style scoped lang="scss"> |
|
|
|
.page{ |
|
|
|
.swipe{ |
|
|
|
|
|
|
|
} |
|
|
|
.info{ |
|
|
|
padding: 30rpx; |
|
|
|
background-color: #fff; |
|
|
|
.title{ |
|
|
|
font-size: 34rpx; |
|
|
|
font-weight: 900; |
|
|
|
} |
|
|
|
.info-line{ |
|
|
|
display: flex; |
|
|
|
justify-content: space-between; |
|
|
|
align-items: center; |
|
|
|
margin-top: 30rpx; |
|
|
|
.price{ |
|
|
|
font-size: 28rpx; |
|
|
|
color: $uni-color; |
|
|
|
text{ |
|
|
|
font-size: 34rpx; |
|
|
|
.page { |
|
|
|
.swipe {} |
|
|
|
|
|
|
|
.info { |
|
|
|
padding: 30rpx; |
|
|
|
background-color: #fff; |
|
|
|
|
|
|
|
.title { |
|
|
|
font-size: 34rpx; |
|
|
|
font-weight: 900; |
|
|
|
} |
|
|
|
|
|
|
|
.info-line { |
|
|
|
display: flex; |
|
|
|
justify-content: space-between; |
|
|
|
align-items: center; |
|
|
|
margin-top: 30rpx; |
|
|
|
|
|
|
|
.price { |
|
|
|
font-size: 28rpx; |
|
|
|
color: $uni-color; |
|
|
|
|
|
|
|
text { |
|
|
|
font-size: 34rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
.num { |
|
|
|
font-size: 24rpx; |
|
|
|
|
|
|
|
image { |
|
|
|
width: 24rpx; |
|
|
|
height: 24rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
.num{ |
|
|
|
font-size: 24rpx; |
|
|
|
image{ |
|
|
|
width: 24rpx; |
|
|
|
height: 24rpx; |
|
|
|
|
|
|
|
.tips { |
|
|
|
display: flex; |
|
|
|
font-size: 20rpx; |
|
|
|
margin-top: 30rpx; |
|
|
|
|
|
|
|
.tip { |
|
|
|
margin-right: 40rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
.tips{ |
|
|
|
display: flex; |
|
|
|
font-size: 20rpx; |
|
|
|
margin-top: 30rpx; |
|
|
|
.tip{ |
|
|
|
margin-right: 40rpx; |
|
|
|
|
|
|
|
.info-unit { |
|
|
|
margin-top: 20rpx; |
|
|
|
padding: 30rpx; |
|
|
|
background-color: #fff; |
|
|
|
|
|
|
|
/deep/ text { |
|
|
|
font-size: 26rpx; |
|
|
|
} |
|
|
|
|
|
|
|
/deep/ .text { |
|
|
|
color: #7C7C7C; |
|
|
|
margin-right: 20rpx; |
|
|
|
font-size: 26rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
.info-unit{ |
|
|
|
margin-top: 20rpx; |
|
|
|
padding: 30rpx; |
|
|
|
background-color: #fff; |
|
|
|
/deep/ text{ |
|
|
|
font-size: 26rpx; |
|
|
|
} |
|
|
|
/deep/ .text{ |
|
|
|
color: #7C7C7C; |
|
|
|
margin-right: 20rpx; |
|
|
|
font-size: 26rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
.content{ |
|
|
|
background-color: #fff; |
|
|
|
margin-top: 20rpx; |
|
|
|
.title{ |
|
|
|
padding: 30rpx; |
|
|
|
|
|
|
|
.content { |
|
|
|
background-color: #fff; |
|
|
|
margin-top: 20rpx; |
|
|
|
|
|
|
|
.title { |
|
|
|
padding: 30rpx; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</style> |
|
|
|
</style> |