<template>
    <div class="inbox">
      <table width="100%">
        <tr align="center" style="color: #54ad4c; line-height: 40px">
          <!-- <th width="8%">用车需求编号</th> -->
          <th width="10%">入厂类型</th>
          <th width="13%">用车需求编号</th>
          <th width="10%">物流公司</th>
          <th width="9%">车牌号</th>
          <th width="10%">司机姓名</th>
          <th width="10%">司机电话</th>
          <th width="10%">司机身份证</th>
          <th width="9%">进厂门</th>
          <th width="9%">出厂门</th>
          <th width="10%">当前状态</th>
        </tr>
      </table>
      <vue-seamless-scroll :data="dataSource" class="seamless-warps-scroll" :class-option="classOption">
        <table width="100%">
          <tbody style="color: rgba(0, 0, 0, 0.65); font-weight: 100 !important;">
            <tr v-for="(item, index) in dataSource" align="center" :key="index">
              <!-- <th width="8%">{{ item.vdNo }}</th>  -->
              <th width="10%">{{ item.efType_dictText }}</th> 
              <th width="13%">{{ item.vdNo }}</th> 
              <th width="10%">{{ item.logistics }}</th> 
              <th width="9%">{{ item.carNum }}</th> 
              <th width="10%">{{ item.driverName }}</th> 
              <th width="10%">{{ item.driverTel }}</th> 
              <th width="10%">{{ item.driverIdCard }}</th> 
              <th width="9%">{{ item.enterFactoryDoor }}</th> 
              <th width="9%">{{ item.exitFactoryDoor }}</th>
              <th width="10%">{{ item.currentStatus_dictText }}</th>
            </tr>
          </tbody>
        </table>
      </vue-seamless-scroll>
    </div>
  </template>
  
  <script>
  import { getAction } from '@api/manage'
  import vueSeamlessScroll from 'vue-seamless-scroll'
  
    export default {
      name: 'Vehicle',
      props: {
        height: Number,
        dataSource: Array
      },
      components: {
        vueSeamlessScroll
      },
      data() {
        return {
          timer: null,
        };
      },
      computed: {
        classOption() {
          return {
            step: 0.1, // 数值越大速度滚动越快
            limitMoveNum: this.dataSource.length, // 开始无缝滚动的数据量 this.dataList.length
            hoverStop: true, // 是否开启鼠标悬停stop
            direction: 1, // 0向下 1向上 2向左 3向右
            openWatch: true, // 开启数据实时监控刷新dom
            singleHeight: 0, // 单步运动停止的高度(默认值0是无缝不停止的滚动) direction => 0/1
            singleWidth: 0, // 单步运动停止的宽度(默认值0是无缝不停止的滚动) direction => 2/3
            waitTime: 1000, // 单步运动停止的时间(默认值1000ms)
          }
        },
      },
      methods: {
      },
      created(){
      },
      mounted(){
      }
    };
  </script>
  
  <style scoped>
    .inbox{
      padding:2px ;
      max-height: 200px;
      overflow: hidden;
    }
  
    .seamless-warps-scroll {
      overflow: hidden;
    }
  </style>