|
|
<template>
|
|
|
<top-nav v-if="isApp" :title="entity.productName"></top-nav>
|
|
|
<top-nav v-if="isApp" :title="entity.productName" :img="firstImage | resize 300 300"></top-nav>
|
|
|
<show-box :is-first="true">
|
|
|
<image-carousel :goods="entity.goodsList"></image-carousel>
|
|
|
<div class="title-box">
|
...
|
...
|
@@ -401,6 +401,7 @@ |
|
|
yoho: yoho,
|
|
|
isApp: yoho.isApp,
|
|
|
intro: {},
|
|
|
firstImage: '',
|
|
|
entity: {
|
|
|
brand: {
|
|
|
brandName: '',
|
...
|
...
|
@@ -508,6 +509,13 @@ |
|
|
$.get(`/product/product_${pid}.json`).then((result) => {
|
|
|
// TODO: 异常处理
|
|
|
this.entity = result;
|
|
|
|
|
|
this.entity.goodsList.forEach((goods)=> {
|
|
|
if (!this.firstImage && goods.colorImage) {
|
|
|
this.firstImage = goods.colorImage;
|
|
|
}
|
|
|
});
|
|
|
|
|
|
return result;
|
|
|
}).then((result)=> {
|
|
|
loadIntroDeferred = () => {
|
...
|
...
|
|