update 待确认
This commit is contained in:
@@ -142,12 +142,27 @@ export default {
|
||||
}
|
||||
},
|
||||
|
||||
getConfirmed() {
|
||||
return this.$confirm('是否直接确认保养记录', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
});
|
||||
},
|
||||
|
||||
async dataFormSubmit() {
|
||||
let valid = false;
|
||||
try {
|
||||
valid = await this.$refs.form.validate();
|
||||
} catch (err) {}
|
||||
if (!valid) return;
|
||||
|
||||
let confirmed = false;
|
||||
try {
|
||||
confirmed = await this.getConfirmed();
|
||||
} catch (err) {
|
||||
confirmed = false;
|
||||
}
|
||||
const res = await this.$axios({
|
||||
url:
|
||||
'/base/equipment-check-order' +
|
||||
@@ -156,8 +171,9 @@ export default {
|
||||
data: {
|
||||
...this.dataForm,
|
||||
special: true,
|
||||
status: 1,
|
||||
status: confirmed ? 2 : 1,
|
||||
groupClass: this.dataForm.groupClass.join(','),
|
||||
checkPerson: this.$store.getters.userId,
|
||||
},
|
||||
});
|
||||
if (res.code == 0) {
|
||||
|
||||
Reference in New Issue
Block a user