<template>
  <div class="client-platform-page client-exam-page">
    <!--  广告  -->
    <div class="client-banner-box">
      <div
        :style="{backgroundImage: `url(${bannerList[0].pic || require(`~/static/images/client/train/train-banner-background.png`)})`}"
        class="client-platform-banner"></div>
    </div>
    <!--  岗位职责  -->
    <gangwei-list label="岗位职责" :list="gangwei" :pc-num="3" :h5-num="2" :pc-margin="320" :h5-margin="0"></gangwei-list>

    <!--  能力提升  -->
    <div class="client-nengli-box client-container">
      <h4>能力提升</h4>
      <img :src="img1" alt="能力提升">
    </div>

    <!--  部分课程列表  -->
    <div class="platform-course-list client-container">
      <h4>部分课程列表</h4>
      <mtaTable :data="tableData" :config="tableConfig" @shi-kan="shiKan"></mtaTable>
      <div class="btn-groups center">
        <freeTrialBtn class="btn-item" myType="kaoshi"/>
        <onlineInformationBtn />
      </div>
    </div>

    <videoDialog :source="curVideo" :visible.sync="visible"></videoDialog>

  </div>
</template>

<script>
import mtaTable from "~/components/common/mtaTable";
import videoDialog from "~/components/common/videoDialog";
import freeTrialBtn from "~/components/common/freeTrialBtn";
import onlineInformationBtn from "~/components/common/onlineInformationBtn";
import gangweiList from "@/components/common/layout/desComp/gangweiList";
import {BannerImgs, chanpinyunying} from "~/defaultConfig";

/**
 * @ 产品与服务 -> 课程资源 -> 产品运营
 */
export default {
  name: "professionalQuality",
  layout: 'templateB',
  head() {
    return {
      title: '在线考试平台_在线考试软件_试卷软件系统',
      meta: [
        {
          name: 'keywords',
          content: '考试平台,试卷系统,试卷软件'
        },
        {
          name: 'description',
          content: '麦塔考试系统具有良好高并发性和访问安全部署、严格的考试监控防作弊功能、PC移动支持多终端，随时随地考试、丰富的考试管理功能。'
        }
      ],
    }
  },
  async asyncData({$axios}) {
    const arr = [
      $axios.$post(`/home/banner/list`, {'code': BannerImgs.chanpinyunying}),
    ]
    const [res1] = await Promise.all(arr);
    return {
      bannerList: res1.data.data || [],
    }
  },
  components: {
    mtaTable, videoDialog,
    freeTrialBtn, onlineInformationBtn, gangweiList
  },
  data() {
    return {
      tableConfig: [
        {
          label: '课程名称',
          key: 'name'
        },
        {
          label: '使用行业',
          key: 'hangye'
        },
        {
          label: '使用人群',
          key: 'renqun'
        }
      ],
      tableData: [
        {
          name: '助你获得客户资源（运营实战课）',
          shikanUrl: 'https://spdb.mtavip.com/c708e29d83f842ec9cd6a11ffb831559/d6fb5cc7893f4405b937fbe99c5080f4-df942531e5deaa288ddd098af1d2ff28-fd.mp4',
          hangye: '全行业',
          renqun: '客户专员'
        },
        {
          name: '不再为流量发愁',
          shikanUrl: '',
          hangye: '全行业',
          renqun: '客户专员'
        },
        {
          name: '5G开启新互联网时代',
          shikanUrl: '',
          hangye: '全行业',
          renqun: '客户专员'
        },
        {
          name: '创新思维课',
          shikanUrl: '',
          hangye: '全行业',
          renqun: '客户专员'
        },
      ],
      curVideo: '',
      visible: false,
      img1: require("~/static/productImage/p45.png")
    }
  },
  computed: {
    gangwei() {
      return chanpinyunying
    }
  },
  methods: {
    shiKan({url}) {
      this.visible = true;
      this.curVideo = url;
    }
  }
}
</script>

<style lang="scss" scoped>

.client-nengli-box {
  margin-bottom: 120px;

  h4 {
    font-size: 30px;
    color: #333;
    font-weight: 800;
    text-align: center;
    margin-bottom: 50px;
  }

  img {
    height: 100%;
    width: 330px;
    text-align: center;
    margin: 0 auto;
    display: block;
  }
}

.platform-course-list {

  h4 {
    font-size: 30px;
    font-weight: 800;
    color: #333;
    text-align: center;
    margin-bottom: 68px;
  }
}
@media (max-width: 768px) {

  .platform-course-list {
    h4 {
      font-size: 18px;
      font-weight: 800;
      color: #333;
      text-align: center;
      margin-bottom: 10%;
      margin-top: 15%;
    }
  }
  .client-nengli-box {
    margin-bottom: 5%;

    h4 {
      font-size: 18px;
      margin-bottom: 30px;
    }

    img {
      height: 200px;
      width: 100%;
    }
  }
}
</style>
