|
@@ -324,6 +324,10 @@ export default {
|
|
// }
|
|
// }
|
|
// });
|
|
// });
|
|
// }
|
|
// }
|
|
|
|
+ if (this.baseInfo && this.baseInfo.workHotList && this.baseInfo.workHotList.length > 0) {
|
|
|
|
+ this.lockHotspotResourceTree(this.baseInfo.workHotList);
|
|
|
|
+ }
|
|
|
|
+
|
|
//开场校验
|
|
//开场校验
|
|
if (this.baseInfo?.workCoverType?.isShowCover === 1) {
|
|
if (this.baseInfo?.workCoverType?.isShowCover === 1) {
|
|
if (this.baseInfo.workCoverType.coverSelect === "videoAndImg") {
|
|
if (this.baseInfo.workCoverType.coverSelect === "videoAndImg") {
|
|
@@ -360,29 +364,40 @@ export default {
|
|
/**
|
|
/**
|
|
* 给热点的资源引用上锁
|
|
* 给热点的资源引用上锁
|
|
*/
|
|
*/
|
|
- lockHotspotResourceTree(sceneIndex, hotspots) {
|
|
|
|
|
|
+ // lockHotspotResourceTree(sceneIndex, hotspots) {
|
|
|
|
+ lockHotspotResourceTree(hotspots) {
|
|
hotspots.forEach((item, index) => {
|
|
hotspots.forEach((item, index) => {
|
|
- const target = this.info.scenes[sceneIndex].someData.hotspots[index];
|
|
|
|
|
|
+ // const target = this.info.scenes[sceneIndex].someData.hotspots[index];
|
|
let fodderId = [];
|
|
let fodderId = [];
|
|
-
|
|
|
|
switch (item.hotspotType) {
|
|
switch (item.hotspotType) {
|
|
case "image":
|
|
case "image":
|
|
- fodderId = target.image.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
- target.fodderId = fodderId;
|
|
|
|
|
|
+ // fodderId = target.image.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
+ // target.fodderId = fodderId;
|
|
|
|
+ fodderId = item.image.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
+ item.fodderId = fodderId;
|
|
break;
|
|
break;
|
|
case "audio":
|
|
case "audio":
|
|
- target.fodderId = [target.audio.id].map((i) => i);
|
|
|
|
|
|
+ // target.fodderId = [target.audio.id].map((i) => i);
|
|
|
|
+ item.fodderId = [item.audio.id].map((i) => i);
|
|
break;
|
|
break;
|
|
case "imageText":
|
|
case "imageText":
|
|
- fodderId = target.imageTextInfo.imageList.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
- target.imageTextInfo.audio.id && fodderId.push(target.imageTextInfo.audio.id);
|
|
|
|
- target.fodderId = fodderId;
|
|
|
|
|
|
+ // fodderId = target.imageTextInfo.imageList.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
+ // target.imageTextInfo.audio.id && fodderId.push(target.imageTextInfo.audio.id);
|
|
|
|
+ // target.fodderId = fodderId;
|
|
|
|
+ fodderId = item.imageTextInfo.imageList.reduce((p, c) => p.concat(c["id"]), []).map((i) => i);
|
|
|
|
+ item.imageTextInfo.audio.id && fodderId.push(item.imageTextInfo.audio.id);
|
|
|
|
+ item.fodderId = fodderId;
|
|
break;
|
|
break;
|
|
case "video":
|
|
case "video":
|
|
- target.fodderId = [target.video.id];
|
|
|
|
|
|
+ // target.fodderId = [target.video.id];
|
|
|
|
+ item.fodderId = [item.video.id];
|
|
|
|
+ break;
|
|
|
|
+ case "scene":
|
|
|
|
+ item.fodderId = [item.scene.fodderId].map((i) => i);
|
|
break;
|
|
break;
|
|
default:
|
|
default:
|
|
- target.fodderId = [];
|
|
|
|
|
|
+ // target.fodderId = [];
|
|
|
|
+ item.fodderId = [];
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
});
|
|
});
|