完善小程序
This commit is contained in:
@@ -18,17 +18,20 @@
|
||||
<up-image :src="item.coverImg" width="80" radius="10" height="80"></up-image>
|
||||
</view>
|
||||
<view class="info">
|
||||
<view class="name"> {{ item.name }} </view>
|
||||
<view class="name"> {{item.cartListinfo.is_temporary == 1?'临时菜' :item.name }}
|
||||
</view>
|
||||
<view class="select-sku-wrap" v-if="item.type == 'sku'">
|
||||
<text v-for="i in item.skuList" :key="i.id">
|
||||
{{item.cartListinfo.sku_id == i.id? i.name:"" }}
|
||||
</text>
|
||||
</view>
|
||||
<view class="select-sku-wrap" v-if="item.type == 'package'">
|
||||
<view>{{dataprocessing(item.cartListinfo).title}}</view>
|
||||
<text v-for="i in dataprocessing(item.cartListinfo).goods" :key="i.id">
|
||||
{{i.proName }}
|
||||
</text>
|
||||
<view v-for="(a,b) in dataprocessing(item.cartListinfo)" :key="b">
|
||||
<!-- <view>{{a.title}}</view> -->
|
||||
<text v-for="i in a.goods" :key="i.proId" style="margin-left: 4rpx;">
|
||||
{{i.proName }}
|
||||
</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price-wrap" style="padding-top: 0;">
|
||||
<view class="price">
|
||||
@@ -147,7 +150,14 @@
|
||||
|
||||
const dataprocessing = computed(() => {
|
||||
return (item) => {
|
||||
return JSON.parse(item.pro_group_info);
|
||||
console.log(item.pro_group_info)
|
||||
let res = null
|
||||
try {
|
||||
res = JSON.parse(item.pro_group_info)
|
||||
} catch (error) {
|
||||
//TODO handle the exception
|
||||
}
|
||||
return res
|
||||
};
|
||||
})
|
||||
|
||||
@@ -234,6 +244,8 @@
|
||||
|
||||
.shop-item-content {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.shop-item-remark {
|
||||
|
||||
Reference in New Issue
Block a user