Преглед изворни кода

修改显示轮播图和3D文物

shaogen1995 пре 4 година
родитељ
комит
704c206531
1 измењених фајлова са 2 додато и 4 уклоњено
  1. 2 4
      src/pages/showPages/cultural-relic/index.vue

+ 2 - 4
src/pages/showPages/cultural-relic/index.vue

@@ -12,7 +12,7 @@
           <p>{{ detail.name }}</p>
                       <!-- v-if="detail.type === '3D'" -->
           <iframe
-            v-if="0"
+            v-if="detail.type === '3D'"
             :src="detail.modelUrl"
             frameborder="0"
           ></iframe>
@@ -127,9 +127,7 @@ export default {
 
       this.detail = result.data
       this.detail.modelUrl += `&hideAction=true`
-      this.imgs = this.detail.typeImages
-        ? JSON.parse(this.detail.typeImages)
-        : []
+      if (this.detail.urlList) this.imgs = this.detail.urlList.split(',')
       this.type = this.getType()
     },