Merge branch 'feature/jianweie_dev' into 'develop'

【优化】去除支付宝小程序,头条小程序分享功能。完善普通商品详情新风格

See merge request jianweie/coreshoppro!2
This commit is contained in:
大灰灰
2022-09-15 09:36:17 +00:00
11 changed files with 117 additions and 439 deletions

View File

@@ -7,10 +7,13 @@
<ItemGroup>
<Compile Remove="CoreShopProfessional-UniApp\.hbuilderx\**" />
<Compile Remove="CoreShopProfessional-UniApp\unpackage\**" />
<Compile Remove="CoreShop\**" />
<EmbeddedResource Remove="CoreShopProfessional-UniApp\.hbuilderx\**" />
<EmbeddedResource Remove="CoreShopProfessional-UniApp\unpackage\**" />
<EmbeddedResource Remove="CoreShop\**" />
<None Remove="CoreShopProfessional-UniApp\.hbuilderx\**" />
<None Remove="CoreShopProfessional-UniApp\unpackage\**" />
<None Remove="CoreShop\**" />
</ItemGroup>
</Project>

View File

@@ -12,7 +12,7 @@
&.left { left: 0; }
&.right { right: 0; }
&.top { top: 0; }
&.bottom { bottom: 0; }
&.bottom { bottom: 3px; }
.icon-jia { color: #ffffff; font-size: 25px; transition: all 0.3s; width: 22px; height: 22px;
&.active { transform: rotate(90deg); }
}

View File

@@ -1,130 +0,0 @@
<template>
<view class="coreshop-share-Box">
<u-toast ref="uToast" />
<view class="coreshop-share-pop">
<view class="coreshop-share-item">
<button class="coreshop-btn" open-type="share">
<u-icon label="分享给好友" labelPos="bottom" size="40" name="/static/images/common/share-friend.png"></u-icon>
</button>
</view>
<view class="coreshop-share-item">
<button class="coreshop-btn" @click="$u.throttle(createPoster, 500)">
<u-icon label="生成海报" labelPos="bottom" size="40" name="/static/images/common/share-poster.png"></u-icon>
</button>
</view>
</view>
<view class="coreshop-bottomBox">
<button class="coreshop-btn coreshop-btn-w coreshop-btn-square" @click="close()">关闭</button>
</view>
</view>
</template>
<script>
export default {
props: {
// 商品id
goodsId: {
type: Number,
default: 0
},
// 分享的图片
shareImg: {
type: String,
default: ''
},
// 分享标题
shareTitle: {
type: String,
default: ''
},
// 分享内容
shareContent: {
type: String,
default: ''
},
// 分享链接
shareHref: {
type: String,
default: ''
},
//分享类型
shareType: {
type: Number,
default: 1
},
//拼团id
groupId: {
type: Number,
default: 0
},
//拼团的团队id
teamId: {
type: Number,
default: 0
}
},
data() {
return {
providerList: [] // 分享通道 包含生成海报
}
},
mounted() {
},
methods: {
// 关闭弹出层
close() {
this.$emit('close')
},
// 生成海报
createPoster() {
let data = {};
if (this.shareType == 1) {
//商品
data = {
page: 2, //商品
url: '/pages/share/jump/jump',
params: {
goodsId: this.goodsId
},
type: 3,//海报
client: 6
}
let userToken = this.$db.get('userToken')
if (userToken) {
data.token = userToken
}
} else if (this.shareType == 3) {
//拼团
data = {
page: 3, //商品
url: '/pages/share/jump/jump',
params: {
goodsId: this.goodsId,
groupId: this.groupId,
teamId: this.teamId
},
type: 3,//海报
client: 6
}
let userToken = this.$db.get('userToken')
if (userToken) {
data.token = userToken
}
}
this.$u.api.share(data).then(res => {
if (res.status) {
this.close()
this.$u.route('/pages/share/sharePoster/sharePoster?poster=' + encodeURIComponent(res.data))
} else {
this.$u.toast(res.msg)
}
});
},
// 分享操作
async share(e) {
}
}
}
</script>

View File

@@ -1,124 +0,0 @@
<template>
<view class="coreshop-share-Box">
<u-toast ref="uToast" />
<view class="coreshop-share-pop">
<view class="coreshop-share-item">
<button class="coreshop-btn" @click="$u.throttle(createPoster, 500)">
<u-icon label="生成海报" labelPos="bottom" size="40" name="/static/images/common/share-poster.png"></u-icon>
</button>
</view>
</view>
<view class="coreshop-bottomBox">
<button class="coreshop-btn coreshop-btn-w coreshop-btn-square" @click="close()">关闭</button>
</view>
</view>
</template>
<script>
// #ifdef MP-TOUTIAO
import { ttPlatform } from '@/common/setting/constVarsHelper.js'
// #endif
export default {
props: {
// 商品id
goodsId: {
type: Number,
default: 0
},
// 分享的图片
shareImg: {
type: String,
default: ''
},
// 分享标题
shareTitle: {
type: String,
default: ''
},
// 分享内容
shareContent: {
type: String,
default: ''
},
// 分享链接
shareHref: {
type: String,
default: ''
},
//分享类型
shareType: {
type: Number,
default: 1
},
//拼团id
groupId: {
type: Number,
default: 0
},
//拼团的团队id
teamId: {
type: Number,
default: 0
}
},
data() {
return {
providerList: [] // 分享通道 包含生成海报
}
},
mounted() {
},
methods: {
// 关闭弹出层
close() {
this.$emit('close')
},
// 生成海报
createPoster() {
let data = {};
if (this.shareType == 1) {
//商品
data = {
page: 2, //商品
url: 'pages/share/jump/jump',
params: {
goodsId: this.goodsId
},
type: 3,//海报
client: 4
}
let userToken = this.$db.get('userToken')
if (userToken) {
data.token = userToken
}
} else if (this.shareType == 3) {
//拼团
data = {
page: 3, //商品
url: 'pages/share/jump/jump',
params: {
goodsId: this.goodsId,
groupId: this.groupId,
teamId: this.teamId
},
type: 3,//海报
client: 4
}
let userToken = this.$db.get('userToken')
if (userToken) {
data.token = userToken
}
}
this.$u.api.share(data).then(res => {
if (res.status) {
this.close()
this.$u.route('/pages/share/sharePoster/sharePoster?poster=' + encodeURIComponent(res.data))
} else {
this.$u.toast(res.msg)
}
});
}
}
}
</script>

View File

@@ -148,12 +148,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :shareType='$globalConstVars.shareType.group' :groupId="groupId" :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :shareType='$globalConstVars.shareType.group' :groupId="groupId" :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :shareType='$globalConstVars.shareType.group' :groupId="groupId" :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :shareType='$globalConstVars.shareType.group' :groupId="groupId" :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->

View File

@@ -299,12 +299,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :shareType='$globalConstVars.shareType.pinTuan' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :shareType='$globalConstVars.shareType.pinTuan' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :shareType='$globalConstVars.shareType.pinTuan' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :shareType='$globalConstVars.shareType.pinTuan' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->

View File

@@ -151,12 +151,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :shareType='$globalConstVars.shareType.seckill' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :shareType='$globalConstVars.shareType.seckill' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :shareType='$globalConstVars.shareType.seckill' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :shareType='$globalConstVars.shareType.seckill' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->

View File

@@ -114,12 +114,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :objectId="model.id" :shareType="12" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :objectId="model.id" :shareType="12" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :objectId="model.id" :shareType="12" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :objectId="model.id" :shareType="12" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->

View File

@@ -15,7 +15,7 @@
<!--幻灯片-->
<u-swiper height="calc(750rpx * 6 / 6)" radius="0" :list="goodsInfo.album" :autoplay="autoplay" indicator indicatorMode="line" circular @click="clickImg"></u-swiper>
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-18 coreshop-bg-white">
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white">
<view class="coreshop-flex coreshop-justify-between coreshop-align-center">
<view class="coreshop-text-red coreshop-font-weight-bold">
<text class="coreshop-font-16">¥</text>
@@ -23,31 +23,34 @@
</view>
<view class="coreshop-flex-sub coreshop-flex coreshop-text-left coreshop-margin-left-12 coreshop-margin-top-6 coreshop-justify-start coreshop-align-center">
<view class="coreshop-font-16 coreshop-text-gray coreshop-text-through">{{ priceSection }}</view>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-column coreshop-margin-left-12" v-if="pointSwitch==1 && pointExchangeModel==2 && pointShowExchangePrice==1 && product.pointsDeduction > 0">
<view class="coreshop-padding-bottom-5 coreshop-font-12">
兑换价{{pointDiscountedProportion * product.pointsDeduction }}{{ pointShowName}}+{{ product.price - product.pointsDeduction}}
</view>
<view class="coreshop-font-12" v-if="pointSwitch==1 && pointGetModel==2 && pointShowPoint==1 && product.points > 0">买就送{{product.points}}{{ pointShowName}}</view>
</view>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-column coreshop-margin-left-12" v-else>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-row">
<view class="coreshop-font-12" v-if="pointSwitch==1 && pointGetModel==2 && pointShowPoint==1 && product.points > 0">买就送{{product.points}}{{ pointShowName}}</view>
</view>
</view>
</view>
<view class="coreshop-flex coreshop-align-center">
<u-icon name="star-fill" :size="20" label="收藏" :labelSize="14" labelPos="right" @click="collection" v-if="isfav"></u-icon>
<u-icon name="star" :size="20" label="收藏" :labelSize="14" labelPos="right" @click="collection" v-else></u-icon>
</view>
</view>
<view>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-row coreshop-margin-top-12" v-if="pointSwitch==1 && pointExchangeModel==2 && pointShowExchangePrice==1 && product.pointsDeduction > 0">
<view class="coreshop-padding-bottom-5 coreshop-font-12">
兑换价{{pointDiscountedProportion * product.pointsDeduction }}{{ pointShowName}}+{{ product.price - product.pointsDeduction}}
</view>
<view class="coreshop-font-12 coreshop-margin-left-12" v-if="pointSwitch==1 && pointGetModel==2 && pointShowPoint==1 && product.points > 0">买就送{{product.points}}{{ pointShowName}}</view>
</view>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-column coreshop-margin-left-12" v-else>
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-row">
<view class="coreshop-font-12" v-if="pointSwitch==1 && pointGetModel==2 && pointShowPoint==1 && product.points > 0">买就送{{product.points}}{{ pointShowName}}</view>
</view>
</view>
</view>
<view class="coreshop-margin-top-12 coreshop-multiple-line-clamp">
<text class="coreshop-font-16 coreshop-font-weight-bold">{{ goodsInfo.name || '' }}</text>
</view>
<view class="coreshop-margin-top-8 coreshop-single-line-clamp">
<text class="coreshop-font-14 coreshop-text-gray">{{ goodsInfo.brief || '' }}</text>
</view>
<view class="coreshop-flex coreshop-margin-top-8" v-if="goodsInfo.brand || goodsInfo.labels">
<u-tag :text="goodsInfo.brand.name" v-if="goodsInfo.brand"></u-tag>
<view class="coreshop-flex coreshop-margin-top-8" v-if="goodsInfo.brand || goodsInfo.labels">
<u-tag :text="goodsInfo.brand.name" v-if="goodsInfo.brand"></u-tag>
<view class="coreshop-margin-left-6" v-for="item in goodsInfo.labels" :key="item.id">
<u-tag :text="item.name" :bgColor="item.style" :borderColor="item.style"></u-tag>
</view>
@@ -70,12 +73,12 @@
</view>
<!--促销-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-common-view-box" v-if="promotion.length > 0" @tap="promotionTap">
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white" v-if="promotion.length > 0" @tap="promotionTap">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row">
<view class="coreshop-basis-1">
<view class="coreshop-basis-2">
<text class="coreshop-text-gray">促销</text>
</view>
<view class="coreshop-basis-8">
<view class="coreshop-basis-7">
<view v-for="(item, index) in promotion" :key="index" :class="index> 1 ? 'coreshop-margin-top-10':''">
<text class="cu-tag line-orange sm radius">{{item.name}}</text>
</view>
@@ -89,100 +92,117 @@
</view>
<!--服务-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-common-view-box" @tap="serviceTap" v-if="serviceDescription.service.length>0">
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white" @tap="serviceTap" v-if="serviceDescription.service.length>0">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row">
<view class="coreshop-basis-1">
<text class="coreshop-text-gray">服务</text>
<view class="coreshop-basis-2">
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">服务</text>
</view>
<view class="coreshop-basis-8">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row">
<view class="coreshop-basis-7 coreshop-flex coreshop-align-center">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row coreshop-align-center">
<u-icon name="checkmark-circle" size="12" labelSize="12" color="#e54d42" :label="item.title" v-for="(item, index) in serviceDescription.service" :key="index" class="coreshop-margin-right-10"></u-icon>
</view>
</view>
<view class="coreshop-basis-1">
<view class="coreshop-float-right">
<u-icon name="arrow-right-double"></u-icon>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
</view>
</view>
<!--发货/规格-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-common-view-box" v-if="serviceDescription.delivery.length>0">
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white" v-if="serviceDescription.delivery.length>0">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row">
<view class="coreshop-basis-1">
<text class="coreshop-text-gray">发货</text>
<view class="coreshop-basis-2">
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">发货</text>
</view>
<view class="coreshop-coreshop-basis-9" v-for="(item, index) in serviceDescription.delivery" :key="index">
<text class="coreshop-font-sm">{{item.description}}</text>
<view class="coreshop-coreshop-basis-8 coreshop-flex coreshop-align-center">
<text class="coreshop-font-sm" v-for="(item, index) in serviceDescription.delivery" :key="index">{{item.description}}</text>
</view>
</view>
<view class="coreshop-solid-bottom coreshop-margin-top-10 coreshop-margin-bottom-10" v-if="serviceDescription.delivery.length>0" />
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-padding-top-10" @tap="openSkuPopup">
<view class="coreshop-basis-1">
<text class="coreshop-text-gray">规格</text>
<view class="coreshop-basis-2">
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">规格</text>
</view>
<view class="coreshop-basis-8">
<view class="coreshop-basis-7 coreshop-flex coreshop-align-center">
<text class="coreshop-font-sm">{{ product.spesDesc || ''}}</text>
</view>
<view class="coreshop-basis-1">
<view class="coreshop-float-right">
<u-icon name="arrow-right-double"></u-icon>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
</view>
</view>
<!--评论-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-padding-left-10 coreshop-padding-right-10 coreshop-padding-bottom-10" v-if="goodsComments.length">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-padding-top-10 coreshop-flex-direction-row">
<view class="coreshop-basis-2">
<text class="coreshop-text-black coreshop-font-md">评价{{goodsComments.length}}</text>
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white">
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-flex-direction-row">
<view class="coreshop-basis-3">
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">评价{{goodsComments.length}}</text>
</view>
<view class="coreshop-basis-7"></view>
<view class="coreshop-basis-1">
<view class="coreshop-basis-3"></view>
<view class="coreshop-basis-4">
<view class="coreshop-float-right">
<u-icon name="arrow-right" @tap="goGoodComments(goodsInfo.id)"></u-icon>
<u-icon name="arrow-right" label="查看更多" labelPos="left" labelSize="12px" labelColor="color['u-content-color']" @tap="goGoodComments(goodsInfo.id)"></u-icon>
</view>
</view>
</view>
<view v-for="(item, index) in goodsComments" :key="index">
<view class="coreshop-solid-bottom coreshop-margin-top-10 coreshop-margin-bottom-10" />
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-padding-10 coreshop-flex-direction-row">
<view class="coreshop-basis-1">
<view class="coreshop-avatar sm round" :style="[{backgroundImage:'url('+ item.avatarImage +')'}]" />
<view v-if="goodsComments.length">
<view v-for="(item, index) in goodsComments" :key="index">
<view class="coreshop-solid-bottom coreshop-margin-top-10 coreshop-margin-bottom-10" />
<view class="coreshop-flex coreshop-flex-wrap coreshop-font-sm coreshop-padding-10 coreshop-flex-direction-row">
<view class="coreshop-basis-1">
<view class="coreshop-avatar sm round" :style="[{backgroundImage:'url('+ item.avatarImage +')'}]" />
</view>
<view class="coreshop-basis-9 coreshop-font-sm">
<view>{{ (item.nickName && item.nickName != '')?item.nickName:item.mobile }}</view>
<view class="coreshop-margin-top-10">{{ item.contentBody || ''}}</view>
<view class="coreshop-text-gray coreshop-margin-top-5">
<u-rate v-model="item.score" :count="5" size="15"></u-rate>
</view>
<view class="coreshop-margin-top-10" v-if="item.imagesArr">
<u-album :urls="item.imagesArr" rowCount="4"></u-album>
</view>
<view class="coreshop-text-gray coreshop-margin-top-5 coreshop-font-12">{{ item.createTime || ''}} {{ item.addon || ''}}</view>
</view>
</view>
<view class="coreshop-basis-9 coreshop-font-sm">
<view>{{ (item.nickName && item.nickName != '')?item.nickName:item.mobile }}</view>
<view class="coreshop-margin-top-10">{{ item.contentBody || ''}}</view>
<view class="coreshop-text-gray coreshop-margin-top-5">
<u-rate v-model="item.score" :count="5" size="15"></u-rate>
</view>
<view class="coreshop-margin-top-10" v-if="item.imagesArr">
<u-album :urls="item.imagesArr" rowCount="4"></u-album>
</view>
<view class="coreshop-text-gray coreshop-margin-top-5 coreshop-font-12">{{ item.createTime || ''}} {{ item.addon || ''}}</view>
</view>
</view>
<view class="coreshop-margin-top-16" v-else>
<text class="coreshop-text-gray coreshop-font-12">该商品暂无评价</text>
</view>
</view>
<!--参数-->
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white" v-if="goodsParams.length>0">
<view>
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">参数</text>
</view>
<view class="goods-param-box">
<view class="goods-param-line" v-for="(item, index) in goodsParams" :key="index">
<view class="name">
<text>{{item.name}}</text>
</view>
<view class="value">
<text>{{item.value}}</text>
</view>
</view>
</view>
</view>
<!--内容区-->
<view class="coreshop-margin-top-16 coreshop-margin-bottom-12 coreshop-flex coreshop-justify-center coreshop-align-center">
<view class="line-70"></view>
<view class="coreshop-margin-left-12 coreshop-margin-right-12 coreshop-text-gray">详情介绍</view>
<view class="line-70"></view>
</view>
<view class="coreshop-margin-top-10 coreshop-bg-white">
<view class="coreshop-font-md coreshop-padding-top-10 coreshop-padding-bottom-10 coreshop-padding-left-10 coreshop-padding-right-10 coreshop-flex-direction-row">
<u-icon name="more-circle" color="#e54d42" label="商品详情" labelSize="15px" label-pos="right"></u-icon>
</view>
<!--参数-->
<view class="coreshop-padding-bottom-10 coreshop-padding-left-10 coreshop-padding-right-10 coreshop-flex-direction-row" v-for="(item, index) in goodsParams" :key="index">
<text class="coreshop-text-gray">{{ item.name || ''}}</text>
<text class="coreshop-text-black">{{ item.value || ''}}</text>
</view>
<view class="coreshop-padding-10">
<u-parse :content="goodsInfo.intro" :selectable="true" v-if="goodsInfo.intro"></u-parse>
<!-- 无数据时默认显示 -->
<view class="coreshop-emptybox" v-else>
<u-empty :icon="$globalConstVars.apiFilesUrl+'/static/images/empty/data.png'" icon-size="150" text="详情为空" mode="list"></u-empty>
</view>
<u-parse :content="goodsInfo.intro" :selectable="true" v-if="goodsInfo.intro"></u-parse>
<!-- 无数据时默认显示 -->
<view class="coreshop-emptybox coreshop-padding-10" v-else>
<u-empty :icon="$globalConstVars.apiFilesUrl+'/static/images/empty/data.png'" icon-size="150" text="详情为空" mode="list"></u-empty>
</view>
</view>
@@ -195,12 +215,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :shareType='$globalConstVars.shareType.goods' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :shareType='$globalConstVars.shareType.goods' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :shareType='$globalConstVars.shareType.goods' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :shareType='$globalConstVars.shareType.goods' :goodsId="goodsInfo.id" :shareImg="goodsInfo.image" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.brief" :shareHref="shareHref" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->
@@ -209,13 +223,12 @@
</view>
<!--常见问题-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-margin-bottom-30 coreshop-common-view-box">
<view class="coreshop-font-md coreshop-padding-bottom-20 coreshop-flex-direction-row">
<u-icon name="question-circle" color="#e54d42" label="常见说明" labelSize="15px" label-pos="right"></u-icon>
<view class="coreshop-margin-left-16 coreshop-margin-right-16 coreshop-margin-top-12 coreshop-padding-16 coreshop-border-radius-9 coreshop-bg-white">
<view class="coreshop-margin-bottom-16">
<text class="coreshop-text-black coreshop-font-weight-bold coreshop-font-15">常见问题</text>
</view>
<view class="coreshop-flex coreshop-flex-wrap coreshop-margin-bottom-10 coreshop-flex-direction-row" v-for="(item, index) in serviceDescription.commonQuestion" :key="index">
<view class="coreshop-basis-2">
<view class="coreshop-basis-2 coreshop-font-13">
{{item.title}}
</view>
<view class="coreshop-basis-8">
@@ -223,70 +236,19 @@
</view>
</view>
<view class="coreshop-solid-bottom coreshop-margin-top-10 coreshop-margin-bottom-10" />
<view class="coreshop-text-center coreshop-text-blue coreshop-padding-top-10" @tap="goArticleList()">查看更多问题</view>
</view>
<!--商家及推荐-->
<view class="coreshop-margin-top-10 coreshop-bg-white coreshop-common-view-box coreshop-goods-shop-info-view-box">
<view class="coreshop-shop-view">
<view class="coreshop-position-absolute">
<u-avatar :src="shopLogo"></u-avatar>
</view>
<view class="coreshop-margin-left-10 coreshop-padding-left-40 coreshop-padding-right-40">
<view class="coreshop-margin-bottom-5">{{shopName}}</view>
<view class="coreshop-font-sm u-line-1">{{shareTitle}}</view>
</view>
<u-button type="error" size="mini" :plain="true" @click="doPhoneCall">联系商家</u-button>
</view>
<view class="coreshop-solid-bottom coreshop-padding-top-5 coreshop-padding-bottom-5" />
<view class="live-tag-view coreshop-margin-top-10 coreshop-margin-bottom-10">
<view class="text-view">
<view class="location-tag"><u-tag text="已定位" mode="plain" size="mini" type="warning" /></view>
<text class="coreshop-margin-left-10 u-line-1">可直接获取商家地理位置信息</text>
</view>
<view class="coreshop-font-sm coreshop-text-red go-map-box" @tap="goShopMap">
<text class="coreshop-margin-right-10">去地图</text>
<u-icon name="arrow-right"></u-icon>
</view>
</view>
<view class="coreshop-solid-bottom coreshop-margin-top-10 coreshop-margin-bottom-10" />
<view class="coreshop-good-shop-recommend-list-box">
<view class="coreshop-font-sm coreshop-padding-top-10 ">本店推荐</view>
<!--滑动列表-->
<view class="recommend-scroll-box">
<scroll-view class="recommend-scroll" scroll-x>
<block v-for="(items,indexs) in shopRecommendData" :key="indexs">
<view :id="['scroll' + (indexs + 1 )]" class="recommend-scroll-item" @tap="goGoodsDetail(items.id)">
<u--image :src="items.image" mode="widthFix" width="91px" height="91px" radius="10"></u--image>
<view class="u-line-2 coreshop-font-sm coreshop-text-black coreshop-margin-top-10 coreshop-margin-bottom-10 coreshop-min-height-34">{{items.name}}</view>
<view class="coreshop-text-red coreshop-text-price coreshop-margin-top-10 coreshop-margin-bottom-10 coreshop-font-md coreshop-flex-direction-row">
{{items.price}}
</view>
</view>
</block>
</scroll-view>
</view>
</view>
<view class="coreshop-text-center coreshop-text-blue coreshop-padding-top-10 coreshop-font-13" @tap="goArticleList()">查看更多问题</view>
</view>
<!--为您推荐-->
<view class="coreshop-recommended-title-view">
<view class="coreshop-flex coreshop-flex-wrap coreshop-flex-direction-row">
<view class="coreshop-flex-4 coreshop-text-right">
<image class="img-anc" src="/static/images/common/anc.png" mode="widthFix" />
</view>
<view class="coreshop-flex-4 coreshop-text-center">
<text class="coreshop-text-black coreshop-font-lg">为您推荐</text>
</view>
<view class="coreshop-flex-4 coreshop-text-left">
<image class="img-anc" src="/static/images/common/anc.png" mode="widthFix" />
</view>
</view>
<view class="coreshop-margin-top-16 coreshop-margin-bottom-12 coreshop-flex coreshop-justify-center coreshop-align-center">
<view class="line-70"></view>
<view class="coreshop-margin-left-12 coreshop-margin-right-12 coreshop-text-gray">为您推荐</view>
<view class="line-70"></view>
</view>
<!--推荐列表-->
<view class="coreshop-goods-group" v-if="otherRecommendData.length>0">
<view class="coreshop-goods-group" v-if="shopRecommendData.length>0">
<u-grid col="2" :border="false" align="left">
<u-grid-item bg-color="transparent" :custom-style="{padding: '0px'}" v-for="(item, index) in otherRecommendData" :key="index" @click="goGoodsDetail(item.id)">
<u-grid-item bg-color="transparent" :custom-style="{padding: '0px'}" v-for="(item, index) in shopRecommendData" :key="index" @click="goGoodsDetail(item.id)">
<view class="good_box">
<u--image :src="item.image" mode="widthFix" width="100%" height="174px" radius="10"></u--image>
<view class="good_title u-line-2 coreshop-min-height-34">
@@ -305,13 +267,14 @@
</u-grid-item>
</u-grid>
</view>
<!--占位底部距离-->
<view class="coreshop-tabbar-height" />
<!--底部操作-->
<view class="coreshop-good-footer-fixed">
<view class="tabbar">
<view class="coreshop-flex coreshop-align-center coreshop-flex-direction-row coreshop-justify-between coreshop-basis-4">
<view class="coreshop-flex coreshop-align-center coreshop-flex-direction-row coreshop-justify-start coreshop-basis-4">
<!-- 客服按钮 -->
<!-- #ifdef H5 || APP-PLUS-NVUE || APP-PLUS -->
<view class="action" @click="showChat()">
@@ -330,22 +293,21 @@
<view class="action" @click="redirectCart">
<button class="noButtonStyle">
<u-badge type="warning" :value="cartNums" showZero="false" absolute="true" :offset="[1, 4]"></u-badge>
<u-icon name="shopping-cart" :size="20" label="购物车" :labelSize="12" labelPos="bottom"></u-icon>
<u-icon name="shopping-cart" :size="24" label="购物车" :labelSize="12" labelPos="bottom"></u-icon>
</button>
</view>
</view>
<view class="btn-group coreshop-flex coreshop-align-center coreshop-flex-direction-row coreshop-justify-between coreshop-basis-5">
<u-button type="primary" size="normal" shape="circle" @click="openSkuPopup">
<u-button type="warning" size="normal" :plain="true" shape="circle" @click="openSkuPopup">
<text class="coreshop-font-12">加购物车</text>
</u-button>
<u-button type="success" size="normal" shape="circle" @click="openSkuPopup">
<u-button type="error" size="normal" shape="circle" @click="openSkuPopup">
<text class="coreshop-font-12">立即购买</text>
</u-button>
</view>
</view>
</view>
<!--弹出框-->
<u-popup class="coreshop-bottom-popup-box" :show="bottomModal" mode="bottom" @close="hideModal" :closeable="true" safeAreaInsetTop>
<view class="radius coreshop-bg-white">
@@ -417,7 +379,6 @@
product: {}, // 货品详情
priceSection: '',
shopRecommendData: [], // 本店推荐数据
otherRecommendData: [], // 其他数据
goodsParams: [], // 商品参数信息
goodsComments: [], // 商品评论信息
type: 2, // 1加入购物车 2购买
@@ -768,17 +729,6 @@
_this.$u.toast(res.msg)
}
});
let data = {
id: 10
}
_this.$u.api.getGoodsRecommendList(data).then(res => {
if (res.status) {
_this.otherRecommendData = _this.$u.randomArray(res.data);
} else {
_this.$u.toast(res.msg)
}
});
},
// 获取购物车数量
getCartNums() {

View File

@@ -46,12 +46,6 @@
<!-- #ifdef MP-WEIXIN -->
<coreshop-share-wx :shareType='$globalConstVars.shareType.addPinTuan' :goodsId="goodsInfo.goodsId" :teamId="teamInfo.teamId" :groupId="teamInfo.ruleId" :shareImg="goodsInfo.imageUrl" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.addon" :shareHref="shareHref" @close="closeShare()"></coreshop-share-wx>
<!-- #endif -->
<!-- #ifdef MP-ALIPAY -->
<coreshop-share-alipay :shareType='$globalConstVars.shareType.addPinTuan' :goodsId="goodsInfo.goodsId" :teamId="teamInfo.teamId" :groupId="teamInfo.ruleId" :shareImg="goodsInfo.imageUrl" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.addon" :shareHref="shareHref" @close="closeShare()"></coreshop-share-alipay>
<!-- #endif -->
<!-- #ifdef MP-TOUTIAO -->
<coreshop-share-tt :shareType='$globalConstVars.shareType.addPinTuan' :goodsId="goodsInfo.goodsId" :teamId="teamInfo.teamId" :groupId="teamInfo.ruleId" :shareImg="goodsInfo.imageUrl" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.addon" :shareHref="shareHref" @close="closeShare()"></coreshop-share-tt>
<!-- #endif -->
<!-- #ifdef APP-PLUS || APP-PLUS-NVUE -->
<coreshop-share-app :shareType='$globalConstVars.shareType.addPinTuan' :goodsId="goodsInfo.goodsId" :teamId="teamInfo.teamId" :groupId="teamInfo.ruleId" :shareImg="goodsInfo.imageUrl" :shareTitle="goodsInfo.name" :shareContent="goodsInfo.addon" :shareHref="shareHref" @close="closeShare()"></coreshop-share-app>
<!-- #endif -->

View File

@@ -677,3 +677,12 @@ u-icon { line-height: 0; }
.contact-btn { margin: 0 auto; }
/*商品参数*/
.goods-param-box { border: 0.5px solid #c3c3c3; border-radius: 6px; margin-top: 12rpx; }
.goods-param-line { border-bottom: 0.5px solid #c3c3c3; display: flex; height: 34px; line-height: 34px; }
.goods-param-line:last-child { border-bottom: 0; }
.goods-param-line .name { background: #f3f3f3; border-right: 0.5px solid #c3c3c3; color: #616161; font-size: 12px; height: 34px; line-height: 34px; text-align: center; width: 95px; }
.goods-param-line .value { color: #2f2f2f; font-size: 12px; padding-left: 12px; width: 215px; }
.line-70 { background: #c3c3c3; height: 1px; margin-top: 3px; width: 34.5px; }