loulijun2021
2024-04-10 213f348eb0e68df4b575a51c570b98f4cf773963
src/views/produce/reportVerify.vue
@@ -295,10 +295,18 @@
            <template slot-scope="{row}">
              <div class="operationClass">
                <el-button
                  v-if="row.verify!=='Y'"
                  type="text"
                  style="cursor: pointer;font-size: 14px"
                  @click="reportAdjust(row)"
                >报工审核
                </el-button>
                <el-button
                  v-if="row.verify==='Y'"
                  type="text"
                  style="cursor: pointer;font-size: 14px;color: rgba(255,0,0,0.8)"
                  @click="reportGiveUp(row)"
                >弃审
                </el-button>
              </div>
@@ -326,7 +334,12 @@
import { handleDatetime } from '@/utils/global'
import elDragDialog from '@/directive/el-drag-dialog'
import waves from '@/directive/waves'
import { MesOrderDistribution, MesOrderStepReportVerifySearch, MesOrderStepReportVerifySeave } from '@/api/WorkOrder'
import {
  MesOrderDistribution,
  MesOrderStepReportNotVerifySeave,
  MesOrderStepReportVerifySearch,
  MesOrderStepReportVerifySeave
} from '@/api/WorkOrder'
import { PrentOrganizationNoCompany } from '@/api/GeneralBasicData'
export default {
@@ -440,9 +453,9 @@
    // 报工审核
    async reportAdjust(row) {
      if (row && row.verify === 'Y') {
        return this.$message.info('此工单已审核!')
      }
      // if (row && row.verify === 'Y') {
      //   return this.$message.info('此工单已审核!')
      // }
      this.$confirm('是否确认审核?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
@@ -472,6 +485,29 @@
        this.$notify.info('已取消审核!')
      })
    },
    // 弃审
    reportGiveUp(row) {
      this.$confirm('是否确认弃审?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        const data = {
          id: row.id,
          steptype: row.steptype
        }
        MesOrderStepReportNotVerifySeave(data).then(res => {
          if (res.code === '200') {
            this.$notify.success('弃审成功!')
            this.getMesOrderStepReportVerifySearch()
          }
        })
      }).catch(() => {
        this.$notify.info('已取消弃审!')
      })
    },
    handleSelectionChange(val) {
      this.multipleSelection = val
    },