mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2025-12-06 17:53:25 +08:00
修复【uniapp】:商品详情页面,如果未登录状态下,也可以进行分享
This commit is contained in:
@@ -26,7 +26,8 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 积分兑换价格 -->
|
<!-- 积分兑换价格 -->
|
||||||
<Point v-if="!props.isActivityGoods" :flex="true" :data="props.goodsDetailData?.product" fontSize="24rpx"></Point>
|
<Point v-if="!props.isActivityGoods" :flex="true" :data="props.goodsDetailData?.product" fontSize="24rpx">
|
||||||
|
</Point>
|
||||||
|
|
||||||
<view class="name-box" v-if="props.goodsDetailData?.name || props.goodsDetailData?.brief">
|
<view class="name-box" v-if="props.goodsDetailData?.name || props.goodsDetailData?.brief">
|
||||||
<view class="name">{{ props.goodsDetailData?.name }}</view>
|
<view class="name">{{ props.goodsDetailData?.name }}</view>
|
||||||
@@ -80,7 +81,7 @@
|
|||||||
import { ShareEnum } from '@/core/enum';
|
import { ShareEnum } from '@/core/enum';
|
||||||
import Point from '@/pages/components/custom-page/components/home-goods/point.vue';
|
import Point from '@/pages/components/custom-page/components/home-goods/point.vue';
|
||||||
import { handleShowToast } from '@/core/utils';
|
import { handleShowToast } from '@/core/utils';
|
||||||
import CoreshopShare from '@/components/coreshop-share/coreshop-share.vue';
|
import CoreshopShare from '@/components/coreshop-share/coreshop-share.vue';
|
||||||
import { useLoginStore } from '@/core/store';
|
import { useLoginStore } from '@/core/store';
|
||||||
|
|
||||||
/** 登录store */
|
/** 登录store */
|
||||||
@@ -102,7 +103,7 @@
|
|||||||
}>({
|
}>({
|
||||||
isFav: false,
|
isFav: false,
|
||||||
showShare: false,
|
showShare: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
watch(() => props.goodsDetailData, (newVla : any) => {
|
watch(() => props.goodsDetailData, (newVla : any) => {
|
||||||
if (newVla) {
|
if (newVla) {
|
||||||
@@ -124,9 +125,7 @@
|
|||||||
|
|
||||||
/** 分享弹框显示与否 */
|
/** 分享弹框显示与否 */
|
||||||
const handleToggleShowShare = () => {
|
const handleToggleShowShare = () => {
|
||||||
_useLoginStore.checkLogin(() => {
|
state.showShare = !state.showShare;
|
||||||
state.showShare = !state.showShare;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user