<template>
  <div class="event-content">
    <!--<VoteHint v-if="this.$store.getters.getisVoteResulthover==true"/>-->
    <div v-if="this.$store.getters.getIsSelectedNow">
      
      <!--<div v-if="this.$store.getters.getItemTitle.eventType=='課前預習'">
        <PreviewMission/>
      </div>
      <div v-if="this.$store.getters.getItemTitle.eventType=='作業'">
        <Homework/>
      </div>-->
      <div v-if="this.$store.getters.getItemTitle.eventType=='exam'">
        <PaperView/>
      </div>
      <!--<div v-if="this.$store.getters.getItemTitle.eventType=='投票'">
        <Vote/>
      </div>
      <div v-if="this.$store.getters.getItemTitle.eventType=='問卷'">
        <QuesNaire/>
      </div>-->
    </div>
        <!-- 如果篩選時未選的時候預設顯示列表第一個-->
    <div class="noSelected" v-if="!this.$store.getters.getIsSelectedNow">
        <h3>{{$t("studentWeb.event.selectActivity")}}</h3>
    </div>

  </div>
</template>

<script>
import Homework from "./EventContentTypeTemplate/Homework";
import PreviewMission from "./EventContentTypeTemplate/PreviewMission";
import Vote from "./EventContentTypeTemplate/Vote";
import PaperView from "./EventContentTypeTemplate/PaperView";
import VoteHint from "./EventContentTypeTemplate/VoteHint";
import QuesNaire from "./EventContentTypeTemplate/QuesNaire";
export default {
  name: "EventContent",
  components: {
    Homework,
    PreviewMission,
    PaperView,
    Vote,
    VoteHint,
    QuesNaire
  },
  methods: {
    //回傳所渲染出來第一個進行中的活動項目
    //theFirstActiveEvent() {
    //  var k = [];
    //  for (var i = 0; i < this.mockdata.length; i++) {
    //    if (this.mockdata[i].isClosed == false) {
    //      k.push(this.mockdata[i]);
    //    }
    //  }
    //  this.$store.commit("ChangeItemName", k[0]);
    //}
  },
        mounted() {
            //console.log(this.$store.getters.getItemTitle.eventType)
    //this.theFirstActiveEvent(); // <!-- 如果沒選的時候預設顯示列表第一個-->
  },
  data() {
    return {
      //mockdata: mockdata.mockdata
    };
  }
};
</script>

<style>
</style>