fix:日志显示问题以及工艺路线改为工艺步骤

This commit is contained in:
shijing 2025-04-22 09:17:59 +08:00
parent 7bdd81c42b
commit 797d8d5981
5 changed files with 37 additions and 23 deletions

View File

@ -2,7 +2,7 @@
<el-dialog <el-dialog
:title="titleMap[mode]" :title="titleMap[mode]"
v-model="visible" v-model="visible"
:size="1000" style="width: 80%;"
destroy-on-close destroy-on-close
@closed="$emit('closed')" @closed="$emit('closed')"
> >
@ -37,10 +37,10 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :md="12" :sm="24"> <el-col :md="12" :sm="24">
<el-form-item label="工艺路线"> <el-form-item label="工艺步骤">
<el-select <el-select
v-model="form.route" v-model="form.route"
placeholder="工艺路线" placeholder="工艺步骤"
clearable clearable
filterable filterable
style="width: 100%" style="width: 100%"
@ -48,10 +48,9 @@
<el-option <el-option
v-for="item in routeOptions" v-for="item in routeOptions"
:key="item.id" :key="item.id"
:label="item.routepack_name" :label="item.name"
:value="item.id" :value="item.id"
> >
<span>{{ item.routepack_name }}-{{item.process_name}}</span>
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -166,6 +165,9 @@ export default {
.req({ process: that.process, page: 0, routepack__state: 30 }) .req({ process: that.process, page: 0, routepack__state: 30 })
.then((res) => { .then((res) => {
that.routeOptions = res; that.routeOptions = res;
if(res.length==1){
that.form.route = res[0].id;
}
}); });
}, },
// //

View File

@ -332,7 +332,7 @@
:mgroup="mgroup" :mgroup="mgroup"
:is_fix = "is_fix" :is_fix = "is_fix"
:mgroupMtype="mgroupMtype" :mgroupMtype="mgroupMtype"
:mgroupName = "mlogItem.mgroup_name" :mgroupName = "mgroupName"
:codeText = "codeText" :codeText = "codeText"
:materialIn="materialIn" :materialIn="materialIn"
@success="handleSaveSuccess" @success="handleSaveSuccess"
@ -342,6 +342,7 @@
<check-dialog <check-dialog
v-if="dialog.check" v-if="dialog.check"
ref="checkDialog" ref="checkDialog"
:deptId="deptId"
:mgroupMtype="mgroupMtype" :mgroupMtype="mgroupMtype"
@success="handleCheckSuccess" @success="handleCheckSuccess"
@closed="dialog.check = false" @closed="dialog.check = false"
@ -351,7 +352,10 @@
v-if="dialog.edit" v-if="dialog.edit"
ref="editDialog" ref="editDialog"
:dept="deptId" :dept="deptId"
:mgroupName= "mlogItem.mgroup_name" :mgroup="mgroup"
:process="process"
:mgroupMtype="mgroupMtype"
:mgroupName= "mgroupName"
@success="handleEditSuccess" @success="handleEditSuccess"
@closed="dialog.edit = false" @closed="dialog.edit = false"
> >
@ -468,6 +472,10 @@ export default {
mgroupMtype:{ mgroupMtype:{
type: String, type: String,
default: "", default: "",
},
process:{
type: String,
default: "",
} }
}, },
components: { components: {
@ -534,6 +542,7 @@ export default {
cellsList:[], cellsList:[],
qct_defects:[], qct_defects:[],
tableDataWm:[], tableDataWm:[],
mgroupName:'',
test_file:'', test_file:'',
deptId: "", deptId: "",
codeText: "", codeText: "",
@ -582,6 +591,7 @@ export default {
let that = this; let that = this;
that.$API.wpm.mlog.item.req(that.mlogId).then((res) => { that.$API.wpm.mlog.item.req(that.mlogId).then((res) => {
that.mlogItem = res; that.mlogItem = res;
that.mgroupName = res.mgroup_name;
if(res.test_file!==null){ if(res.test_file!==null){
that.fileList = [{name:res.test_file,url:res.test_file}]; that.fileList = [{name:res.test_file,url:res.test_file}];
that.form.test_file = res.test_file; that.form.test_file = res.test_file;

View File

@ -2,8 +2,8 @@
<el-dialog <el-dialog
:title="titleMap[mode]" :title="titleMap[mode]"
v-model="visible" v-model="visible"
:size="1000"
destroy-on-close destroy-on-close
style="width: 80%;"
@closed="$emit('closed')" @closed="$emit('closed')"
> >
<el-container v-loading="loading"> <el-container v-loading="loading">
@ -57,10 +57,10 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :md="12" :sm="24" v-if="mlogtype!=='rework'"> <el-col :md="12" :sm="24" v-if="mlogtype!=='rework'">
<el-form-item label="工艺路线" prop="route"> <el-form-item label="工艺步骤" prop="route">
<el-select <el-select
v-model="form.route" v-model="form.route"
placeholder="工艺路线" placeholder="工艺步骤"
clearable clearable
filterable filterable
style="width: 100%" style="width: 100%"
@ -69,14 +69,9 @@
<el-option <el-option
v-for="item in routeOptions" v-for="item in routeOptions"
:key="item.id" :key="item.id"
:label="item.routepack_name" :label="item.name"
:value="item.id" :value="item.id"
> >
<span
>{{ item.routepack_name }}-{{
item.process_name
}}</span
>
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
@ -129,12 +124,12 @@
/> />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :md="12" :sm="24"> <el-col :md="12" :sm="24" v-if="mode == 'edit'">
<el-form-item label="结束时间" prop="work_end_time"> <el-form-item label="结束时间" prop="work_end_time">
<!-- :disabledDate="disabledDateFn" -->
<el-date-picker <el-date-picker
v-model="form.work_end_time" v-model="form.work_end_time"
type="datetime" type="datetime"
:disabledDate="disabledDateFn"
value-format="YYYY-MM-DD HH:mm:ss" value-format="YYYY-MM-DD HH:mm:ss"
style="width: 100%" style="width: 100%"
/> />
@ -406,6 +401,9 @@ export default {
.req({ process: that.process, page: 0, routepack__state: 30 }) .req({ process: that.process, page: 0, routepack__state: 30 })
.then((res) => { .then((res) => {
that.routeOptions = res; that.routeOptions = res;
if(res.length==1){
that.form.route = res[0].id;
}
}); });
}, },
// //

View File

@ -343,6 +343,7 @@ export default {
let that = this; let that = this;
that.materialOptions.forEach(item => { that.materialOptions.forEach(item => {
if(item.id==that.form.wm_in){ if(item.id==that.form.wm_in){
that.form.batch = item.batch;
that.form.count_use = item.count; that.form.count_use = item.count;
that.batch_count = item.count; that.batch_count = item.count;
} }
@ -414,11 +415,13 @@ export default {
} }
let count_pn_jgqbl = 0,mlogbindefect=[]; let count_pn_jgqbl = 0,mlogbindefect=[];
that.qct_defects.forEach(item => { that.qct_defects.forEach(item => {
count_pn_jgqbl += that.defectinform[item.defect_name] ; if(that.defectinform[item.defect_name]>0){
let obj = {}; count_pn_jgqbl += that.defectinform[item.defect_name] ;
obj.defect = item.defect; let obj = {};
obj.count = that.defectinform[item.defect_name]; obj.defect = item.defect;
mlogbindefect.push(obj); obj.count = that.defectinform[item.defect_name];
mlogbindefect.push(obj);
}
}) })
that.form.mlogbindefect = mlogbindefect; that.form.mlogbindefect = mlogbindefect;
that.form.count_pn_jgqbl = count_pn_jgqbl; that.form.count_pn_jgqbl = count_pn_jgqbl;

View File

@ -182,6 +182,7 @@
ref="detailDialog" ref="detailDialog"
:mlogId="mlogId" :mlogId="mlogId"
:mtask="mtask" :mtask="mtask"
:process="processId"
:mgroupMtype="mgroupMtype" :mgroupMtype="mgroupMtype"
@closed="detailClose" @closed="detailClose"
> >