Browse Source

sku显示

dev_des
1054425342@qq.com 2 months ago
parent
commit
a148b283c0
  1. 15
      pages/index/index.vue
  2. 2
      subPackages/equityGoods/index.vue
  3. 27
      subPackages/equityGoods/list.vue
  4. 48
      subPackages/orderQy/detail.vue
  5. 28
      subPackages/orderQy/list.vue

15
pages/index/index.vue

@ -118,6 +118,21 @@ export default {
async onReady() {
let res = await this.$main.getLocationInfo();
console.log(res);
if(!res.cityId){
res = {
address: "江苏省苏州市吴中区太湖东路288号",
area: "吴中区",
areaId: "320506",
city: "苏州市",
cityId: "320500",
latitude: 31.26249,
longitude: 120.63212,
province: "江苏省",
provinceId: "320000",
street: "太湖东路",
}
}
this.addressInfo = res;
this.selectedText = res && res.city;
uni.setStorageSync("SYS_ADDRESS_INFO", JSON.stringify(res));

2
subPackages/equityGoods/index.vue

@ -28,7 +28,7 @@
"/framework/index/getUrl",
'DES'
).then((res) => {
this.img = res.msg
this.img = res.data.imageUrl
});
},
toList(){

27
subPackages/equityGoods/list.vue

@ -1,7 +1,7 @@
<template>
<view class="equity-goods-page">
<image style="width: 100%" mode="widthFix"
:src="showImg('/uploads/20250728/748adc244fc7db313f569a6005344950.png')"></image>
:src="showImg(cityInfo.bannerUrl)"></image>
<view class="location-selector" v-if="addressInfo">
<AreaPicker :defaultValue="{
provinceId: addressInfo.provinceId,
@ -73,7 +73,7 @@
<view class="map-section">
<view class="map-title" @click="showReservationPopup">业务办理 | 预约参观</view>
<view class="map-container">
<map class="map-component" :latitude="mapData.latitude" :longitude="mapData.longitude"
<map class="map-component" :latitude="cityInfo.lat" :longitude="cityInfo.lng"
:scale="mapData.scale"></map>
</view>
<view class="map-description">
@ -81,7 +81,7 @@
<image class="location-icon" :src="
showImg('/uploads/20250728/56804fe109efd614ba955d3110cd6750.png')
" mode="widthFix"></image>
<text class="location-name">国家文化大数据华东区域交易平台{{addressInfo&&addressInfo.city}}运营中心</text>
<text class="location-name">国家文化大数据交易平台{{addressInfo&&addressInfo.city}}运营中心</text>
</view>
</view>
</view>
@ -145,7 +145,8 @@
phone: "",
},
sortValue: '',
addressInfo: {}
addressInfo: {},
cityInfo:{}
};
},
onLoad() {
@ -153,13 +154,25 @@
if (address) {
this.addressInfo = JSON.parse(address)
}
this.getInfoCity()
this.geBenefitPackaget()
},
methods: {
changeAddress(e){
getInfoCity() {
let code = this.addressInfo.cityId
this.Post({
cityId: code
},
"/framework/index/getUrl",
'DES'
).then((res) => {
this.cityInfo = res.data
});
},
changeAddress(e) {
console.log(e)
this.addressInfo =e
uni.setStorageSync('SYS_ADDRESS_INFO',JSON.stringify(e))
this.addressInfo = e
uni.setStorageSync('SYS_ADDRESS_INFO', JSON.stringify(e))
this.geBenefitPackaget()
},
hanleUpdate(e) {

48
subPackages/orderQy/detail.vue

@ -38,8 +38,14 @@
<view class="goods-content">
<view class="goods-info">
<view class="goods-name">{{ goods.goodsTitle || "-" }}</view>
<view class="goods-name" v-if="goods.skuName">{{ goods.skuName || "-" }}</view>
<view class="goods-desc">{{ getGoodsTypeName(goods.type) }}</view>
<view class="goods-quantity">数量{{ goods.num || 1 }}</view>
<view class="goods-specs" v-if="goods.orderExchangeVo && goods.orderExchangeVo.orderExchangeDetailVos">
<view class="spec-tag" v-for="(item, index) in goods.orderExchangeVo.orderExchangeDetailVos" :key="index">
{{item.specValueOne}} / {{item.specValueTwo}}
</view>
</view>
</view>
<view class="goods-actions">
<button
@ -187,7 +193,17 @@
</view>
<view class="popup-content">
<!-- 商品状态 -->
<view class="logistics-section" v-if="currentGoodsInfo">
<view class="section-title">商品状态</view>
<view class="status-info">
<view
class="status-badge-popup"
:class="[getGoodsStatusClass(currentGoodsInfo.status)]"
>
{{ getGoodsStatusText(currentGoodsInfo.status) }}
</view>
</view>
</view>
<!-- 收货地址 -->
<view class="logistics-section">
@ -270,6 +286,7 @@ export default {
showEquityPopup: false,
showLogisticsPopup: false, //
currentLogisticsInfo: null, //
currentGoodsInfo: null, //
orderDetail: {
orderChildVos: [],
},
@ -413,7 +430,7 @@ export default {
const typeMap = {
1: "IP数字资产",
2: "IP资源商品",
3: "君道苏州门票",
3: "门票",
};
return typeMap[type] || "未知类型";
},
@ -517,6 +534,7 @@ export default {
showLogisticsInfo(goods) {
if (goods.orderExchangeVo) {
this.currentLogisticsInfo = goods.orderExchangeVo;
this.currentGoodsInfo = goods;
this.showLogisticsPopup = true;
} else {
uni.showToast({
@ -530,6 +548,7 @@ export default {
closeLogisticsPopup() {
this.showLogisticsPopup = false;
this.currentLogisticsInfo = null;
this.currentGoodsInfo = null;
},
//
@ -1107,12 +1126,13 @@ export default {
.status-info {
display: flex;
align-items: center;
margin-bottom: 8rpx;
}
.status-badge-popup {
padding: 8rpx 16rpx;
border-radius: 20rpx;
font-size: 24rpx;
padding: 6rpx 12rpx;
border-radius: 12rpx;
font-size: 22rpx;
color: #fff;
font-weight: 500;
@ -1199,4 +1219,22 @@ export default {
color: #333;
flex: 1;
}
.goods-specs {
margin-top: 10rpx;
display: flex;
flex-wrap: wrap;
gap: 8rpx;
}
.spec-tag {
background: #f0f8ff;
border: 1rpx solid #e6f3ff;
border-radius: 12rpx;
padding: 4rpx 12rpx;
display: inline-block;
margin-bottom: 6rpx;
font-size: 22rpx;
color: #4a90e2;
font-weight: 500;
}
</style>

28
subPackages/orderQy/list.vue

@ -61,12 +61,18 @@
</view>
<view class="goods-info">
<text class="goods-name">{{ goods.goodsTitle }}</text>
<text class="goods-name" v-if="goods.skuName">{{ goods.skuName }}</text>
<view class="goods-meta">
<text class="goods-type">{{
getGoodsTypeName(goods.type)
}}</text>
<text class="goods-quantity">数量{{ goods.num || 1 }}</text>
</view>
<view class="goods-specs" v-if="goods.orderExchangeVo && goods.orderExchangeVo.orderExchangeDetailVos">
<view class="spec-tag" v-for="(item, index) in goods.orderExchangeVo.orderExchangeDetailVos" :key="index">
{{item.specValueOne}} / {{item.specValueTwo}}
</view>
</view>
</view>
<view class="goods-action">
<!-- 未使用 -->
@ -770,6 +776,28 @@ $bg-light: #f7fafc;
margin-right: 16rpx;
}
//
.goods-specs {
margin-top: 10rpx;
display: flex;
flex-wrap: wrap;
gap: 8rpx;
}
.spec-tag {
background: #f0f8ff;
border: 1rpx solid #e6f3ff;
border-radius: 12rpx;
padding: 4rpx 12rpx;
display: inline-block;
margin-bottom: 6rpx;
font-size: 22rpx;
color: #4a90e2;
font-weight: 500;
}
.goods-quantity {
font-size: 22rpx;
color: $text-muted;

Loading…
Cancel
Save