<!--
 * @Author: zwq
 * @Date: 2020-12-29 16:37:56
 * @LastEditors: zwq
 * @LastEditTime: 2022-03-04 11:05:23
 * @Description:
-->
<template>
  <el-dialog
    :title="'btn.see' | i18nFilter"
    :visible.sync="visible"
  >
    <el-row :gutter="10">
      <el-form
        ref="dataForm"
        :model="dataForm"
        size="medium"
        label-width="110px"
        label-position="left"
      >
        <el-col :span="12">
          <el-row>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.TaskBoxNumber')" prop="taskCode">
                <el-input v-model="dataForm.taskCode" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.FullBoxNumber')" prop="orderName">
                <el-input v-model="dataForm.orderName" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.ExecutionOperation')" prop="fullCode">
                <el-input v-model="dataForm.fullCode" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.TaskStatus')" prop="name">
                <el-input v-model="dataForm.name" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.ScrapInfo.remark')" prop="remark">
                <el-input v-model="dataForm.remark" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
          </el-row>
        </el-col>
        <el-col :span="12">
          <el-row>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.TaskLocation')" prop="createTime">
                <el-input v-model="dataForm.createTime" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.FullBoxStartLocation')" prop="taskType">
                <el-input v-model="dataForm.taskType" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.Priority')" prop="emptyCode">
                <el-input v-model="dataForm.emptyCode" readonly :style="{width: '100%'}" />
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item :label="$t('module.basicData.Warehouse.NextOperation')" prop="anotherCurrLocation">
                <el-input
                  v-model="dataForm.anotherCurrLocation"
                  readonly
                  :style="{width: '100%'}"
                />
              </el-form-item>
            </el-col>
          </el-row>
        </el-col>
      </el-form>
    </el-row>
    <span slot="footer" class="dialog-footer">
      <el-button @click="visible = false">{{ 'btn.cancel' | i18nFilter }}</el-button>
      <el-button type="primary" @click="visible = false">{{ $t('module.basicData.Warehouse.PerformTaskManual') | i18nFilter }} </el-button>
    </span>
  </el-dialog>
</template>

<script>
// import { CurrentTaskDetail } from '@/api/basicData/Warehouse/HistoricalTask'

export default {
  data() {
    return {
      visible: false,
      dataForm: {
        id: '',
        taskCode: undefined,
        orderName: undefined,
        fullCode: undefined,
        name: undefined,
        remark: undefined,
        field119: undefined,
        createTime: undefined,
        taskType: undefined,
        emptyCode: undefined,
        anotherCurrLocation: undefined,
        field121: undefined,
        taskSource: undefined,
        anotherCurrProcessCode: undefined,
        anotherNextProcessCode: undefined,
        anotherTargetLocation: undefined,
        field126: undefined
      }
    }
  },
  methods: {
    init(id) {
      this.dataForm.id = id
      this.visible = true
      this.$nextTick(() => {
        this.$refs['dataForm'].resetFields()
      })
    }
  }
}
</script>
