fix:禅道350

This commit is contained in:
shijing 2026-03-04 10:50:17 +08:00
parent f22632090b
commit 6df332211c
1 changed files with 48 additions and 34 deletions

View File

@ -35,38 +35,38 @@
<table id="mlogbwlist" class="tables"> <table id="mlogbwlist" class="tables">
<thead> <thead>
<tr> <tr>
<th class="w_30 inlineBlock"> <th class="w_50" style="padding: 5px;">
<input type="checkbox" v-model="selectedAll" :value="selectedAll" style="width: 18px;" @change="selectAllChange"> <input type="checkbox" class="checkboxInput" v-model="selectedAll" :value="selectedAll" @change="selectAllChange">
</th> </th>
<th class="w_30 inlineBlock">序号</th> <th class="w_50">序号</th>
<th class="w_140 inlineBlock">物料批次</th> <th class="w_140">物料批次</th>
<th class="w_150 inlineBlock">物料编号</th> <th class="w_150">物料编号</th>
<th class="w_150 inlineBlock" v-if="route_code=='niuzhuan'">生产设备</th> <th class="w_150" v-if="route_code=='niuzhuan'">生产设备</th>
<th class="w_180 inlineBlock" v-if="route_code=='niuzhuan'">扭转日期</th> <th class="w_180" v-if="route_code=='niuzhuan'">扭转日期</th>
<th class="w_80 inlineBlock" v-for="item in qct_testitems" :key="item.id">{{ item.testitem_name }}</th> <th class="w_80" v-for="item in qct_testitems" :key="item.id">{{ item.testitem_name }}</th>
<th class="w_80 inlineBlock" v-for="item in qct_defects" :key="item.id">{{ item.defect_name }}</th> <th class="w_80" v-for="item in qct_defects" :key="item.id">{{ item.defect_name }}</th>
<th class="w_80 inlineBlock">备注</th> <th class="w_80">备注</th>
<th class="w_180 inlineBlock" v-if="!isSubmit">操作</th> <th class="w_180" v-if="!isSubmit">操作</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
<tr v-for="(row, index) in mlogbwlist" :key="row.id"> <tr v-for="(row, index) in mlogbwlist" :key="row.id">
<td class="w_30 inlineBlock padding_4"> <td class="w_50 padding_4" style="text-align: center;">
<input type="checkbox" v-model="selectedindexes" :value="row.id" @change="selectChange"> <input type="checkbox" class="checkboxInput" v-model="selectedindexes" :value="row.id" @change="selectChange">
</td> </td>
<td class="w_30 inlineBlock padding_4"> <td class="w_50 padding_4">
{{ index + 1 }} {{ index + 1 }}
</td> </td>
<td class="w_140 inlineBlock"> <td class="w_140 ">
<input v-if="row.isEdit" v-model="row.mlogb__batch" placeholder="物料批次"> <input v-if="row.isEdit" v-model="row.mlogb__batch" placeholder="物料批次">
<span v-else>{{ row.mlogb__batch }}</span> <span v-else>{{ row.mlogb__batch }}</span>
</td> </td>
<td class="w_150 inlineBlock"> <td class="w_150 ">
<input v-if="row.isEdit" v-model="row.number" placeholder="物料编号"> <input v-if="row.isEdit" v-model="row.number" placeholder="物料编号">
<span v-else>{{ row.number }}</span> <span v-else>{{ row.number }}</span>
<span v-if="row.wpr_number_out !== null && row.wpr_number_out !== undefined">{{ row.wpr_number_out }}</span> <span v-if="row.wpr_number_out !== null && row.wpr_number_out !== undefined">{{ row.wpr_number_out }}</span>
</td> </td>
<td class="w_150 inlineBlock" v-if="route_code=='niuzhuan'"> <td class="w_150 " v-if="route_code=='niuzhuan'">
<select name="pets" id="pet-select" v-if="row.isEdit" style="width: 100%;" v-model="row.equip" :value="row.equip"> <select name="pets" id="pet-select" v-if="row.isEdit" style="width: 100%;" v-model="row.equip" :value="row.equip">
<option v-for="item in optionsEq" :key="item.id" :value="item.id"> <option v-for="item in optionsEq" :key="item.id" :value="item.id">
{{ item.number }} {{ item.number }}
@ -74,13 +74,13 @@
</select> </select>
<span v-else>{{ row.equip_name }}<span v-if="row.equip_number&&row.equip_number!=null">{{ row.equip_number }}</span></span> <span v-else>{{ row.equip_name }}<span v-if="row.equip_number&&row.equip_number!=null">{{ row.equip_number }}</span></span>
</td> </td>
<td class="w_180 inlineBlock" v-if="route_code=='niuzhuan'"> <td class="w_180 " v-if="route_code=='niuzhuan'">
<input v-if="row.isEdit" type="datetime-local" id="datetime" v-model="row.work_start_time" @change = "timeChange(row)"> <input v-if="row.isEdit" type="datetime-local" id="datetime" v-model="row.work_start_time" @change = "timeChange(row)">
<div v-else> <div v-else>
<span v-if="row.work_start_time!==null">{{ row.work_start_time}}</span> <span v-if="row.work_start_time!==null">{{ row.work_start_time}}</span>
</div> </div>
</td> </td>
<td class="w_80 inlineBlock" v-for="item in qct_testitems" :key="item.id"> <td class="w_80 " v-for="item in qct_testitems" :key="item.id">
<span v-if="!row.isEdit || !item.canEdit">{{ row[item.testitem_name] }}</span> <span v-if="!row.isEdit || !item.canEdit">{{ row[item.testitem_name] }}</span>
<input v-if="item.testitem_field_type == 'input-number' && row.isEdit && item.canEdit" <input v-if="item.testitem_field_type == 'input-number' && row.isEdit && item.canEdit"
type="number" v-model="row[item.testitem_name]" @change="defectCountSun(row)"> type="number" v-model="row[item.testitem_name]" @change="defectCountSun(row)">
@ -97,14 +97,14 @@
<option v-for="item0 in item.testitem_choices" :key="item0" :value="item0">{{ item0 }}</option> <option v-for="item0 in item.testitem_choices" :key="item0" :value="item0">{{ item0 }}</option>
</select> </select>
</td> </td>
<td class="w_80 inlineBlock padding_4 defectBlock" v-for="item in qct_defects" :key="item.id"> <td class="w_80 padding_4 defectBlock" v-for="item in qct_defects" :key="item.id">
<input type="checkbox" :disabled="!row.isEdit || !item.canEdit" v-model="row[item.defect_name]" @change="switchChange(row, item,index)"> <input type="checkbox" class="checkboxInput" :disabled="!row.isEdit || !item.canEdit" v-model="row[item.defect_name]" @change="switchChange(row, item,index)">
</td> </td>
<td class="w_80 inlineBlock"> <td class="w_80 ">
<input v-if="row.isEdit" v-model="row.note" placeholder="备注"> <input v-if="row.isEdit" v-model="row.note" placeholder="备注">
<span v-else style="width: 100%;height: 100%;display: inline-block;">{{ row.note }}</span> <span v-else style="width: 100%;height: 100%;display: inline-block;">{{ row.note }}</span>
</td> </td>
<td class="w_180 inlineBlock" v-if="!isSubmit"> <td class="w_180 " v-if="!isSubmit">
<button v-if="row.isEdit" type="button" class="btn btn_green" @click="formTableSave(row,index)">保存</button> <button v-if="row.isEdit" type="button" class="btn btn_green" @click="formTableSave(row,index)">保存</button>
<button v-if="row.isEdit && row.id" type="button" class="btn btn_red" @click="formTableCancel(row,index)">取消</button> <button v-if="row.isEdit && row.id" type="button" class="btn btn_red" @click="formTableCancel(row,index)">取消</button>
<button v-if="row.isEdit && setForm.cd_req_addr !== null" type="button" class="btn btn_yellow" @click="getEqData(index)">重取数据</button> <button v-if="row.isEdit && setForm.cd_req_addr !== null" type="button" class="btn btn_yellow" @click="getEqData(index)">重取数据</button>
@ -1134,21 +1134,33 @@ table {
width: max-content; width: max-content;
} }
table { table {
color: #606266;
border-top: 1px solid #ebeef5; border-top: 1px solid #ebeef5;
border-left: 1px solid #ebeef5; border-left: 1px solid #ebeef5;
} }
tbody tr:nth-child(odd) {
background-color: #f5f7fa;
}
tr{
min-height: 40px;
}
td { td {
height: 25px; padding: 5px;
min-height: 40px;
line-height: 30px;
text-align: left; text-align: left;
border-right: 1px solid #ebeef5; border-right: 1px solid #ebeef5;
border-bottom: 1px solid #ebeef5; border-bottom: 1px solid #ebeef5;
} }
th{ th{
height: 34px; padding: 12px 0;
min-height: 40px;
font-size: 12px;
color: #909399;
word-break: break-all; word-break: break-all;
border-right: 1px solid #ebeef5; border-right: 1px solid #ebeef5;
border-bottom: 1px solid #ebeef5; border-bottom: 1px solid #ebeef5;
/* background-color: #5ca969; */
} }
input{ input{
width: 100%; width: 100%;
@ -1156,8 +1168,12 @@ input{
border: none; border: none;
padding: 0 2px; padding: 0 2px;
} }
.w_30{ .checkboxInput{
width: 30px; width: 14px;
height: 14px;
}
.w_50{
width: 50px;
} }
.w_80{ .w_80{
width: 80px; width: 80px;
@ -1174,21 +1190,19 @@ input{
.w_180{ .w_180{
width: 180px; width: 180px;
} }
.inlineBlock{
display: inline-block;
}
.padding_4{ .padding_4{
padding: 4px; /* 添加内边距 */ padding: 4px; /* 添加内边距 */
} }
.btn{ .btn{
margin: 2px 2px; margin:0 5px;
border: none; border: none;
color: #ffffff; color: #ffffff;
font-size: 12px; font-size: 12px;
border-radius: 4px; border-radius: 4px;
width: 55px; width: 55px;
height: 20px; height: 30px;
line-height: 20px; line-height: 28px;
} }
.btn_red{ .btn_red{
background: #ff0000; background: #ff0000;