| | |
| | | <Evaluation id="main5" :goodsDetail="goodsDetail" /> |
| | | |
| | | <!-- 店铺推荐 --> |
| | | <storeLayout id="main7" :storeDetail="storeDetail" :goodsDetail="goodsDetail" :res="recommendList" /> |
| | | <!-- <storeLayout id="main7" :storeDetail="storeDetail" :goodsDetail="goodsDetail" :res="recommendList" /> --> |
| | | |
| | | <!-- 宝贝详情 --> |
| | | <GoodsIntro id="main9" :res="goodsDetail" :goodsParams="goodsParams" :goodsId="goodsDetail.goodsId" |
| | | v-if="goodsDetail.id" /> |
| | | |
| | | <!-- 宝贝推荐 --> |
| | | <GoodsRecommend id="main11" :res="likeGoodsList" /> |
| | | <!-- <GoodsRecommend id="main11" :res="likeGoodsList" /> --> |
| | | </view> |
| | | </scroll-view> |
| | | |
| | | |
| | | <view class="page-bottom mp-iphonex-bottom" id="pageBottom"> |
| | | <view class="icon-btn"> |
| | | <view class="icon-btn-item" @click="navigateToStore(goodsDetail.storeId)"> |
| | | <!-- <view class="icon-btn-item" @click="navigateToStore(goodsDetail.storeId)"> |
| | | <u-icon size="34" class="red" name="home-fill"></u-icon> |
| | | <view class="red icon-btn-name">店铺</view> |
| | | </view> |
| | | </view> --> |
| | | <view class="icon-btn-item" @click="linkMsgDetail()"> |
| | | <u-icon size="34" name="kefu-ermai"></u-icon> |
| | | <view class="icon-btn-name">客服</view> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import UIcon from '@/uview-components/uview-ui/components/u-icon/u-icon.vue'; |
| | | import UNavbar from '@/uview-components/uview-ui/components/u-navbar/u-navbar.vue'; |
| | | import UPopup from '@/uview-components/uview-ui/components/u-popup/u-popup.vue'; |
| | | import '@/components/uview-components/uview-ui'; |
| | | |
| | | |
| | | /************接口API***************/ |
| | |
| | | import PromotionAssembleListLayout from "./product/promotion/-promotion-assemble-list"; //拼团用户列表 |
| | | import PromotionCoupon from "./product/promotion/-promotion-coupon"; //优惠券组件 |
| | | import GoodsIntro from "./product/goods/-goods-intro"; //商品介绍组件 |
| | | import GoodsRecommend from "./product/goods/-goods-recommend"; //宝贝推荐 |
| | | // import GoodsRecommend from "./product/goods/-goods-recommend"; //宝贝推荐 |
| | | import storeLayout from "./product/shop/-shop"; //店铺组件 |
| | | import Evaluation from "./product/evaluation/-evaluation"; //评价组件 |
| | | import GoodsSwiper from "./product/goods/-goods-swiper"; //轮播图组件 |
| | | import popupGoods from "@/components/m-buy/goods"; //购物车商品的模块 |
| | | import popupGoods from "@/pages/product/m-buy/goods.vue"; //购物车商品的模块 |
| | | import popupAddress from "./product/popup/address"; //地址选择模块 |
| | | import shares from "@/components/m-share/index"; //分享 |
| | | import popups from "@/components/popups/popups"; //气泡框 |
| | | import takeDownFormSaleGoods from "@/components/m-take-down-sale-goods/index"; //下架框 |
| | | import shares from "@/pages/product/m-share/index.vue"; //分享 |
| | | import popups from "@/pages/subComponents/popups/popups.vue"; //气泡框 |
| | | import takeDownFormSaleGoods from "@/pages/product/m-take-down-sale-goods/index"; //下架框 |
| | | import setup from "./product/popup/popup"; |
| | | |
| | | import { |
| | | getSTSToken |
| | | } from '@/api/common.js' |
| | | export default { |
| | | components: { |
| | | popups, |
| | |
| | | PromotionAssembleListLayout, |
| | | PromotionCoupon, |
| | | GoodsIntro, |
| | | GoodsRecommend, |
| | | storeLayout, |
| | | Evaluation, |
| | | GoodsSwiper, |
| | | popupGoods, |
| | | popupAddress, |
| | | takeDownFormSaleGoods, |
| | | UIcon, |
| | | UNavbar, |
| | | UPopup, |
| | | takeDownFormSaleGoods |
| | | }, |
| | | data () { |
| | | return { |
| | |
| | | // #endif |
| | | navbarListData: [ |
| | | //导航栏列表栏数据 |
| | | { |
| | | title: "首页", |
| | | icon: "home-fill", |
| | | ___type: "other", |
| | | }, |
| | | // { |
| | | // title: "首页", |
| | | // icon: "home-fill", |
| | | // ___type: "other", |
| | | // }, |
| | | { |
| | | title: "购物车", |
| | | icon: "bag-fill", |
| | | ___type: "other", |
| | | }, |
| | | { |
| | | title: "搜索", |
| | | icon: "search", |
| | | ___type: "category", |
| | | }, |
| | | // { |
| | | // title: "搜索", |
| | | // icon: "search", |
| | | // ___type: "category", |
| | | // }, |
| | | { |
| | | title: "个人中心", |
| | | icon: "account-fill", |
| | |
| | | this.$store.state.distributionId = distributionId; |
| | | } |
| | | } |
| | | const sts = await getSTSToken(); |
| | | const stsUrl = sts.data.data.endpoint |
| | | // // 处理数据 |
| | | // goodsList.data.result.records.forEach(item => { |
| | | // if (item.thumbnail !== '' && item.thumbnail !== null && item.thumbnail.indexOf('http') === |
| | | // -1) { |
| | | // item.thumbnail = stsUrl + '/' + item.thumbnail |
| | | // } |
| | | // if (item.goodsVideo !== '' && item.goodsVideo !== null && item.goodsVideo.indexOf( |
| | | // 'http') === -1) { |
| | | // item.goodsVideo = stsUrl + '/' + item.goodsVideo |
| | | // } |
| | | // }) |
| | | /**商品信息以及规格信息存储 */ |
| | | console.log('--------------------------1>',response.data.result.data.goodsGalleryList) |
| | | response.data.result.data.goodsGalleryList.forEach((item,index)=>{ |
| | | if (item !== '' && item !== null && item.indexOf('http') === |
| | | -1) { |
| | | response.data.result.data.goodsGalleryList[index] = stsUrl + '/' + item |
| | | console.log('是否执行-------------》',item) |
| | | } |
| | | }) |
| | | console.log('--------------------------2>',response.data.result.data.goodsGalleryList) |
| | | this.goodsDetail = response.data.result.data; |
| | | if (this.goodsDetail.goodsVideo !== '' && this.goodsDetail.goodsVideo !== null && this.goodsDetail.goodsVideo.indexOf( |
| | | 'http') === -1) { |
| | | this.goodsDetail.goodsVideo = stsUrl + '/' + this.goodsDetail.goodsVideo |
| | | } |
| | | console.log('--------------------------2>',this.goodsDetail.goodsGalleryList) |
| | | this.wholesaleList = response.data.result.wholesaleList; |
| | | this.goodsSpec = response.data.result.specs; |
| | | this.PromotionList = response.data.result.promotionMap; |