Browse Source

2023-12-14 IQC检验任务增加“任务重载”按钮

java8
fengyuan_yang 2 years ago
parent
commit
07b0bd8480
  1. 1
      src/api/qc/qc.js
  2. 44
      src/views/modules/qc/IQCResultEntry.vue

1
src/api/qc/qc.js

@ -155,6 +155,7 @@ export const iqcRecordDelete = data => createAPI(`/pms/qc/iqcRecordDelete`,'post
export const disposalMeasuresSearch = data => createAPI(`/pms/qc/disposalMeasuresSearch`,'post',data) export const disposalMeasuresSearch = data => createAPI(`/pms/qc/disposalMeasuresSearch`,'post',data)
export const searchItemFileUrl = data => createAPI(`/pms/qc/searchItemFileUrl`,'post',data) export const searchItemFileUrl = data => createAPI(`/pms/qc/searchItemFileUrl`,'post',data)
export const imageDelete = data => createAPI(`/pms/qc/imageDelete`,'post',data) export const imageDelete = data => createAPI(`/pms/qc/imageDelete`,'post',data)
export const iqcRecordOverLoad = data => createAPI(`/pms/qc/iqcRecordOverLoad`,'post',data)

44
src/views/modules/qc/IQCResultEntry.vue

@ -62,6 +62,7 @@
<el-button type="primary" @click="getDataList()">查询</el-button> <el-button type="primary" @click="getDataList()">查询</el-button>
<el-button type="primary" @click="submitResult()">审核</el-button> <el-button type="primary" @click="submitResult()">审核</el-button>
<el-button type="primary" @click="deleteModal()">删除</el-button> <el-button type="primary" @click="deleteModal()">删除</el-button>
<el-button type="primary" @click="overLoadModal()">任务重载</el-button>
<download-excel <download-excel
:fields="fields()" :fields="fields()"
:data="exportData" :data="exportData"
@ -460,7 +461,8 @@
saveIQCSubDetailed, // saveIQCSubDetailed, //
saveIQCSubmitResult, // saveIQCSubmitResult, //
iqcRecordDelete, // iqcRecordDelete, //
disposalMeasuresSearch //
disposalMeasuresSearch, //
iqcRecordOverLoad, //
} from "@/api/qc/qc.js" } from "@/api/qc/qc.js"
import { import {
getTableDefaultListLanguage, getTableDefaultListLanguage,
@ -1603,6 +1605,46 @@
}).catch(() => { }).catch(() => {
}) })
}, },
//
overLoadModal () {
if (this.IQCSelections.length === 0) {
this.$message.warning('请勾选要重载的检验单!')
return
}
if (this.IQCSelections.every(val => val.state === '待检验')) {
this.$confirm(`是否重载该 `+ this.IQCSelections.length +` 条检验单?`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let tempData = {
site: this.$store.state.user.site,
submitList: this.IQCSelections
}
iqcRecordOverLoad(tempData).then(({data}) => {
if (data && data.code === 0) {
this.getDataList()
this.IQCSelections = []
this.$message({
message: '操作成功',
type: 'success',
duration: 1500,
onClose: () => {}
})
} else {
this.$alert(data.msg, '错误', {
confirmButtonText: '确定'
})
}
})
}).catch(() => {
})
} else {
this.$message.warning('检验单必须为待检验状态!')
return
}
},
// //
submitResult(){ submitResult(){
let tempData1 = '' // let tempData1 = '' //

Loading…
Cancel
Save