diff --git a/.workbuddy/memory/2026-08-13.md b/.workbuddy/memory/2026-08-13.md new file mode 100644 index 0000000..6321525 --- /dev/null +++ b/.workbuddy/memory/2026-08-13.md @@ -0,0 +1,62 @@ +# 2026-08-13 工作记录 + +## business-crud-page.vue UI 对齐 customer-archive(section-card 间隔 + 表单排列统一) + +### 问题 +- 该组件内 `.section-card { margin-bottom: 0 !important }`(scoped 顶层)把全局 8px 卡片间距清零,导致弹窗里的 section-card 卡片贴在一起(与 customer-archive 的留白不一致)。 +- 手写的 dispatch-item 表单 markup 仍写 `label-width="auto"`(虽被共享 CSS 块强制为 `calc(6em+24px)`,但不直观)。 + +### 改动(src/views/business/components/business-crud-page.vue) +1. 删除 `margin-bottom:0 !important` 覆盖,改为 `.section-card{margin-bottom:8px !important; &:last-child{margin-bottom:0}}`,与 customer-archive/全局 element-ui.scss 的 8px 节奏一致。 +2. `.business-crud-page__detail-content`(详情弹窗,原本 `gap:12px`)改为 `gap:8px` 并给内部 `.section-card{margin-bottom:0 !important}`,避免 8px 外边距 + gap 双重留白。 +3. `:deep(.avue-form__group:has(.dialog-section-title))` 白卡 `margin-bottom:16px→8px`,使主弹窗分组白卡与 section-card 同节奏。 +4. `&__dispatch-summary` 的 `margin-bottom:12px→8px`。 +5. dispatch-item 表单 `label-width="auto"→"calc(6em + 24px)"`(与 task-form/freight-form 共享的 label 标准一致;参考 customer-archive 的右侧固定宽 label + `el-row :gutter` 网格思路)。 + +### 验证 +- 仅改 scoped SCSS + 1 处 markup 属性,未动逻辑;SFC 结构未变。表单组件排列本就通过共享 `__task-form/__freight-form/__dispatch-item-form` 块统一为 `calc(6em+24px)` label + 4 列网格,本次使其显式对齐。 + +## 弹窗样式与交互调整(base 模块) + +### 1. port-terminal.vue 港口/码头弹窗 +- 去掉浏览器 input autocomplete 地址联想:新增 `disableDialogAutocomplete()` 方法(批量给 `.port-terminal-edit-dialog` 内 input/textarea 设 autocomplete=off 等),在 `beforeOpen` 两个分支 `done()` 后用 `setTimeout(50)` 调用。 +- option 字段调整(用户此前需求,已指导):详细地址 `detailAddress` 的 `span:24→12`、`order:86→88`,与区县 `districtCode`(span12,order87) 并排。 + +### 2. railway-station.vue 铁路车站弹窗 +- label 宽度 85→108:option `labelWidth:'auto'→'108px'`(字符串不生效),再补 `dialogCustomClass:'railway-station-edit-dialog'` + 非 scoped ` diff --git a/src/views/base/railway-station.vue b/src/views/base/railway-station.vue index cf11f64..4dc8249 100644 --- a/src/views/base/railway-station.vue +++ b/src/views/base/railway-station.vue @@ -204,7 +204,7 @@ export default { dialogWidth: 980, dialogCustomClass: 'railway-station-edit-dialog', labelPosition: 'right', - labelWidth: '108px', + labelWidth: '140px', tip: false, searchShow: true, searchMenuSpan: 24, @@ -899,10 +899,10 @@ export default { diff --git a/src/views/business/components/business-crud-page.vue b/src/views/business/components/business-crud-page.vue index 8c3785b..a4b6fcc 100644 --- a/src/views/business/components/business-crud-page.vue +++ b/src/views/business/components/business-crud-page.vue @@ -2685,7 +2685,7 @@
收发货信息
@@ -10268,7 +10268,7 @@ export default { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 16px; align-items: stretch; - margin-bottom: 12px; + margin-bottom: 8px; } &__dispatch-summary-card, @@ -10702,9 +10702,11 @@ export default { &__detail-content { display: flex; flex-direction: column; - gap: 12px; + gap: 8px; .section-card { + margin-bottom: 0 !important; + :deep(.el-descriptions__label) { width: 140px; color: #606266; @@ -10803,8 +10805,12 @@ export default { } } } -.section-card{ - margin-bottom: 0 !important; +.section-card { + margin-bottom: 8px !important; + + &:last-child { + margin-bottom: 0 !important; + } } /* 编辑弹窗:含分组的 Avue form 渲染为白卡风格 */ @@ -10813,7 +10819,7 @@ export default { border-radius: 6px; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08); padding: 16px; - margin-bottom: 16px; + margin-bottom: 8px; .avue-form__group--title { padding: 0 !important; diff --git a/src/views/business/project-apply.vue b/src/views/business/project-apply.vue index 57953d3..ed59671 100644 --- a/src/views/business/project-apply.vue +++ b/src/views/business/project-apply.vue @@ -1908,7 +1908,7 @@ export default { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 72px; row-gap: 0; - margin-bottom: 8px; + margin-bottom: 12px; background: #fff; border-radius: 0 0 6px 6px; padding: 14px 16px 4px; @@ -1934,7 +1934,7 @@ export default { &__table { width: 100%; - margin-bottom: 8px; + margin-bottom: 12px; background: #fff; border-radius: 0 0 6px 6px; padding: 12px; @@ -1952,7 +1952,7 @@ export default { } &__textarea-list { - margin-bottom: 8px; + margin-bottom: 12px; background: #fff; border-radius: 0 0 6px 6px; padding: 14px 16px 4px; @@ -1975,7 +1975,7 @@ export default { } &__material-card { - margin-bottom: 8px; + margin-bottom: 12px; background: #fff; border-radius: 6px; padding: 14px 16px; diff --git a/src/views/vehicle/customer-archive.vue b/src/views/vehicle/customer-archive.vue index 38912bf..f7f215c 100644 --- a/src/views/vehicle/customer-archive.vue +++ b/src/views/vehicle/customer-archive.vue @@ -3779,7 +3779,7 @@ export default { } .archive-detail-card { - margin-top: 8px; + margin-top: 12px; } .archive-tabs { :deep(.el-tabs__header) {