tangning hai 7 meses
pai
achega
aff4033b1a
Modificáronse 1 ficheiros con 5 adicións e 3 borrados
  1. 5 3
      src/view/layout/index.vue

+ 5 - 3
src/view/layout/index.vue

@@ -85,10 +85,12 @@ const sceneListName = ref('')
 const modeList = ref([])
 const init = async () => {
   modeList.value = modeList.value.length == 0 ? await getcaseLists(caseId.value as number) : modeList.value;
-  sceneList.value = await getCaseSceneList(caseId.value as number);
-  if(modeList.value.length){
+  let listss = await getCaseSceneList(caseId.value as number);
+  sceneList.value = listss;
+  if(listss.length){
     sceneList.value.unshift({ id: -1, type: 99, name: '多元融合' });
   }
+  console.log('init', modeList.value, sceneList.value, modeList.value.length);
   handleCommand()
   // let url = getUrlSrc({ id: 0 }, caseId.value)
   // sceneURL.value = url;
@@ -100,7 +102,7 @@ watch(() => qpisceneList.value, () => {
     return;
   }
   let newqpisceneList = qpisceneList.value && JSON.parse(JSON.stringify(qpisceneList.value)) || []
-  if(modeList.value.length){
+  if(newqpisceneList.length){
     newqpisceneList.unshift({ id: -1, type: 99, name: '多元融合' });
   }
   console.log('qpisceneList', qpisceneList.value, newqpisceneList);