d286265fcefa1ab2233742cf1e30b38ae6c9215f..6d40892cb8f829f90d1bcae271092a7bfcc40836
9 天以前 zhaowei
取消鉴定工单审批提交代码注释
6d4089 对比 | 目录
9 天以前 zhaowei
鉴定工单审批弹窗维修工填写检查结果
c852aa 对比 | 目录
已添加1个文件
已修改4个文件
1272 ■■■■ 文件已修改
src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue 457 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/eam/technical/modules/EamTechnicalStatusEvaluationOrderModal.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowable/workflow/FlowTodo.vue 116 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowable/workflow/TechnicalStatusEvaluation/TechnicalStatusEvaluationApprovalModal.vue 689 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/eam/technical/EamTechnicalStatusEvaluationOrderList.vue
@@ -6,18 +6,23 @@
        <a-row :gutter="24">
          <a-col :xl="5" :lg="6" :md="8" :sm="12">
            <a-form-item label="统一编码">
              <technical-status-equipment-select placeholder="请输入统一编码或名称搜索"
                                                 v-model="queryParam.equipmentId" />
              <lx-search-equipment-select placeholder="请输入统一编码或名称搜索" v-model="queryParam.equipmentId"/>
            </a-form-item>
          </a-col>
          <a-col :xl="5" :lg="6" :md="8" :sm="12">
            <a-form-item label="工单号">
              <a-input placeholder="请输入工单号" v-model="queryParam.orderNum" />
              <a-input placeholder="请输入工单号" v-model="queryParam.orderNum"/>
            </a-form-item>
          </a-col>
          <a-col :xl="5" :lg="6" :md="8" :sm="12">
            <a-form-item label="计划鉴定日期">
              <a-date-picker v-model="queryParam.evaluationDate" style="width: 100%" />
              <a-date-picker v-model="queryParam.evaluationDate" style="width: 100%"/>
            </a-form-item>
          </a-col>
          <a-col :xl="5" :lg="6" :md="8" :sm="12">
            <a-form-item label="鉴定状态">
              <j-dict-select-tag placeholder="请选择鉴定状态" dict-code="technical_status_evaluation_order_status"
                                 v-model="queryParam.evaluationStatus"/>
            </a-form-item>
          </a-col>
          <a-col :xl="4" :lg="6" :md="8" :sm="12">
@@ -40,235 +45,251 @@
             :scroll="{ x: 'max-content' }" :loading="loading" @change="handleTableChange">
        <span slot="action" slot-scope="text, record">
          <a-popconfirm v-if="record.evaluationStatus === 'WAIT_EVALUATION'" title="确定领取吗?"
                        @confirm="handleReceive(record.id)">
          <template v-if="record.evaluationStatus === 'WAIT_EVALUATION'">
            <a-popconfirm title="确定领取吗?"
                          @confirm="handleReceive(record.id)">
            <a>领取</a>
          </a-popconfirm>
           <a-divider type="vertical"/>
          </template>
            <a @click="handleDetail(record)">详情</a>
        </span>
    </a-table>
    <!-- table区域-end -->
    <!-- è¡¨å•区域 -->
    <eamTechnicalStatusEvaluationOrder-modal ref="modalForm" @ok="modalFormOk" />
    <eamTechnicalStatusEvaluationOrder-modal ref="modalForm" @ok="modalFormOk"/>
    <technical-status-evaluation-approval-modal ref="technicalStatusEvaluationApprovalModal"
                                                :selectShenpiData="selectedOrderData"/>
  </a-card>
</template>
<script>
import EamTechnicalStatusEvaluationOrderModal from './modules/EamTechnicalStatusEvaluationOrderModal'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import TechnicalStatusEquipmentSelect from '../equipment/modules/TechnicalStatusEquipmentSelect'
import { getAction } from '@/api/manage'
  import EamTechnicalStatusEvaluationOrderModal from './modules/EamTechnicalStatusEvaluationOrderModal'
  import { JeecgListMixin } from '@/mixins/JeecgListMixin'
  import { getAction } from '@/api/manage'
  import LxSearchEquipmentSelect from '../equipment/modules/LxSearchEquipmentSelect'
  import TechnicalStatusEvaluationApprovalModal
    from '../../flowable/workflow/TechnicalStatusEvaluation/TechnicalStatusEvaluationApprovalModal'
export default {
  name: 'EamTechnicalStatusEvaluationOrderList',
  mixins: [JeecgListMixin],
  components: {
    TechnicalStatusEquipmentSelect,
    EamTechnicalStatusEvaluationOrderModal
  },
  data() {
    return {
      description: '技术状态鉴定工单管理页面',
      // è¡¨å¤´
      columns: [
        {
          title: '#',
          dataIndex: '',
          key: 'rowIndex',
          width: 60,
          align: 'center',
          customRender: function(t, r, index) {
            return parseInt(index) + 1
  export default {
    name: 'EamTechnicalStatusEvaluationOrderList',
    mixins: [JeecgListMixin],
    components: {
      TechnicalStatusEvaluationApprovalModal,
      LxSearchEquipmentSelect,
      EamTechnicalStatusEvaluationOrderModal
    },
    data() {
      return {
        description: '技术状态鉴定工单管理页面',
        selectedOrderData: {},
        // è¡¨å¤´
        columns: [
          {
            title: '#',
            dataIndex: '',
            key: 'rowIndex',
            width: 60,
            align: 'center',
            customRender: function(t, r, index) {
              return parseInt(index) + 1
            },
            fixed: 'left'
          },
          fixed: 'left'
        },
        {
          title: '统一编码',
          align: 'center',
          dataIndex: 'equipmentCode',
          fixed: 'left'
        },
        {
          title: '设备名称',
          align: 'center',
          dataIndex: 'equipmentName',
          fixed: 'left'
        },
        {
          title: '设备型号',
          align: 'center',
          dataIndex: 'equipmentModel',
          fixed: 'left'
        },
        {
          title: '工单号',
          align: 'center',
          dataIndex: 'orderNum',
          fixed: 'left'
        },
        {
          title: '计划鉴定日期',
          align: 'center',
          dataIndex: 'evaluationDate',
          fixed: 'left'
        },
        {
          title: '锁定工单日期',
          align: 'center',
          dataIndex: 'freezeOrderDate'
        },
        {
          title: '工单过期日期',
          align: 'center',
          dataIndex: 'orderExpirationDate'
        },
        {
          title: '实际开始时间',
          align: 'center',
          dataIndex: 'actualStartTime'
        },
        {
          title: '实际结束时间',
          align: 'center',
          dataIndex: 'actualEndTime'
        },
        {
          title: '鉴定人',
          align: 'center',
          dataIndex: 'evaluator'
        },
        {
          title: '鉴定状态',
          align: 'center',
          dataIndex: 'evaluationStatus_dictText'
        },
        {
          title: '创建方式',
          align: 'center',
          dataIndex: 'creationMethod_dictText'
        },
        {
          title: '安全装置检查结果',
          align: 'center',
          dataIndex: 'safetyEquipmentCheckResult'
        },
        {
          title: '精度参数检查结果',
          align: 'center',
          dataIndex: 'precisionCheckResult'
        },
        {
          title: '功能状态检查结果',
          align: 'center',
          dataIndex: 'functionalCheckResult'
        },
        {
          title: '其他检查结果',
          align: 'center',
          dataIndex: 'otherCheckResult'
        },
        {
          title: '维修室主任签字',
          align: 'center',
          dataIndex: 'repairManagerSignature'
        },
        {
          title: '维修室主任签字时间',
          align: 'center',
          dataIndex: 'repairManagerSignatureTime1'
        },
        {
          title: '试件检查结果',
          align: 'center',
          dataIndex: 'sampleCheckResult'
        },
        {
          title: '工艺员签字',
          align: 'center',
          dataIndex: 'processTechnicianSignature'
        },
        {
          title: '工艺员签字时间',
          align: 'center',
          dataIndex: 'processTechnicianSignatureTime'
        },
        {
          title: '鉴定结果',
          align: 'center',
          dataIndex: 'evaluationResult'
        },
        {
          title: '限/禁用原因',
          align: 'center',
          dataIndex: 'evaluationReason'
        },
        {
          title: '设备检查人签字',
          align: 'center',
          dataIndex: 'inspectorSignature'
        },
        {
          title: '设备检查人签字时间',
          align: 'center',
          dataIndex: 'inspectorSignatureTime'
        },
        {
          title: '附录A HF编码',
          align: 'center',
          dataIndex: 'hfCodeA'
        },
        {
          title: '附录B HF编码',
          align: 'center',
          dataIndex: 'hfCodeB'
        },
        {
          title: '附录C HF编码',
          align: 'center',
          dataIndex: 'hfCodeC'
        },
        {
          title: '附录D HF编码',
          align: 'center',
          dataIndex: 'hfCodeD'
        },
        {
          title: '操作',
          dataIndex: 'action',
          align: 'center',
          scopedSlots: { customRender: 'action' },
          fixed: 'right'
          {
            title: '统一编码',
            align: 'center',
            dataIndex: 'equipmentCode',
            fixed: 'left'
          },
          {
            title: '设备名称',
            align: 'center',
            dataIndex: 'equipmentName',
            fixed: 'left'
          },
          {
            title: '设备型号',
            align: 'center',
            dataIndex: 'equipmentModel',
            fixed: 'left'
          },
          {
            title: '工单号',
            align: 'center',
            dataIndex: 'orderNum'
          },
          {
            title: '计划鉴定日期',
            align: 'center',
            dataIndex: 'evaluationDate'
          },
          {
            title: '锁定工单日期',
            align: 'center',
            dataIndex: 'freezeOrderDate'
          },
          {
            title: '工单过期日期',
            align: 'center',
            dataIndex: 'orderExpirationDate'
          },
          {
            title: '实际开始时间',
            align: 'center',
            dataIndex: 'actualStartTime'
          },
          {
            title: '实际结束时间',
            align: 'center',
            dataIndex: 'actualEndTime'
          },
          {
            title: '领取人',
            align: 'center',
            dataIndex: 'evaluator_dictText'
          },
          {
            title: '鉴定状态',
            align: 'center',
            dataIndex: 'evaluationStatus_dictText'
          },
          {
            title: '创建方式',
            align: 'center',
            dataIndex: 'creationMethod_dictText'
          },
          {
            title: '安全装置检查结果',
            align: 'center',
            dataIndex: 'safetyEquipmentCheckResult'
          },
          {
            title: '精度参数检查结果',
            align: 'center',
            dataIndex: 'precisionCheckResult'
          },
          {
            title: '功能状态检查结果',
            align: 'center',
            dataIndex: 'functionalCheckResult'
          },
          {
            title: '其他检查结果',
            align: 'center',
            dataIndex: 'otherCheckResult'
          },
          {
            title: '维修室主任签字',
            align: 'center',
            dataIndex: 'repairManagerSignature'
          },
          {
            title: '维修室主任签字时间',
            align: 'center',
            dataIndex: 'repairManagerSignatureTime1'
          },
          {
            title: '试件检查结果',
            align: 'center',
            dataIndex: 'sampleCheckResult'
          },
          {
            title: '工艺员签字',
            align: 'center',
            dataIndex: 'processTechnicianSignature'
          },
          {
            title: '工艺员签字时间',
            align: 'center',
            dataIndex: 'processTechnicianSignatureTime'
          },
          {
            title: '鉴定结果',
            align: 'center',
            dataIndex: 'evaluationResult'
          },
          {
            title: '限/禁用原因',
            align: 'center',
            dataIndex: 'evaluationReason'
          },
          {
            title: '设备检查人签字',
            align: 'center',
            dataIndex: 'inspectorSignature'
          },
          {
            title: '设备检查人签字时间',
            align: 'center',
            dataIndex: 'inspectorSignatureTime'
          },
          {
            title: '附录A HF编码',
            align: 'center',
            dataIndex: 'hfCodeA'
          },
          {
            title: '附录B HF编码',
            align: 'center',
            dataIndex: 'hfCodeB'
          },
          {
            title: '附录C HF编码',
            align: 'center',
            dataIndex: 'hfCodeC'
          },
          {
            title: '附录D HF编码',
            align: 'center',
            dataIndex: 'hfCodeD'
          },
          {
            title: '操作',
            dataIndex: 'action',
            align: 'center',
            scopedSlots: { customRender: 'action' },
            fixed: 'right'
          }
        ],
        url: {
          list: '/eam/eamTechnicalStatusEvaluationOrder/list',
          receive: '/eam/eamTechnicalStatusEvaluationOrder/collect'
        }
      ],
      url: {
        list: '/eam/eamTechnicalStatusEvaluationOrder/list',
        receive: '/eam/eamTechnicalStatusEvaluationOrder/collect',
      }
    },
    methods: {
      handleReceive(id) {
        let that = this
        this.loading = true
        getAction(that.url.receive, { id })
          .then(res => {
            if (res.success) {
              that.$notification.success({
                message: '消息',
                description: res.message
              })
              that.loadData()
            } else {
              that.$notification.warning({
                message: '消息',
                description: res.message
              })
              that.loading = false
            }
          })
      },
      handleDetail(record) {
        this.selectedOrderData = Object.assign({}, record)
        this.$refs.technicalStatusEvaluationApprovalModal.recordDetail(record)
        this.$refs.technicalStatusEvaluationApprovalModal.title = '详情'
        this.$refs.technicalStatusEvaluationApprovalModal.disableSubmit = true
      }
    }
  },
  computed: {
  },
  methods: {
    handleReceive(id) {
      let that = this
      this.loading = true
      getAction(that.url.receive, { id })
        .then(res => {
          if (res.success) {
            that.$notification.success({
              message: '消息',
              description: res.message
            })
            that.loadData();
          } else {
            that.$notification.warning({
              message: '消息',
              description: res.message
            })
            that.loading = false
          }
        })
    }
  }
}
</script>
src/views/eam/technical/modules/EamTechnicalStatusEvaluationOrderModal.vue
@@ -101,11 +101,11 @@
              type: JVXETypes.hidden
            },
            {
              title: '项目序号',
              title: '序号',
              key: 'itemCode',
              type: JVXETypes.normal,
              align: 'center',
              width: 150
              width: 60
            },
            {
              title: '检查项目',
@@ -126,11 +126,11 @@
              type: JVXETypes.hidden
            },
            {
              title: '项目序号',
              title: '序号',
              key: 'itemCode',
              type: JVXETypes.normal,
              align: 'center',
              width: 150
              width: 60
            },
            {
              title: '检查项目',
src/views/flowable/workflow/FlowTodo.vue
@@ -91,8 +91,11 @@
    <maintenance-standard-approval-modal ref="maintenanceStandardApprovalModal" @modalFormOk="modalFormOk"
                                         :selectShenpiData="selectedRowData"/>
    <inspection-order-handle ref="modalFormInspectionOrder" :selectShenpiData="selectedRowData"
    <inspection-order-handle ref="inspectionOrderHandle" :selectShenpiData="selectedRowData"
                             @modalFormOk="modalFormOk"/>
    <technical-status-evaluation-approval-modal ref="technicalStatusApprovalModal" :selectShenpiData="selectedRowData"
                                                @modalFormOk="modalFormOk"/>
  </a-card>
</template>
@@ -102,11 +105,13 @@
  import { getAction } from '@api/manage'
  import MaintenanceStandardApprovalModal from './MaintenanceStandard/MaintenanceStandardApprovalModal'
  import InspectionOrderHandle from './InspectionOrder/InspectionOrderHandle'
  import TechnicalStatusEvaluationApprovalModal
    from './TechnicalStatusEvaluation/TechnicalStatusEvaluationApprovalModal'
  export default {
    name: 'NcDeviceCharactersList',
    mixins: [JeecgListMixin, mixinDevice],
    components: { InspectionOrderHandle, MaintenanceStandardApprovalModal },
    components: { TechnicalStatusEvaluationApprovalModal, InspectionOrderHandle, MaintenanceStandardApprovalModal },
    data() {
      return {
        description: '工作流-我的待办',
@@ -203,9 +208,6 @@
          case 'sbdjApproval':
            this.handInspectionOrder(item)
            break
          case 'WEEK_MAINTENANCE':
            this.handleWeekMaintenance(item)
            break
          case 'eam_repair':
            this.handleRepairOrder(item)
            break
@@ -215,8 +217,8 @@
          case 'third_maintenance':
            this.handleThirdMaintenance(item)
            break
          case 'toolOutStorageApproval':
            this.handleToolOutStorageApproval(item)
          case 'TECHNICAL_STATUS_EVALUATION':
            this.handleTechnicalStatusEvaluation(item)
            break
          case 'toolsStocktakingBound':
            this.handleToolStocktakingApproval(item)
@@ -230,7 +232,7 @@
      },
      /**
       * ç‚¹å‡»ä¿å…»è§„范分类流程详情时触发
       * ç‚¹å‡»ä¿å…»è§„范分类流程执行审批时触发
       * @param record
       */
      handleMaintenanceStandard(record) {
@@ -239,6 +241,58 @@
        this.$refs.maintenanceStandardApprovalModal.title = '保养规范'
        this.$refs.maintenanceStandardApprovalModal.getAllApproveData(record)
        this.$refs.maintenanceStandardApprovalModal.getBasicInformation(record)
      },
      /**
       * ç‚¹å‡»æŠ€æœ¯çŠ¶æ€é‰´å®šæµç¨‹æ‰§è¡Œå®¡æ‰¹æ—¶è§¦å‘
       * @param record
       */
      handleTechnicalStatusEvaluation(record) {
        this.selectedRowData = Object.assign({}, record)
        this.$refs.technicalStatusApprovalModal.visible = true
        this.$refs.technicalStatusApprovalModal.title = record.name
        this.$refs.technicalStatusApprovalModal.handleDetail(record)
      },
      /**
       * ç‚¹å‡»ç‚¹æ£€å·¥å•流程执行审批时触发
       * @param record
       */
      handInspectionOrder(record) {
        console.log('record----->', record)
        this.selectedRowData = Object.assign({}, record)
        this.$refs.inspectionOrderHandle.visible = true
        this.$refs.inspectionOrderHandle.title = record.name
        this.$refs.inspectionOrderHandle.getAllApproveData(record)
        this.$refs.inspectionOrderHandle.getBasicInformation(record)
      },
      /**
       * ç‚¹å‡»è®¾å¤‡ç»´ä¿®åˆ†ç±»æµç¨‹æ‰§è¡Œå®¡æ‰¹æ—¶è§¦å‘
       * @param record
       */
      handleRepairOrder(record) {
        this.selectRepairOrderData = Object.assign({}, record)
        this.$refs.repairOrderApprovalModal.visible = true
        this.$refs.repairOrderApprovalModal.title = record.name
        this.$refs.repairOrderApprovalModal.getAllApproveData(record)
        this.$refs.repairOrderApprovalModal.getBasicInformation(record)
      },
      handleSecondMaintenance(item) {
        if (item && item.dataId) {
          this.selectSecondMaintenanceData = Object.assign({}, item)
          this.$refs.secondMaintenanceApprovalModal.handleDetail(item)
          this.$refs.secondMaintenanceApprovalModal.title = item.name
          this.$refs.secondMaintenanceApprovalModal.disableSubmit = false
        }
      },
      handleThirdMaintenance(item) {
        if (item && item.dataId) {
          this.selectThirdMaintenanceData = Object.assign({}, item)
          this.$refs.thirdMaintenanceApprovalModal.handleDetail(item)
          this.$refs.thirdMaintenanceApprovalModal.title = item.name
          this.$refs.thirdMaintenanceApprovalModal.disableSubmit = false
        }
      },
      batchHandle() {
@@ -275,52 +329,6 @@
        let parts = title.split(':') // æ³¨æ„å†’号是全角字符,使用对应的字进行分割
        let result = parts[0]
        return result
      },
      handInspectionOrder(record) {
        console.log('record----->', record)
        this.selectedRowData = Object.assign({}, record)
        this.$refs.modalFormInspectionOrder.visible = true
        this.$refs.modalFormInspectionOrder.title = record.name
        this.$refs.modalFormInspectionOrder.getAllApproveData(record)
        this.$refs.modalFormInspectionOrder.getBasicInformation(record)
      },
      handleWeekMaintenance(item) {
        if (item && item.dataId) {
          this.selectWeekMaintenanceData = Object.assign({}, item)
          this.$refs.weekMaintenanceApprovalModal.handleDetail(item)
          this.$refs.weekMaintenanceApprovalModal.title = item.name
          this.$refs.weekMaintenanceApprovalModal.disableSubmit = false
        }
      },
      /**
       * ç‚¹å‡»è®¾å¤‡ç»´ä¿®åˆ†ç±»æµç¨‹è¯¦æƒ…时触发
       * @param record
       */
      handleRepairOrder(record) {
        this.selectRepairOrderData = Object.assign({}, record)
        this.$refs.repairOrderApprovalModal.visible = true
        this.$refs.repairOrderApprovalModal.title = record.name
        this.$refs.repairOrderApprovalModal.getAllApproveData(record)
        this.$refs.repairOrderApprovalModal.getBasicInformation(record)
      },
      handleSecondMaintenance(item) {
        if (item && item.dataId) {
          this.selectSecondMaintenanceData = Object.assign({}, item)
          this.$refs.secondMaintenanceApprovalModal.handleDetail(item)
          this.$refs.secondMaintenanceApprovalModal.title = item.name
          this.$refs.secondMaintenanceApprovalModal.disableSubmit = false
        }
      },
      handleThirdMaintenance(item) {
        if (item && item.dataId) {
          this.selectThirdMaintenanceData = Object.assign({}, item)
          this.$refs.thirdMaintenanceApprovalModal.handleDetail(item)
          this.$refs.thirdMaintenanceApprovalModal.title = item.name
          this.$refs.thirdMaintenanceApprovalModal.disableSubmit = false
        }
      }
    }
  }
src/views/flowable/workflow/TechnicalStatusEvaluation/TechnicalStatusEvaluationApprovalModal.vue
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,689 @@
<template>
  <j-modal :title="title" :width="1200" :visible="visible" :confirmLoading="confirmLoading"
           :okButtonProps="{ class:{'jee-hidden': disableSubmit} }" fullscreen @ok="handleOk"
           @cancel="handleCancel" centered cancelText="关闭">
    <a-spin :spinning="spinning">
      <a-form-model ref="form" :model="model" :rules="validatorRules" :labelCol="labelCol" :wrapperCol="wrapperCol">
        <a-row :gutter="24">
          <a-col :span="8">
            <a-tabs>
              <a-tab-pane tab="基础信息">
                <a-row>
                  <a-col :span="12">
                    <a-form-model-item label="工单号">
                      <a-input v-model="model.orderNum" readOnly/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="12">
                    <a-form-model-item label="统一编码">
                      <technical-status-equipment-select v-model="model.equipmentId"
                                                         @autocompleteForm="autocompleteForm" disabled/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
                <a-row>
                  <a-col :span="12">
                    <a-form-model-item label="计划鉴定日期">
                      <a-input v-model="model.evaluationDate" readOnly/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="12">
                    <a-form-model-item label="领取人">
                      <a-input v-model="model.evaluator_dictText" readOnly/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
                <a-row>
                  <a-form-model-item :labelCol="labelColLong" :wrapperCol="wrapperColLong" label="备注">
                    <a-textarea v-model="model.remark" readOnly/>
                  </a-form-model-item>
                </a-row>
              </a-tab-pane>
            </a-tabs>
          </a-col>
          <a-col :span="model.evaluationStatus&&model.evaluationStatus!='UNDER_EVALUATION'?10:16">
            <a-tabs :active-key="activeTabKey" @change="handleTabChange">
              <a-tab-pane :key="1" tab="安全装置检查" forceRender
                          v-if="selectShenpiData.taskDefKey&&selectShenpiData.taskDefKey=='safety_equipment_check'||!Boolean(selectShenpiData.taskDefKey)">
                <j-vxe-table ref="editableDetailTable1" rowNumber bordered alwaysEdit keep-source :height="300"
                             :dataSource="detail.safetyEquipmentCheckList"
                             :columns="detail.safetyEquipmentCheckColumns">
                  <template v-slot:safetyEquipmentCheckResult="props">
                    <j-dict-select-tag v-model="props.row.safetyEquipmentCheckResult" :disabled="disableSubmit"
                                       placeholder="请选择检查结果"
                                       @change="$refs['editableDetailTable'+activeTabKey].validateTable()"
                                       dictCode="yes_no_none" style="width: 100%"/>
                  </template>
                </j-vxe-table>
                <a-tabs v-if="model.safetyCheckCompleted">
                  <a-tab-pane tab="维修室主任确认">
                    <a-row>
                      <a-col :span="24">
                        <a-form-model-item prop="safetyCheckConfirmResult" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认类型">
                          <j-dict-select-tag type='radio' v-model='model.safetyCheckConfirmResult'
                                             dictCode='approved_rejected'
                                             placeholder="请选择确认类型"/>
                        </a-form-model-item>
                      </a-col>
                      <a-col :span="24">
                        <a-form-model-item prop="safetyCheckConfirmComment" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认意见">
                          <a-textarea placeholder="请输入意见" v-model="model.safetyCheckConfirmComment"/>
                        </a-form-model-item>
                      </a-col>
                    </a-row>
                  </a-tab-pane>
                </a-tabs>
              </a-tab-pane>
              <a-tab-pane :key="2" tab="设备精度检查" forceRender
                          v-if="selectShenpiData.taskDefKey&&selectShenpiData.taskDefKey=='equipment_precision_check'||!Boolean(selectShenpiData.taskDefKey)">
                <j-vxe-table ref="editableDetailTable2" rowNumber bordered
                             alwaysEdit keep-source :height="300"
                             :dataSource="detail.precisionCheckList" :columns="detail.precisionCheckColumns">
                  <template v-slot:precisionCheckResult="props">
                    <a-input-number v-model="props.row.precisionCheckResult" :disabled="disableSubmit"
                                    @blur="$refs['editableDetailTable'+activeTabKey].validateTable()"
                                    placeholder="请输入检查结果" style="width: 100%"/>
                  </template>
                </j-vxe-table>
                <a-tabs v-if="model.precisionCheckCompleted">
                  <a-tab-pane tab="维修室主任确认">
                    <a-row>
                      <a-col :span="24">
                        <a-form-model-item prop="precisionCheckConfirmResult" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认类型">
                          <j-dict-select-tag type='radio' v-model='model.precisionCheckConfirmResult'
                                             dictCode='approved_rejected'
                                             placeholder="请选择确认类型"/>
                        </a-form-model-item>
                      </a-col>
                      <a-col :span="24">
                        <a-form-model-item prop="precisionCheckConfirmComment" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认意见">
                          <a-textarea placeholder="请输入意见" v-model="model.precisionCheckConfirmComment"/>
                        </a-form-model-item>
                      </a-col>
                    </a-row>
                  </a-tab-pane>
                </a-tabs>
              </a-tab-pane>
              <a-tab-pane :key="3" tab="其他检查" forceRender
                          v-if="selectShenpiData.taskDefKey&&selectShenpiData.taskDefKey=='other_check'||!Boolean(selectShenpiData.taskDefKey)">
                <j-vxe-table ref="editableDetailTable3" rowNumber bordered
                             alwaysEdit keep-source :height="300"
                             :dataSource="detail.otherCheckList" :columns="detail.otherCheckColumns">
                  <template v-slot:otherCheckResult="props">
                    <a-textarea v-model="props.row.otherCheckResult" :rows="1" :disabled="disableSubmit"
                                @blur="$refs['editableDetailTable'+activeTabKey].validateTable()"
                                placeholder="请输入检查结果"
                                :autoSize="false"/>
                  </template>
                </j-vxe-table>
                <a-tabs v-if="model.otherCheckCompleted">
                  <a-tab-pane tab="维修室主任确认">
                    <a-row>
                      <a-col :span="24">
                        <a-form-model-item prop="otherCheckConfirmResult" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认类型">
                          <j-dict-select-tag type='radio' v-model='model.otherCheckConfirmResult'
                                             dictCode='approved_rejected'
                                             placeholder="请选择确认类型"/>
                        </a-form-model-item>
                      </a-col>
                      <a-col :span="24">
                        <a-form-model-item prop="otherCheckConfirmComment" :labelCol="labelColLong"
                                           :wrapperCol="wrapperColLong" label="确认意见">
                          <a-textarea placeholder="请输入意见" v-model="model.otherCheckConfirmComment"/>
                        </a-form-model-item>
                      </a-col>
                    </a-row>
                  </a-tab-pane>
                </a-tabs>
              </a-tab-pane>
              <template v-if="selectShenpiData.procInstId">
                <a-tab-pane key='4' tab='流程图'>
                  <img :src="imageSrc" alt="Fetched Image"/>
                </a-tab-pane>
              </template>
            </a-tabs>
          </a-col>
          <a-col :span="6" v-if="model.evaluationStatus&&model.evaluationStatus!='UNDER_EVALUATION'">
            <a-tabs>
              <a-tab-pane tab="维修工确认">
                <a-row>
                  <a-col :span="24">
                    <a-form-model-item prop="confirmDealType" label="安全装置是否齐全" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.safetyEquipmentCheckResult' dictCode='yn'
                                         :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="confirmDealType" label="设备功能是否齐全" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.precisionCheckResult' dictCode='yn'
                                         placeholder="请选择确认类型" :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="confirmDealType" label="精度是否达到要求" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.functionalCheckResult' dictCode='yes_no_none'
                                         placeholder="请选择确认类型" :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="confirmDealType" label="检查是否合格" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.otherCheckResult' dictCode='yes_no_none'
                                         placeholder="请选择确认类型" :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
              </a-tab-pane>
            </a-tabs>
            <a-tabs>
              <a-tab-pane tab="维修室主任确认">
                <a-row>
                  <a-col :span="24">
                    <a-form-model-item prop="repairManagerSignatureResult" label="确认类型" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.repairManagerSignatureResult'
                                         dictCode='approved_rejected'
                                         placeholder="请选择确认类型" :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="repairManagerComment" label="确认意见" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <a-textarea placeholder="请输入意见" v-model="model.repairManagerComment"
                                  :disabled="disableSubmit || completionDisable"/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
              </a-tab-pane>
            </a-tabs>
            <a-tabs>
              <a-tab-pane tab="工艺员确认">
                <a-row>
                  <a-col :span="24">
                    <a-form-model-item prop="sampleCheckResult" label="试件检查结果" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.sampleCheckResult' dictCode='yn'
                                         :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="processTechnicianComment" label="确认意见" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <a-textarea placeholder="请输入意见" v-model="model.processTechnicianComment"
                                  :disabled="disableSubmit || completionDisable"/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
              </a-tab-pane>
            </a-tabs>
            <a-tabs>
              <a-tab-pane tab="使用单位技术主管确认">
                <a-row>
                  <a-col :span="24">
                    <a-form-model-item prop="departTechnicalLeaderSignatureResult" label="确认类型"
                                       :labelCol="rightColLabelCol" :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.departTechnicalLeaderSignatureResult'
                                         dictCode='approved_rejected'
                                         :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="departTechnicalLeaderComment" label="确认意见" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <a-textarea placeholder="请输入意见" v-model="model.departTechnicalLeaderComment"
                                  :disabled="disableSubmit || completionDisable"/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
              </a-tab-pane>
            </a-tabs>
            <a-tabs>
              <a-tab-pane tab="设备检验员确认">
                <a-row>
                  <a-col :span="24">
                    <a-form-model-item prop="evaluationResult" label="鉴定结果" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-dict-select-tag type='radio' v-model='model.evaluationResult'
                                         dictCode='equipment_technology_status'
                                         placeholder="请选择确认类型" :disabled="disableSubmit || inspectorConfirmDisable"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="evaluationReason" label="限/禁用原因" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <j-select-multiple v-model='model.evaluationReason'
                                         dictCode='technical_status_evaluation_result_reason'
                                         placeholder="请选择限/禁用原因"/>
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="24">
                    <a-form-model-item prop="inspectorComment" label="确认意见" :labelCol="rightColLabelCol"
                                       :wrapperCol="rightColWrapperCol">
                      <a-textarea placeholder="请输入意见" v-model="model.inspectorComment"
                                  :disabled="disableSubmit || completionDisable"/>
                    </a-form-model-item>
                  </a-col>
                </a-row>
              </a-tab-pane>
            </a-tabs>
          </a-col>
        </a-row>
      </a-form-model>
    </a-spin>
  </j-modal>
</template>
<script>
  import { downFile, getAction, httpAction } from '@/api/manage'
  import { JVxeTableModelMixin } from '@/mixins/JVxeTableModelMixin.js'
  import { JVXETypes } from '@comp/jeecg/JVxeTable'
  import MaintenanceEquipmentSelect from '@views/eam/equipment/modules/MaintenanceEquipmentSelect'
  import TechnicalStatusEquipmentSelect from '../../../eam/equipment/modules/TechnicalStatusEquipmentSelect'
  export default {
    name: 'TechnicalStatusEvaluationApprovalModal',
    mixins: [JVxeTableModelMixin],
    components: {
      TechnicalStatusEquipmentSelect,
      MaintenanceEquipmentSelect
    },
    props: {
      selectShenpiData: {
        type: Object
      }
    },
    data() {
      return {
        title: '操作',
        visible: false,
        model: {},
        labelCol: {
          xs: { span: 24 },
          sm: { span: 8 }
        },
        wrapperCol: {
          xs: { span: 24 },
          sm: { span: 16 }
        },
        labelColLong: {
          xs: { span: 24 },
          sm: { span: 4 }
        },
        wrapperColLong: {
          xs: { span: 24 },
          sm: { span: 20 }
        },
        rightColLabelCol: {
          xs: { span: 24 },
          sm: { span: 9 }
        },
        rightColWrapperCol: {
          xs: { span: 24 },
          sm: { span: 15 }
        },
        confirmLoading: false,
        spinning: false,
        imageSrc: null,
        activeTabKey: 1,
        validatorRules: {
          confirmDealType: [
            { required: true, message: '请选择通过或驳回!' }
          ],
          confirmComment: [
            { required: true, message: '请输入确认意见!' }
          ],
          leaderConfirmComment: [
            { required: true, message: '请输入初验收意见!' }
          ]
        },
        url: {
          queryById: '/eam/eamTechnicalStatusEvaluationOrder/queryById',
          detail: '/eam/eamTechnicalStatusEvaluationOrderDetail/queryList',
          approval: '/eam/eamTechnicalStatusEvaluationOrder/approval',
          diagramView: '/assign/flow/diagramView'
        },
        disableSubmit: false,
        selectedRowKeys: [],
        detail: {
          safetyEquipmentCheckList: [],
          precisionCheckList: [],
          otherCheckList: [],
          safetyEquipmentCheckColumns: [
            {
              title: 'ID',
              key: 'id',
              type: JVXETypes.hidden
            },
            {
              title: 'standardId',
              key: 'standardId',
              type: JVXETypes.hidden
            },
            {
              title: '序号',
              key: 'itemCode',
              type: JVXETypes.normal,
              align: 'center',
              width: 60
            },
            {
              title: '检查项目',
              key: 'itemName',
              type: JVXETypes.normal,
              align: 'center'
            },
            {
              title: '检查结果',
              key: 'safetyEquipmentCheckResult',
              type: JVXETypes.slot,
              slotName: 'safetyEquipmentCheckResult',
              validateRules: [{ handler: this.customValidate }],
              align: 'center'
            }
          ],
          precisionCheckColumns: [
            {
              title: 'ID',
              key: 'id',
              type: JVXETypes.hidden
            },
            {
              title: 'standardId',
              key: 'standardId',
              type: JVXETypes.hidden
            },
            {
              title: '序号',
              key: 'itemCode',
              type: JVXETypes.normal,
              align: 'center',
              width: 60
            },
            {
              title: '检查项目',
              key: 'itemName',
              type: JVXETypes.normal,
              align: 'center'
            },
            {
              title: '检查子项目',
              key: 'subItemName',
              type: JVXETypes.normal,
              align: 'center'
            },
            {
              title: '允差值',
              key: 'toleranceValue',
              type: JVXETypes.normal,
              align: 'center'
            },
            {
              title: '检查结果',
              key: 'precisionCheckResult',
              type: JVXETypes.slot,
              slotName: 'precisionCheckResult',
              align: 'center',
              validateRules: [{ handler: this.customValidate }]
            }
          ],
          otherCheckColumns: [
            {
              title: 'ID',
              key: 'id',
              type: JVXETypes.hidden
            },
            {
              title: 'standardId',
              key: 'standardId',
              type: JVXETypes.hidden
            },
            {
              title: '序号',
              key: 'itemCode',
              type: JVXETypes.normal,
              align: 'center',
              width: 60
            },
            {
              title: '检查项目',
              key: 'itemName',
              type: JVXETypes.normal,
              align: 'center'
            },
            {
              title: '检查结果',
              key: 'otherCheckResult',
              type: JVXETypes.slot,
              slotName: 'otherCheckResult',
              align: 'center',
              validateRules: [{ handler: this.customValidate }]
            }
          ]
        }
      }
    },
    computed: {
      confirmDisable: function() {
        return ['WAIT_ADMIN_CONFIRM', 'WAIT_INSPECTOR_CONFIRM', 'COMPLETE'].includes(this.model.maintenanceStatus)
      },
      inspectorConfirmDisable: function() {
        return ['WAIT_INSPECTOR_CONFIRM', 'COMPLETE'].includes(this.model.maintenanceStatus)
      },
      completionDisable: function() {
        return ['COMPLETE'].includes(this.model.maintenanceStatus)
      }
    },
    methods: {
      /**
       * ä¸»é¡µé¢ç‚¹å‡»æ‰§è¡Œå®¡æ‰¹æ—¶è§¦å‘
       * @param record ä¸»é¡µé¢åˆ—表行记录
       */
      async handleDetail(record) {
        this.initParams()
        this.getFlowChartImageByApi(record)
        let res = await getAction(this.url.queryById, { id: record.dataId })
        this.model = Object.assign({}, res.result)
        this.model.dataId = record.dataId
        this.model.taskId = record.id
        this.model.userId = record.assignee
        this.model.instanceId = record.procInstId
        this.loadDetail(record.dataId)
      },
      /**
       * ä¸»é¡µé¢ç‚¹å‡»è¯¦æƒ…时触发
       * @param record ä¸»é¡µé¢åˆ—表行记录
       */
      recordDetail(record) {
        this.initParams()
        this.model = Object.assign({}, record)
        this.loadDetail(record.id)
      },
      /**
       * èŽ·å–æµç¨‹å›¾
       * @param record ä¸»é¡µé¢åˆ—表行记录
       */
      getFlowChartImageByApi(record) {
        const { processDefinitionId, processInstanceId, processDefinitionKey } = record
        downFile(this.url.diagramView, {
          processDefinitionId,
          processInstanceId,
          TaskDefinitionKey: processDefinitionKey
        }, 'get')
          .then((res => {
            this.imageSrc = window.URL.createObjectURL(new Blob([res]))
          }))
          .catch(err => {
            this.$notification.error({
              message: '消息',
              description: res.message
            })
          })
      },
      async handleOk() {
        const that = this
        let errMap
        if (that.$refs['editableDetailTable' + this.activeTabKey]) {
          // æ ¡éªŒå½“前tab表格
          errMap = await that.$refs['editableDetailTable' + this.activeTabKey].validateTable()
        } else {
          // å½“前tab不是表格时则校验有表格的
          for (let index = 1; index <= 3; index++) {
            if (that.$refs['editableDetailTable' + index]) {
              errMap = await that.$refs['editableDetailTable' + index].validateTable()
              if (errMap) {
                that.activeTabKey = index
                that.$refs['editableDetailTable' + this.activeTabKey].clearValidate()
                that.$notification.warning({
                  message: '消息',
                  description: '检查结果不能为空'
                })
                break
              }
            }
          }
        }
        if (errMap) return
        // è§¦å‘表单验证
        this.$refs.form.validate(valid => {
          if (valid) {
            that.confirmLoading = that.spinning = true
            for (let index = 1; index <= 3; index++) {
              if (that.$refs['editableDetailTable' + index]) {
                this.model.tableDetailList = that.$refs['editableDetailTable' + index].getTableData()
                break
              }
            }
            console.log('model', this.model.tableDetailList)
            httpAction(this.url.approval, this.model, 'put')
              .then((res) => {
                if (res.success) {
                  that.$notification.success({
                    message: '消息',
                    description: res.message
                  })
                  that.$emit('modalFormOk')
                  that.close()
                } else {
                  that.$notification.warning({
                    message: '消息',
                    description: res.message
                  })
                }
              })
              .finally(() => {
                that.confirmLoading = that.spinning = false
              })
          } else {
            return false
          }
        })
      },
      autocompleteForm(selectObj) {
        this.$set(this.model, 'standardName', selectObj.standardName)
        this.$set(this.model, 'standardId', selectObj.id)
        this.$set(this.model, 'equipmentId', selectObj.equipmentId)
      },
      //规范选择变化
      loadDetail(orderId) {
        getAction(this.url.detail, { orderId })
          .then(res => {
            if (res.success) {
              this.detail.safetyEquipmentCheckList = res.result.filter(item => item.checkCategory == 'SAFETY_EQUIPMENT_CHECK')
              this.detail.precisionCheckList = res.result.filter(item => item.checkCategory == 'PRECISION_CHECK')
              this.detail.otherCheckList = res.result.filter(item => item.checkCategory == 'OTHER_CHECK')
            }
          })
          .finally(() => {
            this.spinning = false
          })
      },
      // åˆå§‹åŒ–数据
      initParams() {
        this.model = {}
        this.detail.safetyEquipmentCheckList = this.detail.precisionCheckList = this.detail.otherCheckList = []
        this.visible = true
        this.spinning = true
        this.$nextTick(() => {
          for (let index = 1; index <= 3; index++) {
            if (this.$refs['editableDetailTable' + index]) {
              this.activeTabKey = index
              return
            }
          }
        })
      },
      /**
       * æ£€æŸ¥æ˜Žç»†æ ‡ç­¾åˆ‡æ¢æ—¶è§¦å‘
       * @param tabKey åˆ‡æ¢åŽçš„tabKey
       */
      handleTabChange(tabKey) {
        if (this.$refs['editableDetailTable' + this.activeTabKey]) this.$refs['editableDetailTable' + this.activeTabKey].clearValidate()
        this.activeTabKey = tabKey
      },
      /**
       * è‡ªå®šä¹‰è¡¨æ ¼å•元格校验
       * @param cellValue å•元格值
       * @param callback ç»“果回调函数
       */
      customValidate({ cellValue }, callback) {
        if (cellValue) {
          callback(true)
        } else {
          callback(false, '${title}不能为空')
        }
      },
      handleCancel() {
        this.close()
      },
      close() {
        this.$emit('close')
        this.visible = false
        this.$refs.form.clearValidate()
      }
    }
  }
</script>
<style scoped>
  /deep/ .ant-select-dropdown-menu {
    text-align: left;
  }
</style>
src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue
@@ -15,7 +15,7 @@
                    </a-form-model-item>
                  </a-col>
                  <a-col :span="12">
                    <a-form-model-item label="设备编码">
                    <a-form-model-item label="统一编码">
                      <maintenance-equipment-select v-model="model.equipmentId" maintenanceCategory="SECOND_MAINTENANCE"
                                                    @autocompleteForm="autocompleteForm" disabled/>
                    </a-form-model-item>