<template>
  <div class="content">
    <el-table :data="tableData" border style="width: 100%">
      <el-table-column prop="ticketName" label="作业名称" min-width="600" />
      <el-table-column prop="workstationName" label="岗位" min-width="200" />
      <el-table-column prop="machineryName" label="设备工艺" min-width="500" />
      <el-table-column label="作业类型" prop="ticketType" min-width="150">
        <template #default="scope">
          <dict-tag :type="DICT_TYPE.TICKET_TYPE" :value="scope.row.ticketType" />
        </template>
      </el-table-column>
      <el-table-column prop="ticketStartTime" label="作业开始时间" width="290" />
    </el-table>
  </div>
</template>

<script setup lang="ts">
import {DICT_TYPE} from "@/utils/dict";
import * as Home from "@/api/home";
const tableData = ref([])

onMounted(() => {
  getJobDate()
})
const getJobDate = async () => {
  try {
    const jobData = await Home.getHomePage()
    tableData.value = jobData.jobList
    console.log(jobData, tableData.value, '数据有什么')
  } catch (error) {}
}
</script>

<style scoped lang="scss">

.content {
  width: 100%;
  max-height: 400px;
  overflow: auto;
}
</style>
