fix:禅道130131

This commit is contained in:
shijing 2025-10-20 14:54:02 +08:00
parent 73d96c57da
commit 1ce40eed02
2 changed files with 38 additions and 55 deletions

View File

@ -93,7 +93,7 @@
min-width="150"
>
<template #default="scope">
<span v-if="route_code=='kaitaijie'" @click="rowClick(scope.row)" style="color:#0052d9;font-weight: 600;cursor: pointer;">{{scope.row.batch}}</span>
<span v-if="route_code=='pengma'" @click="rowClick(scope.row)" style="color:#0052d9;font-weight: 600;cursor: pointer;">{{scope.row.batch}}</span>
<span v-else>{{scope.row.batch}}</span>
</template>
</el-table-column>

View File

@ -113,18 +113,18 @@
>
<el-row>
<el-col :span="23">
<el-form-item label="操作日期" required>
<el-form-item label="操作时间" prop="work_start_time">
<el-date-picker
v-model="muserForm.handle_date"
type="date"
placeholder="操作日期"
value-format="YYYY-MM-DD"
v-model="muserForm.work_start_time"
type="datetime"
placeholder="操作时间"
value-format="YYYY-MM-DD HH:mm:ss"
style="width: 100%"
></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="23">
<el-form-item label="操作人" required>
<el-form-item label="操作人" prop="handle_user">
<ehsSelect
v-model="muserForm.handle_user"
:showName="muserForm.handle_user_name"
@ -150,7 +150,7 @@
</el-select>
</el-form-item>
</el-col>
<el-col :span="23">
<!-- <el-col :span="23">
<el-form-item label="关联班次" prop="shift">
<el-select
v-model="muserForm.shift"
@ -166,6 +166,23 @@
</el-option>
</el-select>
</el-form-item>
</el-col> -->
<el-col :span="23">
<el-form-item label="使用设备" prop="equipment">
<el-select
v-model="muserForm.equipment"
placeholder="设备"
class="width-100"
>
<el-option
v-for="item in equipmentOtions"
:key="item.id"
:label="item.name"
:value="item.id"
>
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-form>
@ -509,6 +526,7 @@ export default {
shiftOtions:[],
tableDataWm:[],
qct_defects:[],
equipmentOtions:[],
defectOptions:[],
qct_testitems:[],
processOptions:[],
@ -528,6 +546,10 @@ export default {
count_use: [{required: true,message: "请输入领取数量",trigger: "blur"}],
process:[{required: true,message: "请选择工序",trigger: "blur"}],
shift:[{required: true,message: "请选择班次",trigger: "blur"}],
work_start_time:[{required: true,message: "请选择开始时间",trigger: "blur"}],
handle_user:[{required: true,message: "请选择操作人",trigger: "blur"}],
process:[{required: true,message: "请选择子工序",trigger: "blur"}],
equipment:[{required: true,message: "请选择设备",trigger: "blur"}],
},
route_file:null,
handle_date:'',
@ -571,6 +593,7 @@ export default {
that.getMlogItem();
that.getPreocess();
that.getShift();
that.getEquipment();
},
methods: {
open() {
@ -615,6 +638,12 @@ export default {
})
});
},
getEquipment(){
let that = this;
that.$API.em.equipment.list.req({page:0,belong_dept:that.dept}).then((res) => {
that.equipmentOtions = res;
})
},
//
getcutCount(material_id){
let that = this;
@ -640,52 +669,6 @@ export default {
that.shiftOtions = res;
});
},
// getdefects(qct){
// let that = this;
// if(qct!==''&&qct!==null){//
// that.$API.qm.qct.item.req(qct).then((res) => {
// that.qct_defects = [];
// that.testdefectss(res);
// })
// }else{
// that.$API.qm.qct.getQct.req({ material: that.mlogItem.material_out,type:'out',tag:'process' }).then((res) => {
// that.testdefectss(res);
// }).catch(()=>{
// // that.getList();
// })
// }
// },
// testdefectss(res){
// let that = this;
// res.qct_defects.forEach((item) => {
// that.addTemplate[item.defect_name] = false;
// let obj = Object.assign({}, item);
// that.qct_defects.push(obj);
// })
// that.qct_defects_origin = that.qct_defects;
// that.qct_testitems = [];
// res.qct_testitems.forEach((item2) => {
// if(item2.testitem_type!=='20'){
// let obj2 = Object.assign({}, item2);
// obj2.value = '';
// obj2.addto_wpr = item2.addto_wpr;
// if(item2.testitem_field_type=='input-number'||item2.testitem_field_type=='input-int'){
// obj2.value = null;
// that.addTemplate[item2.testitem_name] = null;
// }
// if(item2.testitem_field_type=='select-text'||item2.testitem_field_type=='selects-text'){
// let str = obj2.testitem_choices.replace(/'/g, '"');
// let arr = JSON.parse(str);
// obj2.testitem_choices = arr;
// that.addTemplate[item2.testitem_name] = null;
// }
// that.qct_testitems.push(obj2);
// }
// })
// that.qct_testitems_origin = that.qct_testitems;
// // that.getList();
// },
//mlogbw
getMlogbw(){
let that = this;
let params = {};
@ -939,7 +922,7 @@ export default {
that.muserForm.mlog = that.mlogItem.id;
that.muserForm.handle_user = userInfo.id;
that.muserForm.handle_user_name = userInfo.name;
that.muserForm.handle_date = this.$TOOL.dateFormat2(new Date());
that.muserForm.work_start_time = this.$TOOL.dateFormat(new Date());
that.saveMuserDialog = true;
},
saveMuserSubmit (){