gaoluyang
2 天以前 6ae6ee885f0acb59f4c8b2d2439fb58a0a345701
src/views/CNAS/resourceDemand/device/component/fault.vue
@@ -31,7 +31,8 @@
          <el-table-column prop="managementNumber" label="统一编号" min-width="150"></el-table-column>
          <el-table-column prop="faultSituation" label="故障情况" min-width="130"></el-table-column>
          <el-table-column prop="submitPerson" label="提交人" min-width="130"></el-table-column>
          <el-table-column prop="createTime" label="提交日期" min-width="150"></el-table-column>
          <el-table-column prop="createTime" label="提交日期" min-width="150"
            :formatter="formatDateCell"></el-table-column>
          <el-table-column prop="currentState" label="当前状态" min-width="130"></el-table-column>
          <el-table-column prop="currentResponsible" label="当前责任人" width="180"></el-table-column>
          <!-- 操作按钮 -->
@@ -279,9 +280,8 @@
<script>
import { dateFormat } from '@/utils/date'
import { mapGetters } from "@/utils/store-compat";
import draftSave from '@/mixins/draftSave'
import { formatListDate } from './dateFormat'
export default {
  mixins: [draftSave],
  props: {
    clickNodeVal: {
      type: Object,
@@ -320,6 +320,9 @@
    this.getTableList(this.clickNodeVal.value)
  },
  methods: {
    formatDateCell(row, column, cellValue) {
      return formatListDate(cellValue)
    },
    //要求修复日期:禁用在故障日期前的日期
    disabledDate(time) {
      let selectDate = this.form.faultDate
@@ -409,7 +412,6 @@
          }).then(res => {
            if (res.code == 200) {
              this.$message.success('提交成功')
              this.draftClear('fault')
              this.getTableList(this.clickNodeVal.value)
              this.dialogVisible = false
            }
@@ -434,11 +436,6 @@
        this.form.manufacturer = res.data.manufacturer
        this.form.specificationModel = res.data.specificationModel
        this.form.managementNumber = res.data.managementNumber
        if (!this.form.id) {
          this.draftRestore('fault', 'form', this.clickNodeVal.value, 'dialogVisible')
        } else if (this.currentStep === 0) {
          this.draftRestore('fault', 'form', this.form.id, 'dialogVisible')
        }
      });
      // 获取负责人信息
      this.getUserList()
@@ -588,7 +585,6 @@
    },
    dialogVisible(newVal) {
      if (!newVal) {
        this.draftStop('fault')
        this.form = {}
        this.closeLoading()
        this.currentStep = 0 // 步骤条显示第几步