change(dms):修复设备图片字段清空逻辑并优化卡片布局

- 将图片字段清空方式从 undefined 改为显式设置为空字符串,确保后端正确更新
- 设备卡片容器增加 align-items: stretch 以保持一致高度
- 调整 .machine-card 样式以支持弹性布局,预留底部操作区域空间
- 快捷操作按钮组定位到底部,并横向居中显示- 统一卡片内边距,增强视觉一致性
master
zangch@mesnac.com 2 months ago
parent dbdcc0557e
commit db8e282bbc

@ -1117,8 +1117,9 @@ const submitForm = () => {
form.value.ossId = form.value.file[0].ossId;
form.value.photoAddress = form.value.file[0].url;
} else {
form.value.ossId = undefined;
form.value.photoAddress = undefined;
//
form.value.ossId = '';
form.value.photoAddress = '';
}
if (form.value.machineId) {
@ -1741,18 +1742,25 @@ watch(selectedMachine, (newMachine) => {
grid-template-columns: repeat(5, 1fr); // 5
gap: 8px;
margin-bottom: 16px;
align-items: stretch;
}
.machine-card-wrapper {
cursor: pointer;
height: 100%;
.machine-card {
background: #fff;
border-radius: 4px;
padding: 8px;
padding: 8px 8px 44px; //
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
transition: all 0.3s ease;
position: relative;
height: 160px;
display: flex;
flex-direction: column;
justify-content: space-between;
box-sizing: border-box;
&:hover {
transform: translateY(-1px);
@ -1852,6 +1860,10 @@ watch(selectedMachine, (newMachine) => {
}
.quick-actions {
position: absolute;
left: 8px;
right: 8px;
bottom: 8px;
display: flex;
gap: 4px;
justify-content: center;

Loading…
Cancel
Save