Authored by shuaiguo

feat(product/detail): 展示配置视频 reviewed by 邱骏

@@ -29,14 +29,18 @@ export default { @@ -29,14 +29,18 @@ export default {
29 }); 29 });
30 }); 30 });
31 31
32 - let [detail, resource, activity, recommend, vedioResource, limitInfo] = await Promise.all(queryTasks);  
33 -  
34 - if(vedioResource) { 32 + let [detail, resource, activity, recommend, videoResource, limitInfo] = await Promise.all(queryTasks);
35 33
  34 + if(videoResource) {
  35 + videoResource = {
  36 + src: videoResource.vedioImageUrl,
  37 + url: videoResource.vedioUrl
36 } 38 }
  39 + } else {
37 // 视频资源位 40 // 视频资源位
38 const videoResourceInfo = resource.find(r=> /(\.mp4)/.test(r.data[0].url)); 41 const videoResourceInfo = resource.find(r=> /(\.mp4)/.test(r.data[0].url));
39 - const videoResource = get(videoResourceInfo, 'data[0]', {}); 42 + videoResource = get(videoResourceInfo, 'data[0]', {});
  43 + }
40 44
41 resource = get(resource, '[0].data[0]', {}); 45 resource = get(resource, '[0].data[0]', {});
42 46