排产代码提交

dev-scheduling
zhangdi 4 days ago
parent eba8eb5aee
commit 3cfeee2035
  1. 74
      src/views/productionSchedulingPlan/schedulingDashboard/index.vue

@ -232,7 +232,6 @@
<div class="wo-code-title" v-if="searchType == '1'">{{ tooltipData.woCode }}</div>
<div class="wo-code-title" v-if="searchType == '2'">{{ tooltipData.teamName }}</div>
<div class="wo-code-title" v-if="searchType == '3'">{{ tooltipData.equipName }}</div>
<!-- 详情列表 -->
<ul class="detail-list">
<li class="detail-item" v-if="searchType == '1'">
@ -247,6 +246,26 @@
<span class="label">车间订单号</span>
<span class="value">{{ tooltipData.woCode || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">零件号</span>
<span class="value">{{ tooltipData.partCode || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">流程卡号</span>
<span class="value">{{ tooltipData.cardNo || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">批次号</span>
<span class="value">{{ tooltipData.batehNo || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">当前工序</span>
<span class="value">{{ tooltipData.currenterecessName || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">数量</span>
<span class="value">{{ tooltipData.makeoty || '-' }}</span>
</li>
<li class="detail-item">
<span class="label">计划开始时间</span>
<span class="value">{{ tooltipData.planStartTime || '-' }}</span>
@ -266,14 +285,12 @@
<li class="detail-item">
<span class="label">状态</span>
<span class="value">
<!-- et staus=this.searchType=='1'?row.planStatus:row.orderStatus -->
<el-tag v-if="searchType == '1'">
<i v-if="tooltipData.planStatus == '1'">未开始</i>
<i v-if="tooltipData.planStatus == '2'">进行中</i>
<i v-if="tooltipData.planStatus == '3'">已完成</i>
</el-tag>
<el-tag v-if="searchType == '2'||searchType == '3'" :type="tooltipData.status">
<el-tag v-if="searchType == '2' || searchType == '3'" :type="tooltipData.status">
<i v-if="tooltipData.orderStatus == '1'">未开始</i>
<i v-if="tooltipData.orderStatus == '2'">进行中</i>
<i v-if="tooltipData.orderStatus == '3'">已完成</i>
@ -317,7 +334,7 @@ export default {
tooltipData: {},
tooltipX: 0,
tooltipY: 0,
baseRowHeight: 40, //
baseRowHeight: 36, //
rowHeights: {}, //
};
},
@ -497,10 +514,40 @@ export default {
//
showTooltip(e, task, device) {
this.tooltipData = { ...task, device };
this.tooltipX = e.pageX + 10;
this.tooltipY = e.pageY + 10;
this.tooltipVisible = true;
this.tooltipData = { ...task, device };
this.tooltipVisible = true; // tooltip便
this.$nextTick(() => {
const tooltipEl = document.querySelector('.tooltip');
if (!tooltipEl) return; //
const tooltipWidth = tooltipEl.offsetWidth;
const tooltipHeight = tooltipEl.offsetHeight;
const padding = 5; // tooltip
const mouseOffsetX = 8; // 10px8px
const mouseOffsetY = 8; // 10px8px
//
let x = e.pageX + mouseOffsetX;
let y = e.pageY + mouseOffsetY;
//
if (x + tooltipWidth > document.documentElement.clientWidth) {
x = e.pageX - tooltipWidth - mouseOffsetX;
}
//
if (y + tooltipHeight > document.documentElement.clientHeight) {
y = e.pageY - tooltipHeight - mouseOffsetY;
}
//
x = Math.max(padding, x);
y = Math.max(padding, y);
this.tooltipX = x;
this.tooltipY = y;
});
},
hideTooltip() {
this.tooltipVisible = false;
@ -866,7 +913,7 @@ export default {
}
.task-label {
font-size: 12px;
font-size: 14px;
color: white;
white-space: nowrap;
overflow: hidden;
@ -879,11 +926,12 @@ export default {
background-color: white;
border: 1px solid #ddd;
border-radius: 4px;
padding: 10px;
padding: 5px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
z-index: 1000;
font-size: 12px;
pointer-events: none;
/* z-index: 100; */
}
.tooltip-content div {
@ -906,8 +954,8 @@ export default {
.detail-item {
display: flex;
align-items: center;
margin-bottom: 12px;
line-height: 24px;
margin-bottom: 5px;
line-height: 20px;
.label {
width: 100px;

Loading…
Cancel
Save