zhangherong
2025-04-23 d18aac028272ad8c9173a1c180553b6871e70693
art: 设备管理-点检-点检前端问题修改
已修改1个文件
46 ■■■■■ 文件已修改
src/views/flowable/workflow/InspectionOrder/InspectionOrderHandle.vue 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/flowable/workflow/InspectionOrder/InspectionOrderHandle.vue
@@ -62,7 +62,7 @@
          </a-col>
          <a-col :span='span'>
            <a-form-model-item label="点检人">
              <a-input v-model="tableRowRecord.operator" readOnly/>
              <a-input v-model="tableRowRecord.operator_dictText" readOnly/>
            </a-form-model-item>
          </a-col>
        </a-row>
@@ -236,10 +236,12 @@
        visible: false,
        // 表头
        url: {
          queryBomDataById: '/eam/eamInspectionOrder/selectVoById',
          // queryBomDataById: '/eam/eamInspectionOrder/selectVoById',
          diagramView: '/assign/flow/diagramView',
          queryHisTaskList: '/assign/flow/queryHisTaskList',
          approve: '/eam/eamInspectionOrder/approval'
          approve: '/eam/eamInspectionOrder/approval',
          queryById: '/eam/eamInspectionOrder/queryById',
          detailList: '/eam/eamInspectionOrderDetail/queryList'
        },
        detail: {
          loading: false,
@@ -356,22 +358,19 @@
       * 获取待办记录的基本信息
       * @param record 待办记录信息
       */
      getBasicInformation(record) {
      async getBasicInformation(record) {
        this.activeTabKey = '1'
        this.tableRowRecord = {}
        this.detail.dataSource = []
        this.spinning = true
        const param = { id: record.dataId }
        const that = this
        getAction(this.url.queryBomDataById, param)
          .then((res => {
            if (res.success) {
              that.tableRowRecord = { ... res.result[0], fileList: JSON.parse(res.result[0].imageFiles) }
              if (!this.hasInspectionDateArrived && !this.disableSubmit) this.title += `(未到点检日期不能提前点检)`
              that.detail.dataSource = res.result[0].tableDetailList
              console.log('that.tableRowRecord----->', that.tableRowRecord)
            }
          }))
        let res = await getAction(this.url.queryById, param);
        this.tableRowRecord = Object.assign({}, res.result);
        debugger
        if (this.tableRowRecord.imageFiles) {
          let obj = JSON.parse(this.tableRowRecord.imageFiles)
          this.tableRowRecord.fileList = [...obj]
        }
        await this.loadDetail(record.dataId)
      },
      async submitForm() {
@@ -420,7 +419,6 @@
        this.$set(this.tableRowRecord, 'standardName', standardName)
        this.$set(this.tableRowRecord, 'maintenancePeriod', maintenancePeriod)
        this.$set(this.tableRowRecord, 'standardCode', standardCode)
        this.spinning = false
      },
      // 批量选择所有点检结果
@@ -470,7 +468,21 @@
      handleCancel() {
        this.selectedRowKeys = []
        this.visible = false
      }
      },
      //标准选择变化
      loadDetail(orderId) {
        if (orderId) {
          getAction(this.url.detailList, { orderId: orderId })
            .then(res => {
              if (res.success) {
                this.detail.dataSource = [...res.result]
              }
            })
            .finally(() => {
              this.spinning = false
            })
        }
      },
    }
  }
</script>