Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf4f4002

Browse files
committed
1.8.338 20251106
调整仓位展示
1 parentfa6150b commitf4f4002

File tree

2 files changed

+32
-8
lines changed

2 files changed

+32
-8
lines changed

‎src/store/modules/common.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ const useCommonStore = defineStore('commonStore', () => {
2020

2121
// 系统配置
2222
letpublicSetting=ref({
23-
webVer:"1.8.337 20251105"
23+
webVer:"1.8.338 20251106"
2424
});
2525

2626
// 添加登录状态管理

‎src/views/custom-page/Yt/PositionDistribution.vue‎

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
</div>
101101
</div>
102102
<divclass="slot-grid-container">
103-
<divclass="slot-grid">
103+
<divclass="slot-grid"v-if="slotList.length > 0":style="{ gridTemplateColumns: `repeat(${currentX || 10}, 100px)` }">
104104
<div
105105
v-for="slot in slotList"
106106
:key="slot.id"
@@ -111,6 +111,9 @@
111111
<spanclass="slot-label">{{ slot.label }}</span>
112112
</div>
113113
</div>
114+
<divclass="slot-grid-empty"v-else>
115+
<el-emptydescription="暂无仓位" />
116+
</div>
114117
</div>
115118
</div>
116119
</div>
@@ -213,14 +216,25 @@ const onLoadTreeData = async (status) => {
213216
treeLoading.value=false;
214217
};
215218
219+
let currentX=ref(null);
220+
let currentY=ref(null);
221+
216222
// 树节点点击事件
217223
consthandleNodeClick= (data)=> {
218224
// 只处理二级节点(仓库)
219225
if (!data.children||data.children.length===0) {
226+
currentX.value=data.rawData.spatialinformationX||0;
227+
currentY.value=data.rawData.spatialinformationY||0;
220228
currentWarehouseId.value=data.id;
221-
currentWarehouseTitle.value=`${data.label}的仓位`;
229+
currentWarehouseTitle.value=`${data.label}的仓位${currentX.value}*${currentY.value}`;
222230
// 使用原始数据中的ID或当前节点ID
223231
constwarehouseId=data.rawData?.basicInformationoftheWarehouseId;
232+
233+
// 没有坐标信息,不加载仓位数据
234+
if(!currentX.value||!currentY.value){
235+
slotList.value= [];
236+
return;
237+
}
224238
loadSlotData(warehouseId);
225239
}
226240
};
@@ -570,6 +584,7 @@ const handleEdit = (data) => {
570584
571585
.slot-grid-container {
572586
flex:1;
587+
overflow-x: auto;
573588
overflow-y: auto;
574589
padding:20px;
575590
@@ -600,8 +615,9 @@ const handleEdit = (data) => {
600615
601616
.slot-grid {
602617
display: grid;
603-
grid-template-columns:repeat(10,1fr);
604618
gap:10px;
619+
width: fit-content;
620+
min-width:100%;
605621
606622
.slot-cell {
607623
aspect-ratio:1;
@@ -612,11 +628,12 @@ const handleEdit = (data) => {
612628
justify-content: center;
613629
cursor: pointer;
614630
transition: all0.2s;
615-
min-height:60px;
616-
631+
width:100px;
632+
height:100px;
633+
box-sizing: border-box;
634+
padding:05px;
617635
.slot-label {
618-
font-size:12px;
619-
font-weight:500;
636+
font-size:13px;
620637
color: #303133;
621638
}
622639
@@ -659,6 +676,13 @@ const handleEdit = (data) => {
659676
}
660677
}
661678
679+
.slot-grid-empty {
680+
display: flex;
681+
align-items: center;
682+
justify-content: center;
683+
height:60%;
684+
}
685+
662686
.help-text {
663687
font-size:12px;
664688
color: #f56c6c;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp