<template>
  <div class="news">
    <Banner :img="require('@/assets/img/introduce.png')" />
    <div class="common-container">
      <el-container>
        <LeftTabs title="中心简介" :options="options" @tabSelect="tabSelect" />
        <RightContent :selectTab="selectTab" :breadList="breadList" />
      </el-container>
    </div>
  </div>
</template>

<script>
import Banner from "../components/Banner";
import LeftTabs from '@/components/LeftTabs'
import RightContent from '@/components/RightContent'
export default {
  name: "Introduce",
  components: {
    Banner,
    LeftTabs,
    RightContent
  },
  data() {
    return {
      loading: true,
      selectTab: {},
      options: [
        {
          label: '平台简介',
          type: 'intro'
        },
        {
          label: '平台人员',
          type: 'staff'
        },
        {
          label: '规章制度',
          type: 'institution'
        }
      ],
      routeList: [
        {
          name: '首页',
          path: '/'
        },
        {
          name: '中心介绍'
        }
      ],
      breadList: []
    };
  },
  methods: {
    // 选择tab
    tabSelect(row) {
      this.selectTab = { ...row }
      this.breadList = [...this.routeList, { name: this.selectTab.label }]
    }
  }
};
</script>

<style lang="scss" scoped>

</style>
