Browse Source

banner图跳转优化

yuwenjun1997 2 năm trước cách đây
mục cha
commit
8864c458d7

+ 3 - 0
mixins/global.js

@@ -8,6 +8,9 @@ export default {
     methods: {
         jumpAction(data) {
             const { jumpType, jumpLink, jumpProductId, jumpImage } = data
+            if (jumpType === 1 && !jumpLink) return
+            if (jumpType === 2 && !jumpProductId) return
+            if (jumpType === 3 && !jumpImage) return
             // jumpType 跳转类型:1链接,2商品,3图片
             const jumpMap = {
                 1: `others/web-view?websit=${encodeURIComponent(jumpLink)}`,

+ 1 - 0
pages/views/goods/components/goods-info/goods-info.vue

@@ -104,6 +104,7 @@ export default {
         .tag {
             padding: 0 8rpx;
             margin-right: 20rpx;
+            margin-top: 20rpx;
             height: 34rpx;
             background: #fff3f7;
             border-radius: 6rpx;