parent
0347ff275e
commit
b46e36c873
5 changed files with 124 additions and 99 deletions
@ -1,87 +1,95 @@ |
|||||||
<template> |
<template> |
||||||
<el-dialog title="转派" append-to-body :modelValue="openShow" width="30%" @close="closeDialog"> |
<el-dialog title="转派" append-to-body :modelValue="openShow" width="30%" @close="closeDialog"> |
||||||
|
<el-form ref="form" :model="formData" :rules="rules" label-width="80px" class="vd-form-row"> |
||||||
|
<el-row> |
||||||
|
<el-col :span="24"> |
||||||
|
<el-form-item label="调度员" prop="disAssignMan"> |
||||||
|
<el-select v-model="formData.disAssignMan" placeholder="请选择" clearable filterable> |
||||||
|
<el-option |
||||||
|
v-for="item in options" |
||||||
|
:key="item.id" |
||||||
|
:label="item.realName" |
||||||
|
:value="item.id" |
||||||
|
> |
||||||
|
</el-option> |
||||||
|
</el-select> |
||||||
|
</el-form-item> |
||||||
|
</el-col> |
||||||
|
</el-row> |
||||||
|
<el-row> |
||||||
|
<el-col :span="24"> |
||||||
|
<el-form-item label="处理意见" prop="resolution"> |
||||||
|
<el-input v-model="formData.resolution" type="textarea" /> |
||||||
|
</el-form-item> |
||||||
|
</el-col> |
||||||
|
</el-row> |
||||||
|
</el-form> |
||||||
|
|
||||||
<el-form ref="form" :model="formData" :rules="rules" label-width="80px" class="vd-form-row"> |
<template #footer> |
||||||
<el-row> |
<span class="dialog-footer"> |
||||||
<el-col :span="24"> |
<el-button @click="closeDialog">取 消</el-button> |
||||||
<el-form-item label="调度员" prop="proMan.userId"> |
<el-button type="primary" @click="submit" :loading="saveLoading">确 定</el-button> |
||||||
<!-- <all-user v-model="formData.proMan.userId" /> --> |
</span> |
||||||
<el-select v-model="formData.proMan.userId" placeholder="请选择" clearable filterable> |
</template> |
||||||
<el-option v-for="item in options" :key="item.value" :label="item.label" |
</el-dialog> |
||||||
:value="item.value"> |
|
||||||
</el-option> |
|
||||||
</el-select> |
|
||||||
</el-form-item> |
|
||||||
</el-col> |
|
||||||
</el-row> |
|
||||||
<el-row> |
|
||||||
<el-col :span="24"> |
|
||||||
<el-form-item label="处理意见" prop="resolution"> |
|
||||||
<el-input v-model="formData.resolution" type="textarea" /> |
|
||||||
</el-form-item> |
|
||||||
</el-col> |
|
||||||
</el-row> |
|
||||||
</el-form> |
|
||||||
|
|
||||||
<template #footer> |
|
||||||
<span class="dialog-footer"> |
|
||||||
<el-button @click="closeDialog">取 消</el-button> |
|
||||||
<el-button type="primary" @click="submit">确 定</el-button> |
|
||||||
</span> |
|
||||||
</template> |
|
||||||
</el-dialog> |
|
||||||
</template> |
</template> |
||||||
<script> |
<script> |
||||||
|
import { setDispatch, getRoleUserList } from '@/api/processManagement/taskDispatch'; |
||||||
|
|
||||||
|
import { disTechnician } from '@/api/productionManagement/WIPChange.js'; |
||||||
|
|
||||||
export default { |
export default { |
||||||
props: { |
props: { |
||||||
showDialog: { |
showDialog: { |
||||||
type: Boolean, |
type: Boolean, |
||||||
default: false |
default: false, |
||||||
}, |
|
||||||
}, |
}, |
||||||
data() { |
rowItem: { |
||||||
return { |
type: Object, |
||||||
openShow: false, |
default: () => ({}), |
||||||
formData: { proMan: {}, resolution: null, ddtIdList: [] }, |
|
||||||
rules: { |
|
||||||
'proMan.userId': [{ required: true }] |
|
||||||
}, |
|
||||||
options: [ |
|
||||||
{ |
|
||||||
label: '人员一', |
|
||||||
value: 1 |
|
||||||
}, |
|
||||||
{ |
|
||||||
label: '人员二', |
|
||||||
value: 2 |
|
||||||
} |
|
||||||
] |
|
||||||
} |
|
||||||
}, |
}, |
||||||
mounted() { |
}, |
||||||
this.openShow = this.showDialog |
data() { |
||||||
|
return { |
||||||
|
saveLoading: false, |
||||||
|
openShow: false, |
||||||
|
formData: { disAssignMan: null, resolution: null, ddtIdList: [] }, |
||||||
|
rules: { |
||||||
|
disAssignMan: [{ required: true }], |
||||||
|
}, |
||||||
|
options: [], |
||||||
|
}; |
||||||
|
}, |
||||||
|
mounted() { |
||||||
|
this.openShow = this.showDialog; |
||||||
|
this.getRoleUserList(); |
||||||
|
}, |
||||||
|
methods: { |
||||||
|
getRoleUserList() { |
||||||
|
getRoleUserList({ current: 1, size: 9999999 }).then(res => { |
||||||
|
this.options = res.data.data.records; |
||||||
|
}); |
||||||
}, |
}, |
||||||
methods: { |
submit() { |
||||||
submit() { |
this.$refs.form.validate(valid => { |
||||||
// this.$refs.form.validate((valid) => { |
if (valid) { |
||||||
// if (valid) { |
let query = { |
||||||
// this.formData.assignType = false; |
ddtIdList: [this.rowItem.id], |
||||||
// this.$ajax |
resolution: this.formData.resolution, |
||||||
// .post('dsDisTasking/disTechnician', this.formData) |
disAssignMan: this.formData.disAssignMan, |
||||||
// .then((res) => { |
}; |
||||||
// if (this.$ifAjax(res)) { |
disTechnician(query).then(res => { |
||||||
// this.$message.success(this.$t('craft.alreadyAssign')); |
this.$message.success('操作成功'); |
||||||
// this.cancel(true); |
this.closeDialog(); |
||||||
// } |
}); |
||||||
// }); |
|
||||||
// } |
|
||||||
// }); |
|
||||||
}, |
|
||||||
closeDialog() { |
|
||||||
this.openShow = false |
|
||||||
this.$emit('closeDialog'); |
|
||||||
} |
} |
||||||
} |
}); |
||||||
} |
}, |
||||||
|
closeDialog() { |
||||||
|
this.openShow = false; |
||||||
|
this.$emit('closeDialog'); |
||||||
|
}, |
||||||
|
}, |
||||||
|
}; |
||||||
</script> |
</script> |
||||||
<style lang="scss" scoped></style> |
<style lang="scss" scoped></style> |
||||||
|
|||||||
Loading…
Reference in new issue