<template>
  <div>
    <el-tabs v-model="activeTab" @tab-click="handleTypeTabClick" >
      <el-tab-pane
        v-for="(item, index) in options"
        :key="item.value"
        :label="item.label"
        :name="item.value"
      >
      </el-tab-pane>
    </el-tabs>

    <iframe :src="src" width="100%" height="1000px" frameborder="0"></iframe>
  </div>
</template>

<script>
import { listCar, getCar, delCar, addCar, updateCar } from "/src/api/car/car";
import {listMessage, testMessage} from "@/api/car/message/message";
import {getMessageType, listMessageType} from "@/api/car/message/messageType";

export default {
  name: "Reveal",
  data() {
    return {
      src:'',
      options: [
        {
          value: '/firm/car/car',
          label: '车辆数据'
        },
        {
          value: '/car/log',
          label: '故障日志'
        },
        {
          value: '/car/breakdown',
          label: '车辆故障'
        },
      ],
      activeTab: '/firm/car/car'
    };
  },
  created() {

  },
  methods: {
    handleTypeTabClick(tab){
      console.log(tab.name)
      this.src = tab.name
    },
  }
};
</script>
