diff --git a/src/pages/home/edit-quick-actions.vue b/src/pages/home/edit-quick-actions.vue index 3b2471b..94f8d7f 100644 --- a/src/pages/home/edit-quick-actions.vue +++ b/src/pages/home/edit-quick-actions.vue @@ -476,18 +476,16 @@ .edit-common-btn { position: absolute; right: 20rpx; - height: 60rpx; display: flex; align-items: center; justify-content: center; - padding: 0 32rpx; + padding: 14rpx 28rpx; background: #2979ff; - border-radius: 12rpx; + border-radius: 8rpx; transition: all 0.2s ease; .edit-common-text { - font-size: 34rpx; - font-weight: 500; + font-size: 36rpx; color: #fff; line-height: 1; } diff --git a/src/pages/work/order/order-review.vue b/src/pages/work/order/order-review.vue index 1c3bfaa..ac22d74 100644 --- a/src/pages/work/order/order-review.vue +++ b/src/pages/work/order/order-review.vue @@ -46,8 +46,7 @@ - 该订单已被拦截,请勿复核发货 - 查看 + {{ listType === 'group' ? '该波次有拦截订单' : '该订单已被拦截,请勿复核发货' }} @@ -99,7 +98,7 @@ - + 订单列表 @@ -120,7 +119,7 @@ - + 设置扫描数量 @@ -144,7 +143,7 @@ - + 拦截信息 @@ -163,7 +162,7 @@ - + 称重 @@ -301,7 +300,7 @@ - + 断开蓝牙秤 @@ -315,7 +314,7 @@ - + 包材绑定 @@ -346,7 +345,7 @@ - + 复核设置 @@ -436,10 +435,12 @@ - - + + + + 打印设置 + - 打印设置 打印台 @@ -447,7 +448,8 @@ v-model="printStationInputKeyword" placeholder="请输入或扫描打印台编号" :clearable="true" - :customStyle="{ fontSize: '28rpx', height: '80rpx', lineHeight: '80rpx', padding: '0 20rpx', background: '#fafafa', borderRadius: '10rpx' }" + font-size="36rpx" + :customStyle="{ height: '80rpx', lineHeight: '80rpx', padding: '0 20rpx', background: '#fafafa', borderRadius: '10rpx' }" @input="handlePrintStationInput" @focus="handlePrintStationInputFocus" @blur="handlePrintStationInputBlur" @@ -482,7 +484,7 @@ mode="center" :closeable="false" :closeOnClickOverlay="false" - border-radius="16" + round="16" :z-index="10095" @close="showPrintFailPopup = false" > @@ -501,7 +503,7 @@ - + 打印台列表 @@ -1590,11 +1592,24 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; if (!keyword) { return; } - // 按回车时,如果有精确匹配则选中,否则选中过滤列表第一个 - if (this.printStationFilteredList.length > 0) { - const station = this.printStationFilteredList[0]; - this.handlePrintStationSelect(station); + const kw = keyword.toLowerCase(); + // 仅精确匹配才直接绑定,避免输入部分关键字回车误绑到首个模糊匹配项 + const exactMatch = this.printStationFilteredList.find(station => { + return String(station.name).toLowerCase() === kw + || String(station.id).toLowerCase() === kw + || String(station.customBarcode || '').toLowerCase() === kw; + }); + if (exactMatch) { + this.handlePrintStationSelect(exactMatch); + return; } + // 过滤后仅剩一个时才自动选中,避免多个模糊匹配时误绑第一个 + if (this.printStationFilteredList.length === 1) { + this.handlePrintStationSelect(this.printStationFilteredList[0]); + return; + } + uni.showToast({ title: '未匹配到打印台', icon: 'none' }); + this.speakVoice('未绑定打印台'); }, safeDispatchBroadcast(action, payload) { try { @@ -4564,7 +4579,7 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; &__text { flex: 1; min-width: 0; - font-size: 32rpx; + font-size: 36rpx; color: #ffffff; line-height: 1.4; } @@ -4750,7 +4765,7 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; width: 560rpx; padding: 36rpx; background: #ffffff; - border-radius: 16rpx; + border-radius: 20rpx; } .settings-popup-title { @@ -4774,7 +4789,6 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; .settings-options { display: flex; - gap: 16rpx; } .settings-option { @@ -4788,6 +4802,10 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; background: #fafafa; } + .settings-option + .settings-option { + margin-left: 16rpx; + } + .settings-option--active { color: #2979ff; border-color: #2979ff; @@ -5521,11 +5539,11 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; .search-row { display: flex; align-items: center; - gap: 10rpx; } .search-row .unbound-print-btn { flex-shrink: 0; + margin-left: 10rpx; padding: 0 12rpx; height: 56rpx; font-size: 24rpx; @@ -5538,6 +5556,7 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; .search-row .scan-qty-btn { flex-shrink: 0; + margin-left: 10rpx; padding: 0 12rpx; height: 56rpx; font-size: 24rpx; @@ -5593,9 +5612,32 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; flex-direction: column; } + /* 打印设置弹窗:参考面单补打页样式(紧凑高度 + 顶部圆角裁切 + 居中标题) */ + .print-popup--settings { + height: 450rpx; + border-radius: 20px 20px 0 0; + overflow: hidden; + } + + .print-popup-header { + display: flex; + flex-direction: column; + align-items: center; + padding: 32rpx 30rpx 24rpx; + border-bottom: 1rpx solid #f0f0f0; + flex-shrink: 0; + } + + .print-popup-header .print-popup-title { + font-size: 38rpx; + font-weight: 600; + color: #333; + margin-bottom: 0; + } + .print-popup-scroll { flex: 1; - padding: 48rpx 32rpx calc(40rpx + env(safe-area-inset-bottom)); + padding: 32rpx 32rpx calc(40rpx + env(safe-area-inset-bottom)); box-sizing: border-box; } @@ -5610,23 +5652,19 @@ import ReviewDetail from './order-review-comps/ReviewDetail.vue'; display: flex; align-items: flex-start; padding: 28rpx 0; - border-bottom: 1rpx solid #f2f3f5; } .print-row--station { position: relative; - } - - .print-row--station .print-label { - padding-top: 10rpx; + align-items: center; } .print-label { min-width: 130rpx; width: 130rpx; font-size: 36rpx; - line-height: 40rpx; - color: #909399; + line-height: 36rpx; + color: #000000; } .print-value { diff --git a/src/pages/work/order/returnRecord-comps/ReturnScanPanel.vue b/src/pages/work/order/returnRecord-comps/ReturnScanPanel.vue index ba43e1b..45c1b4f 100644 --- a/src/pages/work/order/returnRecord-comps/ReturnScanPanel.vue +++ b/src/pages/work/order/returnRecord-comps/ReturnScanPanel.vue @@ -2,8 +2,12 @@ @@ -35,19 +39,17 @@ - - - - - - + @@ -82,17 +84,20 @@ + 扫描记录 共 {{ recordTotal }} 条 - 接口未按任务过滤,已前端筛选 - - 导出 - - - 刷新 + + + 导出 + + + 刷新 + + 接口未按任务过滤,已前端筛选 {{ item.tagText }} + 备注:{{ item.remark }} - - {{ item.scannerName || '--' }} - 备注:{{ item.remark }} - + {{ item.scannerName || '--' }} {{ item.createdAt || '--' }} @@ -133,31 +136,6 @@ - - - - - 更多操作 - - - - {{ showScanInput ? '关闭手动输入' : '打开手动输入' }} - - - 刷新扫描记录 - - - - - { + this.recordsRefreshing = false; + }, 300); }, // ===== 常用备注(localStorage 维护) ===== /** 读取本地常用备注 */ @@ -966,15 +946,6 @@ export default { handleExportPopupClose() { this.closeExportPopup(); }, - // ===== 更多操作 ===== - handleMoreManualInput() { - this.showMorePopup = false; - this.toggleScanInput(); - }, - handleMoreRefresh() { - this.showMorePopup = false; - this.handleRefreshRecords(); - }, handleScanConfirm(value) { const code = value || this.scanInput; if (!code) return; @@ -1269,19 +1240,30 @@ export default { flex-shrink: 0; } - /* ===== 导航栏(标题居中,右侧更多按钮自适应宽度) ===== */ + /* ===== 导航栏(标题居中,右侧输入框按钮自适应宽度) ===== */ ::v-deep .nav-title .right { width: auto; min-width: 80rpx; } - /* ===== 右上角更多 ===== */ - .nav-more-btn { + /* ===== 右上角输入框 ===== */ + .nav-input-btn { display: flex; align-items: center; justify-content: center; - width: 72rpx; - height: 72rpx; + padding: 12rpx 28rpx; + border-radius: 8rpx; + background: #2979ff; + + &--active { + background: #fa8c16; + } + + .nav-input-btn__text { + font-size: 36rpx; + color: #ffffff; + line-height: 1; + } } /* ===== 常用备注抽屉 ===== */ @@ -1298,7 +1280,7 @@ export default { .remark-popup__title { font-size: 38rpx; - font-weight: 600; + font-weight: bold; color: #303133; } } @@ -1412,52 +1394,6 @@ export default { } } - /* ===== 更多操作弹窗 ===== */ - .more-popup { - padding: 32rpx 32rpx 40rpx; - - .more-popup__header { - display: flex; - align-items: center; - justify-content: center; - - .more-popup__title { - font-size: 38rpx; - font-weight: 600; - color: #303133; - } - } - - .more-popup__actions { - margin-top: 32rpx; - display: flex; - flex-direction: column; - - .more-popup__btn { - height: 96rpx; - display: flex; - align-items: center; - justify-content: center; - background: #f0f7ff; - border: 1rpx solid #b3d8ff; - border-radius: 16rpx; - - &:active { - opacity: 0.85; - } - - & + .more-popup__btn { - margin-top: 20rpx; - } - - .more-popup__btn-text { - font-size: 32rpx; - color: #2979ff; - } - } - } - } - /* ===== 导出弹窗 ===== */ .export-popup { display: flex; @@ -1473,7 +1409,7 @@ export default { .export-popup__title { font-size: 38rpx; - font-weight: 600; + font-weight: bold; color: #303133; } } @@ -1493,7 +1429,7 @@ export default { .export-popup__percent { font-size: 36rpx; - font-weight: 600; + font-weight: bold; color: #2979ff; } } @@ -1598,7 +1534,7 @@ export default { /* ===== 当前收件任务 ===== */ .task-banner { - margin: 16rpx 24rpx 0; + margin: 16rpx 16rpx 0; padding: 16rpx 24rpx; background: #fff7e6; border: 1rpx solid #ffd591; @@ -1616,7 +1552,7 @@ export default { .task-banner__label { width: 140rpx; flex-shrink: 0; - font-size: 28rpx; + font-size: 32rpx; color: #ad6800; } @@ -1625,7 +1561,7 @@ export default { min-width: 0; font-size: 36rpx; color: #000; - font-weight: 600; + font-weight: bold; /* 编号/任务名过长时完整显示,可换行 */ word-break: break-all; overflow-wrap: break-word; @@ -1678,30 +1614,13 @@ export default { .scan-section { padding: 20rpx 24rpx; background: #fff; - margin: 16rpx 0; - - .scan-input-wrap { - display: flex; - align-items: center; - gap: 16rpx; - - .scan-camera-btn { - width: 72rpx; - height: 72rpx; - display: flex; - align-items: center; - justify-content: center; - background: #f0f7ff; - border-radius: 8rpx; - flex-shrink: 0; - } - } + margin: 16rpx 16rpx; } /* ===== 信息展示列表 ===== */ .info-list { background: #fff; - margin: 0 24rpx 16rpx; + margin: 0 16rpx 16rpx; border-radius: 12rpx; overflow: hidden; @@ -1775,7 +1694,7 @@ export default { /* ===== 加急提示 ===== */ .urgent-tip { - margin: 0 24rpx 16rpx; + margin: 0 16rpx 16rpx; padding: 24rpx 24rpx; display: flex; align-items: center; @@ -1794,7 +1713,7 @@ export default { /* ===== 30日幂等提示 ===== */ .duplicated-tip { - margin: 0 24rpx 16rpx; + margin: 0 16rpx 16rpx; padding: 20rpx 24rpx; display: flex; align-items: center; @@ -1816,7 +1735,7 @@ export default { min-height: 0; display: flex; flex-direction: column; - margin: 16rpx 24rpx 12rpx; + margin: 16rpx 16rpx 12rpx; background: #ffffff; border-radius: 12rpx; overflow: hidden; @@ -1825,18 +1744,26 @@ export default { flex-shrink: 0; display: flex; align-items: center; - padding: 16rpx 20rpx; + padding: 16rpx 24rpx; border-bottom: 1rpx solid #f0f0f0; .record-section__head-left { flex-shrink: 0; display: flex; - align-items: baseline; + align-items: center; + + .record-section__title-bar { + width: 8rpx; + height: 32rpx; + margin-right: 12rpx; + background: #2979ff; + border-radius: 4rpx; + } } .record-section__title { font-size: 36rpx; - font-weight: 600; + font-weight: bold; color: #303133; } @@ -1846,14 +1773,11 @@ export default { color: #909399; } - .record-section__hint { - flex: 1; - min-width: 0; - margin-left: 12rpx; - font-size: 28rpx; - color: #fa8c16; - word-break: break-all; - overflow-wrap: break-word; + .record-section__head-actions { + margin-left: auto; + flex-shrink: 0; + display: flex; + align-items: center; } .record-section__btn { @@ -1861,10 +1785,8 @@ export default { display: flex; align-items: center; justify-content: center; - margin-left: auto; - width: 130rpx; height: 60rpx; - padding: 0; + padding: 0 28rpx; background: #2979ff; border-radius: 8rpx; @@ -1873,16 +1795,26 @@ export default { } .record-section__btn-text { - font-size: 32rpx; + font-size: 36rpx; color: #ffffff; white-space: nowrap; } } } + .record-section__hint { + display: block; + padding: 10rpx 24rpx 0; + font-size: 28rpx; + color: #fa8c16; + word-break: break-all; + overflow-wrap: break-word; + } + .record-scroll { flex: 1; min-height: 0; + background: #f5f7fa; } .record-empty { @@ -1892,25 +1824,23 @@ export default { justify-content: center; .record-empty__text { - font-size: 28rpx; + font-size: 32rpx; color: #c0c4cc; } } .record-list { - padding: 0; + padding: 12rpx 0; .record-item { - padding: 16rpx 20rpx; - border-bottom: 1rpx solid #f5f6f8; - - /* 斑马纹:偶数行浅灰背景 */ - &:nth-child(even) { - background: #f5f7fa; - } + padding: 20rpx 24rpx; + margin-bottom: 12rpx; + background: #ffffff; + border: 1rpx solid #ebeef5; + border-radius: 12rpx; &:last-child { - border-bottom: none; + margin-bottom: 0; } .record-item__head { @@ -1921,7 +1851,6 @@ export default { flex: 1; min-width: 0; font-size: 36rpx; - font-weight: 600; color: #000; /* 单号完整显示,可换行 */ word-break: break-all; @@ -1954,19 +1883,11 @@ export default { } .record-item__meta { - margin-top: 6rpx; + margin-top: 8rpx; display: flex; - align-items: flex-start; + align-items: center; justify-content: space-between; - /* 左:姓名 + 备注(备注完整显示,可换行) 右:时间 */ - .record-item__meta-left { - flex: 1; - min-width: 0; - display: flex; - align-items: flex-start; - } - .record-item__meta-item { flex-shrink: 0; font-size: 28rpx; @@ -1976,17 +1897,16 @@ export default { .record-item__meta-item--time { margin-left: 12rpx; } + } - .record-item__remark { - flex: 1; - min-width: 0; - margin-left: 12rpx; - font-size: 32rpx; - color: #606266; - /* 备注完整显示,可换行 */ - word-break: break-all; - overflow-wrap: break-word; - } + .record-item__remark { + display: block; + margin-top: 8rpx; + font-size: 36rpx; + color: #000000; + /* 备注完整显示,可换行 */ + word-break: break-all; + overflow-wrap: break-word; } } } diff --git a/src/pages/work/order/returnRecord.vue b/src/pages/work/order/returnRecord.vue index 760d9fe..f50bafb 100644 --- a/src/pages/work/order/returnRecord.vue +++ b/src/pages/work/order/returnRecord.vue @@ -134,6 +134,27 @@ + + + + + 删除收件任务 + + 确认删除「{{ (deletingTask && (deletingTask.title || deletingTask.batchNo || deletingTask.id)) || '--' }}」?删除后不可恢复 + + + 取消 + 删除 + + + @@ -172,7 +193,10 @@ export default { // 新建任务 showCreatePopup: false, createTitle: '', - creating: false + creating: false, + // 删除任务 + showDeletePopup: false, + deletingTask: null }; }, computed: { @@ -249,7 +273,6 @@ export default { uni.showToast({ title: '查询收件任务失败', icon: 'none' }); } finally { this.loading = false; - this.refreshing = false; } }, handleSearch() { @@ -266,8 +289,13 @@ export default { async handleRefresh() { if (this.refreshing) return; this.refreshing = true; + // 真机原生 refresher 需先收到 true 再收到 false 才会收回,先让 true 刷新到原生 + await this.$nextTick(); await this.loadTaskList(this.currentPage); - this.refreshing = false; + // 延迟关闭,避免 true/false 连续赋值被渲染层合并导致一直转圈 + setTimeout(() => { + this.refreshing = false; + }, 300); }, // ===== 进入扫码登记 ===== handleTaskOpen(item) { @@ -293,15 +321,19 @@ export default { } return; } - uni.showModal({ - title: '删除收件任务', - content: `确认删除「${item.title || item.batchNo || item.id}」?删除后不可恢复`, - success: (modalRes) => { - if (modalRes.confirm) { - this.removeTask(item); - } - } - }); + this.deletingTask = item; + this.showDeletePopup = true; + }, + closeDeletePopup() { + this.showDeletePopup = false; + this.deletingTask = null; + }, + confirmDeleteTask() { + const item = this.deletingTask; + this.closeDeletePopup(); + if (item) { + this.removeTask(item); + } }, async removeTask(item) { uni.showLoading({ title: '删除中...', mask: true }); @@ -383,17 +415,21 @@ export default { } .nav-create { + position: absolute; + top: 50%; + right: 20rpx; + transform: translateY(-50%); display: flex; align-items: center; justify-content: center; - width: 130rpx; - height: 60rpx; + padding: 14rpx 28rpx; background: #2979ff; border-radius: 8rpx; .nav-create-text { - font-size: 32rpx; + font-size: 36rpx; color: #ffffff; + line-height: 1; white-space: nowrap; } } @@ -415,35 +451,45 @@ export default { align-items: center; .task-scope__item { + flex: 1; + height: 56rpx; + padding: 0 12rpx; display: flex; align-items: center; justify-content: center; - padding: 8rpx 32rpx; - margin-right: 16rpx; background: #f5f7fa; - border: 1rpx solid #e6e8eb; - border-radius: 30rpx; + border: 1rpx solid #ebeef5; + border-radius: 28rpx; + + & + .task-scope__item { + margin-left: 16rpx; + } &--active { - background: #e6f0ff; + background: #2979ff; border-color: #2979ff; + box-shadow: 0 4rpx 12rpx rgba(41, 121, 255, 0.28); } .task-scope__text { - font-size: 28rpx; + font-size: 34rpx; color: #606266; + white-space: nowrap; } &--active .task-scope__text { - color: #2979ff; - font-weight: 600; + color: #ffffff; + font-weight: bold; } } .task-scope__hint { - flex: 1; - text-align: right; - font-size: 24rpx; + flex: 2; + display: flex; + align-items: center; + justify-content: flex-end; + margin-left: 16rpx; + font-size: 30rpx; color: #c0c4cc; } } @@ -479,17 +525,15 @@ export default { } .task-list { - padding: 0 12rpx; + padding: 0 16rpx; box-sizing: border-box; - /* 左滑时内容被容器裁剪到卡片左边缘(文字贴死左边):给滑动容器留一点左间距 */ ::v-deep .u-swipe-action-item { - margin-left: 12rpx; + margin-bottom: 12rpx; } } .task-card { - margin-bottom: 12rpx; padding: 20rpx 24rpx; background: #ffffff; border: 2rpx solid #ebedf2; @@ -505,17 +549,15 @@ export default { min-width: 0; margin-right: 16rpx; font-size: 38rpx; - font-weight: 600; + font-weight: bold; color: #000; - /* 编号过长时单行省略,避免挤掉右侧登记数 */ - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; + /* 编号过长时换行显示,避免挤掉右侧登记数 */ + word-break: break-all; } .task-card__count { flex-shrink: 0; - font-size: 34rpx; + font-size: 36rpx; color: #ffffff; background: #52c41a; border-radius: 24rpx; @@ -535,7 +577,7 @@ export default { .task-card__title { flex: 1; - font-size: 32rpx; + font-size: 36rpx; color: #303133; overflow: hidden; text-overflow: ellipsis; @@ -561,7 +603,7 @@ export default { justify-content: space-between; .task-card__meta-item { - font-size: 26rpx; + font-size: 30rpx; color: #909399; } } @@ -590,7 +632,7 @@ export default { .create-popup__title { font-size: 38rpx; - font-weight: 600; + font-weight: bold; color: #303133; } } @@ -650,5 +692,67 @@ export default { } } } + + /* ===== 删除任务确认弹窗(参考完成盘点弹窗样式) ===== */ + .delete-confirm-popup { + width: 640rpx; + padding: 40rpx 32rpx 32rpx; + background: #ffffff; + border-radius: 20rpx; + box-sizing: border-box; + } + + .delete-confirm-popup__title { + font-size: 42rpx; + font-weight: bold; + color: #303133; + text-align: center; + margin-bottom: 32rpx; + } + + .delete-confirm-popup__body { + margin-bottom: 36rpx; + padding: 24rpx; + background: #f5f7fa; + border-radius: 12rpx; + } + + .delete-confirm-popup__text { + font-size: 36rpx; + color: #303133; + line-height: 1.6; + word-break: break-all; + } + + .delete-confirm-popup__actions { + display: flex; + align-items: center; + } + + .delete-confirm-popup__btn { + flex: 1; + height: 88rpx; + border-radius: 12rpx; + display: flex; + align-items: center; + justify-content: center; + font-size: 36rpx; + font-weight: bold; + } + + .delete-confirm-popup__btn + .delete-confirm-popup__btn { + margin-left: 20rpx; + } + + .delete-confirm-popup__btn--cancel { + background: #f5f7fa; + color: #606266; + border: 1rpx solid #dcdfe6; + } + + .delete-confirm-popup__btn--confirm { + background: #f56c6c; + color: #ffffff; + } }