123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- <template>
- <cm-drawer title="商品参数" :visible="visible" @close="$emit('close')" position="bottom">
- <scroll-view scroll-y="true" class="cm-product-params">
- <view class="content-tr">
- <view class="content-td">品牌:</view>
- <view class="content-th">{{ productInfo.brandName == null ? '其他' : productInfo.brandName }}</view>
- </view>
- <view class="content-tr">
- <view class="content-td">包装规格:</view> <view class="content-th">{{ productInfo.unit }}</view>
- </view>
- <view class="content-tr">
- <view class="content-td">库存:</view> <view class="content-th">{{ productInfo.stock }}</view>
- </view>
- <view
- class="content-tr"
- v-if="productInfo.parametersList.length > 0"
- v-for="(item, index) in productInfo.parametersList"
- :key="index"
- >
- <view class="content-td">{{ item.paramsName }}:</view>
- <view class="content-th">{{ item.paramsContent }}</view>
- </view>
- </scroll-view>
- </cm-drawer>
- </template>
- <script>
- import CmDrawer from '../cm-drawer/cm-drawer.vue'
- export default {
- components: {
- CmDrawer
- },
- props: {
- productInfo: {
- type: Object,
- default: () => {}
- },
- visible: {
- type: Boolean,
- default: false
- }
- },
- }
- </script>
- <style lang="scss" scoped>
- .cm-product-params {
- width: 100%;
- padding-top: 24rpx;
- height: 320rpx;
- .content-tr {
- width: 100%;
- min-height: 58rpx;
- line-height: 58rpx;
- display: flex;
- .content-td {
- display: flex;
- flex: 3;
- font-size: 26rpx;
- color: #999999;
- line-height: 58rpx;
- text-align: right;
- }
- .content-th {
- display: flex;
- flex: 7;
- font-size: 26rpx;
- color: #333333;
- line-height: 58rpx;
- text-align: left;
- padding-left: 10rpx;
- }
- }
- }
- </style>
|