feat(钢卷修正): 添加钢卷状态显示和边框颜色区分
- 在标题下方添加状态说明文本 - 根据dataType动态设置钢卷卡片边框颜色 - 显示materialType字段并移除注释 - 调整footer按钮显示条件 - 合并重复的dicts配置
This commit is contained in:
@@ -5,7 +5,11 @@
|
||||
<el-col :span="24">
|
||||
<div class="section-card material-section">
|
||||
<div class="section-header">
|
||||
<h3 class="section-title">查找钢卷并修正</h3>
|
||||
<h3 class="section-title">
|
||||
查找钢卷并修正
|
||||
<span class="section-desc">绿色边框表示当前钢卷,灰色边框表示历史钢卷</span>
|
||||
</h3>
|
||||
|
||||
<el-button size="mini" icon="el-icon-refresh" @click="getMaterialCoil">刷新</el-button>
|
||||
</div>
|
||||
|
||||
@@ -31,13 +35,13 @@
|
||||
<i class="el-icon-box"></i>
|
||||
<p>暂无待领物料</p>
|
||||
</div>
|
||||
|
||||
<!-- 根据item.dataType决定边框颜色,为0使用当前的颜色,为1使用绿色,为2使用黄色 -->
|
||||
<div v-for="(item, index) in materialCoilList" :key="item.coilId || index" class="material-card"
|
||||
:style="{ border: item.abnormalCount > 0 ? '1px solid red' : ' 1px solid #e4e7ed' }">
|
||||
:style="item.dataType === 0 ? 'border: 1.5px solid #e4e7ed' : item.dataType === 1 ? 'border: 1.5px solid green' : 'border: 1.5px solid yellow'">
|
||||
<div class="card-header">
|
||||
<div class="header-left">
|
||||
<el-tag type="info" size="small" class="coil-no-tag">{{ item.currentCoilNo }}</el-tag>
|
||||
<!-- <span class="material-type">{{ item.materialType || '原料' }}</span> -->
|
||||
<span class="material-type">{{ item.materialType || '原料' }}</span>
|
||||
<el-popover v-if="item.rawMaterial || item.product" placement="top" width="280" trigger="hover"
|
||||
popper-class="material-params-popover">
|
||||
<div class="material-params-content">
|
||||
@@ -178,7 +182,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<div class="card-footer" v-if="item.dataType != 10">
|
||||
<el-button type="primary" icon="el-icon-check" size="mini" @click="handleCorrectMaterial(item)"
|
||||
:loading="item.picking" class="action-btn">修正</el-button>
|
||||
<el-button type="danger" icon="el-icon-alarm-clock" :plain="item.abnormalCount == 0" size="mini"
|
||||
@@ -346,7 +350,7 @@ import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
||||
|
||||
export default {
|
||||
name: 'DoPage',
|
||||
dicts: ['action_type', 'coil_abnormal_code', 'coil_abnormal_position', 'coil_abnormal_degree'],
|
||||
dicts: ['action_type', 'coil_abnormal_code', 'coil_abnormal_position', 'coil_abnormal_degree', 'coil_quality_status'],
|
||||
props: {
|
||||
label: {
|
||||
type: String,
|
||||
@@ -366,7 +370,6 @@ export default {
|
||||
ProductSelect,
|
||||
RawMaterialSelect,
|
||||
},
|
||||
dicts: ['coil_quality_status'],
|
||||
data() {
|
||||
return {
|
||||
// 物料列表相关
|
||||
@@ -377,7 +380,7 @@ export default {
|
||||
materialQueryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 20,
|
||||
dataType: 1,
|
||||
// dataType: 1,
|
||||
status: 0,
|
||||
enterCoilNo: null,
|
||||
currentCoilNo: null
|
||||
@@ -829,6 +832,11 @@ export default {
|
||||
color: #303133;
|
||||
}
|
||||
|
||||
.section-desc {
|
||||
font-size: 12px;
|
||||
color: #909399;
|
||||
}
|
||||
|
||||
.material-section {
|
||||
.section-header {
|
||||
border-bottom-color: #409eff;
|
||||
|
||||
Reference in New Issue
Block a user