fix:玻纤日志详情时输入物料不查询qct,输入物料添加下拉选择
This commit is contained in:
parent
0564c5f6da
commit
3382a2c876
|
|
@ -552,26 +552,10 @@ export default {
|
||||||
that.handle_date=that.mlogItem.handle_date;
|
that.handle_date=that.mlogItem.handle_date;
|
||||||
that.handle_user = that.mlogItem.handle_user;
|
that.handle_user = that.mlogItem.handle_user;
|
||||||
that.dialog.check_single = true;
|
that.dialog.check_single = true;
|
||||||
if(row.qct==null&&!that.mlogItem.is_fix){
|
that.qct = row.qct;
|
||||||
that.$API.qm.qct.list.req({qctmat__material:row.material_out,page:0}).then((res)=>{
|
that.$nextTick(() => {
|
||||||
if(res.length>0){
|
that.$refs.checkDialogSingle.open(type,that.qct);
|
||||||
that.qct = res[0].id;
|
});
|
||||||
console.log('that.qct',that.qct);
|
|
||||||
that.$nextTick(() => {
|
|
||||||
that.$refs.checkDialogSingle.open(type,that.qct);
|
|
||||||
});
|
|
||||||
}else{
|
|
||||||
that.$nextTick(() => {
|
|
||||||
that.$refs.checkDialogSingle.open(type);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.qct = row.qct;
|
|
||||||
that.$nextTick(() => {
|
|
||||||
that.$refs.checkDialogSingle.open(type,that.qct);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//表单提交方法
|
//表单提交方法
|
||||||
mlogSubmit() {
|
mlogSubmit() {
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,24 @@
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="批次号" required>
|
<el-form-item label="批次选择">
|
||||||
|
<el-select
|
||||||
|
v-model="batchs"
|
||||||
|
placeholder="批次选择"
|
||||||
|
clearable
|
||||||
|
style="width: 100%"
|
||||||
|
@change="changeMaterial"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in materialOptions"
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.batch"
|
||||||
|
:value="item.id"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="物料扫码">
|
||||||
<el-input ref="codeInput" v-model="wm_in" clearable @change="formWminChange(wm_in)"></el-input>
|
<el-input ref="codeInput" v-model="wm_in" clearable @change="formWminChange(wm_in)"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="使用数量" prop="count_use">
|
<el-form-item label="使用数量" prop="count_use">
|
||||||
|
|
@ -106,6 +123,7 @@ export default {
|
||||||
emits: ["success", "closed"],
|
emits: ["success", "closed"],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
batchs:"",
|
||||||
loading: false,
|
loading: false,
|
||||||
mode: "add",
|
mode: "add",
|
||||||
titleMap: {
|
titleMap: {
|
||||||
|
|
@ -213,6 +231,16 @@ export default {
|
||||||
that.materialOptions = res;
|
that.materialOptions = res;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
changeMaterial(){
|
||||||
|
let that = this;
|
||||||
|
that.materialOptions.forEach(item=>{
|
||||||
|
if(item.id == that.batchs){
|
||||||
|
that.form.batch = item.batch;
|
||||||
|
that.form.wm_in = item.id;
|
||||||
|
that.form.count_use = item.count_cando;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
//扫描后处理方法
|
//扫描后处理方法
|
||||||
formWminChange(code){
|
formWminChange(code){
|
||||||
let that = this,codeId='',arr=[];
|
let that = this,codeId='',arr=[];
|
||||||
|
|
|
||||||
|
|
@ -452,7 +452,7 @@ export default {
|
||||||
}
|
}
|
||||||
that.$API.mtm.mgroup.item.req(that.mgroup).then((res) => {
|
that.$API.mtm.mgroup.item.req(that.mgroup).then((res) => {
|
||||||
that.process_type=res.process_type;
|
that.process_type=res.process_type;
|
||||||
if(that.mode == 'outs'){//输入
|
if(that.mode == 'outs'&&qct!==''&&qct!==null){//输出
|
||||||
that.getdefects();
|
that.getdefects();
|
||||||
}else{
|
}else{
|
||||||
that.getList();
|
that.getList();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue