From f71d2f108860712b8d30a958b2dc46d5af4620e5 Mon Sep 17 00:00:00 2001 From: zzh <1368735060@qq.com> Date: Thu, 3 Sep 2026 18:05:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=8A=BD=E5=B1=89=E5=8E=BB=E9=A1=B6?= =?UTF-8?q?=E6=A0=8F/=E5=9C=86=E8=A7=92=EF=BC=8C=E8=AE=A2=E5=8D=95?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E6=8C=89=E9=92=AE=E7=BB=9F=E4=B8=80=E5=88=B0?= =?UTF-8?q?=20Tab=20=E4=B8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DrawerPro 默认隐藏空 header;抽屉无圆角;修复全部轨迹开关;详情操作从 footer 挪到 Tab 工具栏。 Co-authored-by: Cursor --- src/assets/style/global.less | 8 +- src/components/DrawerPro/index.vue | 9 +- .../myOrders/components/OrderDetailDrawer.vue | 134 +++++++---- .../myOrders/components/OrderStockBindTab.vue | 10 +- .../components/OrderDetailDrawer.vue | 210 +++++++++++------- .../components/TrackOrderDetailDrawer.vue | 11 +- src/views/track/trackOrder/index.vue | 14 +- 7 files changed, 257 insertions(+), 139 deletions(-) diff --git a/src/assets/style/global.less b/src/assets/style/global.less index 1ee8a62..9ce1db6 100644 --- a/src/assets/style/global.less +++ b/src/assets/style/global.less @@ -135,13 +135,13 @@ body .arco-modal-simple .arco-modal-title { text-align: left; } -/* Rounded corners to align with SimpleAdmin (Element Plus-like 4px) */ +/* Rounded corners to align with SimpleAdmin (Element Plus-like 4px) + 抽屉贴边展开,不做圆角 */ body .arco-card, body .arco-card-bordered, body .arco-modal, body .arco-popover-content, body .arco-dropdown, -body .arco-drawer, body .arco-input-wrapper, body .arco-textarea-wrapper, body .arco-select, @@ -155,6 +155,10 @@ body .arco-notification { border-radius: 8px !important; } +body .arco-drawer { + border-radius: 0 !important; +} + /* vxe table wrapper */ body .vxe-table--border, body .vxe-grid { diff --git a/src/components/DrawerPro/index.vue b/src/components/DrawerPro/index.vue index 7f03e83..404ce39 100644 --- a/src/components/DrawerPro/index.vue +++ b/src/components/DrawerPro/index.vue @@ -10,11 +10,18 @@ visible: false, width: 400, placement: 'right', + // 默认不展示顶栏(可点遮罩关闭);需要标题时 setDrawerProps({ title }) 会自动打开 + header: false, ...unref(Attrs), }); const setDrawerProps = (props: DrawerProps) => { - Object.assign(defaultProps, props); + const next: DrawerProps = { ...props }; + // 传入 title 且未显式指定 header 时,自动显示顶栏 + if (next.title && next.header === undefined) { + next.header = true; + } + Object.assign(defaultProps, next); }; const instance = getCurrentInstance(); diff --git a/src/views/order/myOrders/components/OrderDetailDrawer.vue b/src/views/order/myOrders/components/OrderDetailDrawer.vue index 51f33e3..9c55103 100644 --- a/src/views/order/myOrders/components/OrderDetailDrawer.vue +++ b/src/views/order/myOrders/components/OrderDetailDrawer.vue @@ -1,25 +1,10 @@