杨磊
5 天以前 97eb39caf61e8ea8f70776af267f6deed51720fe
src/books/aurturingAndEducationAged0to3/view/components/index.vue
@@ -9,10 +9,14 @@
      transformOrigin: 'center top',
    }">
      <pageHeader v-if="showCatalogList.indexOf(1) > -1" :showPageList="loadPageList"></pageHeader>
      <chapterOne v-if="showCatalogList.indexOf(2) > -1" :showPageList="loadPageList"></chapterOne>
      <chapterTwo v-if="showCatalogList.indexOf(3) > -1" :showPageList="loadPageList"></chapterTwo>
      <chapterThree v-if="showCatalogList.indexOf(4) > -1" :showPageList="loadPageList"></chapterThree>
      <chapterFour v-if="showCatalogList.indexOf(5) > -1" :showPageList="loadPageList"></chapterFour>
      <chapterOne v-if="showCatalogList.indexOf(2) > -1" :showPageList="loadPageList" :resourceList="resourceList">
      </chapterOne>
      <chapterTwo v-if="showCatalogList.indexOf(3) > -1" :showPageList="loadPageList" :resourceList="resourceList">
      </chapterTwo>
      <chapterThree v-if="showCatalogList.indexOf(4) > -1" :showPageList="loadPageList" :resourceList="resourceList">
      </chapterThree>
      <chapterFour v-if="showCatalogList.indexOf(5) > -1" :showPageList="loadPageList" :resourceList="resourceList">
      </chapterFour>
      <chapterFive v-if="showCatalogList.indexOf(6) > -1" :showPageList="loadPageList"></chapterFive>
    </div>
  </div>
@@ -51,6 +55,7 @@
      audioPath: "",
      currentTime: null,
      videoList: [],
      resourceList: {},
    };
  },
  computed: {
@@ -102,6 +107,11 @@
          this.container ? this.container : document
        ).querySelector(".page-main");
        scrollBox.scrollTop = (scrollBox.scrollTop / oldVal) * newVal;
      },
    },
    resourceList: {
      handler(newVal, oldVal) {
        this.resourceList = newVal;
      },
    },
  },
@@ -165,9 +175,9 @@
    }, 500);
    // 测试页面跳转
    setTimeout(() => {
      this.gotoPage(2, 12);
    }, 500);
    //setTimeout(() => {
    //   this.gotoPage(5, 252);
    //}, 500);
    // const pageDom = (this.container ? this.container : document)
    //   .querySelector("#app")