zhongshujie
2024-12-31 d464f452c2ad713bb90227e8edce358be0740a4a
src/books/aviationEtiquette/view/components/chapter005.vue
@@ -380,6 +380,25 @@
            <p class="fz-15">
              某高校每年举行五四礼仪时装秀,以航空职业礼仪和技能展示为主,让每一名学生参与进来并成为主角,对标国际赛事的高规格、高水准,全方位展示学生的职业风采和时尚风貌。从班级普及赛到最终T台呈现,通过形形色色的编排和服装自制,同学们展现了高度职业化的民航员工的专业素质。
            </p>
            <div class="video-box">
              <p class="center text td-0">
                <video :src="videoPathOne" webkit-playsinline="true" x-webkit-airplay="true" playsinline="true"
                  x5-video-orientation="h5" x5-video-player-fullscreen="true" x5-playsinline="" controls
                  controlslist="nodownload" class="w100 video" style="border-radius: 10px"></video>
              </p>
              <p class="center videoname">
                <span>视频:礼仪时装秀</span>
                <el-tooltip class="item" effect="dark" :content="chapterData.isCollectVideo ? '点击取消' : '点击收藏'
                  " placement="top-start">
                  <img :src="collectResourceList.findIndex(
                    (item) => item.id == 'd3ac730a06dcc8381de684ace3263a63'
                  ) > -1
                    ? collectCheck
                    : collectImg
                    " alt="" class="collect-btn" @click="handleCollect('video-01')" />
                </el-tooltip>
              </p>
            </div>
          </div>
          <div class="bk2">
            <div class="zysx">
@@ -931,25 +950,8 @@
          nine: "",
        },
      },
      chapter004: {
        videoMd5: [
          {
            isCollectVideo: false,
            handleMd5: "",
            md5: "7454A10BD25ED828FF31D0702DA63D55",
            name: "什么是心理健康",
          },
          {
            isCollectVideo: false,
            handleMd5: "",
            md5: "E4AC28F178D660E96355C17E6F283E66",
            name: "心理健康的10项标准",
          },
        ],
      },
      chapterData: {
        isCollectVideo: false,
        isCollectVideo01: false,
      },
    };
  },
@@ -962,18 +964,12 @@
    }
    const choiceQuestion = localStorage.getItem(
      "civilAviatyonSevervices-book-chapter04-Data"
      "aviationEtiquette-book-chapter04-Data"
    );
    if (choiceQuestion) {
      this.chapterData = JSON.parse(choiceQuestion);
    }
    const videoData = localStorage.getItem(
      "civilAviatyonSevervices-book-chapter004"
    );
    if (videoData) {
      this.chapter004 = JSON.parse(videoData);
    }
    this.getVidoePath();
    this.collectResourceList = await getCollectResource(
      this.config.activeBook.bookId
@@ -982,17 +978,8 @@
  methods: {
    async getVidoePath() {
      this.videoPathOne = await getResourcePath(
        "f230fd8fd7952a4ad4dd05d94df7e797"
        "d3ac730a06dcc8381de684ace3263a63"
      );
      this.videoPathTwo = await getResourcePath(
        "700cfdb8b85b372045b1e97e3356ae3a"
      );
      for (let index = 0; index < this.chapter004.videoMd5.length; index++) {
        const item = this.chapter004.videoMd5[index];
        if (item.md5 && !item.md5.includes("https:")) {
          item.handleMd5 = await getResourcePath(item.md5);
        }
      }
    },
    setBookQuestion() {
@@ -1004,17 +991,10 @@
    handleChapterData() {
      localStorage.setItem(
        "civilAviatyonSevervices-book-chapter04-Data",
        "aviationEtiquette-book-chapter04-Data",
        JSON.stringify(this.chapterData)
      );
    },
    handlechapter004() {
      localStorage.setItem(
        "civilAviatyonSevervices-book-chapter004",
        JSON.stringify(this.chapter004)
      );
    },
    handleFocus(id) {
      this.isFocused = id; // 当textarea聚焦时,设置为true
    },
@@ -1023,38 +1003,17 @@
    },
    handleCollect(e) {
      if (e.md5) {
      if (e == "video-01") {
        this.handleCollectResource(
          e.md5,
          e.md5,
          "d3ac730a06dcc8381de684ace3263a63",
          "d3ac730a06dcc8381de684ace3263a63",
          "",
          "视频",
          "bits",
          "微课小课堂:" + e.name
        );
        e.isCollectVideo = !e.isCollectVideo;
      } else if (e == "video-01") {
        this.handleCollectResource(
          "f230fd8fd7952a4ad4dd05d94df7e797",
          "f230fd8fd7952a4ad4dd05d94df7e797",
          "",
          "视频",
          "bits",
          "视频:心理学的流派"
          "视频:礼仪时装秀"
        );
        this.chapterData.isCollectVideo = !this.chapterData.isCollectVideo;
      } else if (e == "video-02") {
        this.handleCollectResource(
          "700cfdb8b85b372045b1e97e3356ae3a",
          "700cfdb8b85b372045b1e97e3356ae3a",
          "",
          "视频",
          "bits",
          "视频:心理学的研究内容"
        );
        this.chapterData.isCollectVideo01 = !this.chapterData.isCollectVideo01;
      }
      this.handlechapter004();
      this.handleChapterData();
    },
    //资源收藏事件