From 29d808402de185f1661c5a8181436e5e0d88e591 Mon Sep 17 00:00:00 2001 From: lzq <2495532633@qq.com> Date: Thu, 15 Jan 2026 17:36:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E4=BB=B6=E4=B8=8A=E4=BC=A0=E7=BB=84?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 12 +- src/common/app/app-api.ts | 7 +- src/common/index.ts | 2 +- src/common/utils/times.ts | 57 +++++++- src/components/page/FormPage.vue | 37 ++++- src/components/uploader/Uploader.vue | 69 ++++++++-- src/dts/components.d.ts | 11 +- src/pages/a-frame/UserInfoPanel.vue | 14 +- .../gds/goods-category/GoodsCategory.vue | 89 +++++++++++- .../gds/goods-category/GoodsCategoryForm.vue | 130 +++++++++--------- .../gds/goods-category/goods-category.d.ts | 18 +-- src/pages/gds/goods/Goods.vue | 20 ++- src/pages/gds/goods/GoodsForm.vue | 130 +++++++++--------- src/pages/gds/goods/goods-api.ts | 5 +- src/pages/order/trans-order/CheckForm.vue | 69 +++++----- src/pages/order/trans-order/InForm.vue | 84 ++++++----- src/pages/order/trans-order/OutForm.vue | 30 ++-- src/pages/sys/user/UserForm.vue | 9 +- 18 files changed, 517 insertions(+), 276 deletions(-) diff --git a/index.html b/index.html index 69ed505..65997a9 100644 --- a/index.html +++ b/index.html @@ -1,14 +1,14 @@ - - + + - + - + diff --git a/src/dts/components.d.ts b/src/dts/components.d.ts index 7baa19c..a7d2661 100644 --- a/src/dts/components.d.ts +++ b/src/dts/components.d.ts @@ -5,7 +5,6 @@ // ------ // Generated by unplugin-vue-components // Read more: https://github.com/vuejs/core/pull/3399 -import { GlobalComponents } from 'vue' export {} @@ -33,8 +32,12 @@ declare module 'vue' { ElHeader: typeof import('element-plus/es')['ElHeader'] ElIcon: typeof import('element-plus/es')['ElIcon'] ElIconCircleClose: typeof import('@element-plus/icons-vue')['CircleClose'] + ElIconCirclePlus: typeof import('@element-plus/icons-vue')['CirclePlus'] + ElIconDelete: typeof import('@element-plus/icons-vue')['Delete'] ElIconPicture: typeof import('@element-plus/icons-vue')['Picture'] + ElIconPlus: typeof import('@element-plus/icons-vue')['Plus'] ElImage: typeof import('element-plus/es')['ElImage'] + ElImageViewer: typeof import('element-plus/es')['ElImageViewer'] ElInput: typeof import('element-plus/es')['ElInput'] ElInputNumber: typeof import('element-plus/es')['ElInputNumber'] ElMain: typeof import('element-plus/es')['ElMain'] @@ -87,8 +90,12 @@ declare global { const ElHeader: typeof import('element-plus/es')['ElHeader'] const ElIcon: typeof import('element-plus/es')['ElIcon'] const ElIconCircleClose: typeof import('@element-plus/icons-vue')['CircleClose'] + const ElIconCirclePlus: typeof import('@element-plus/icons-vue')['CirclePlus'] + const ElIconDelete: typeof import('@element-plus/icons-vue')['Delete'] const ElIconPicture: typeof import('@element-plus/icons-vue')['Picture'] + const ElIconPlus: typeof import('@element-plus/icons-vue')['Plus'] const ElImage: typeof import('element-plus/es')['ElImage'] + const ElImageViewer: typeof import('element-plus/es')['ElImageViewer'] const ElInput: typeof import('element-plus/es')['ElInput'] const ElInputNumber: typeof import('element-plus/es')['ElInputNumber'] const ElMain: typeof import('element-plus/es')['ElMain'] @@ -112,4 +119,4 @@ declare global { const ElUpload: typeof import('element-plus/es')['ElUpload'] const RouterLink: typeof import('vue-router')['RouterLink'] const RouterView: typeof import('vue-router')['RouterView'] -} \ No newline at end of file +} diff --git a/src/pages/a-frame/UserInfoPanel.vue b/src/pages/a-frame/UserInfoPanel.vue index cf57738..603f26a 100644 --- a/src/pages/a-frame/UserInfoPanel.vue +++ b/src/pages/a-frame/UserInfoPanel.vue @@ -91,11 +91,10 @@ defineExpose({ + :upload-props="{ + accept: 'image/*', + listType:'picture' + }"> 点击上传头像 @@ -116,10 +115,11 @@ defineExpose({ } } -.avatar-uploader { + +:deep(.a-uploader) { width 100%; - :deep(.el-upload) { + .el-upload { width 100%; & > button { diff --git a/src/pages/gds/goods-category/GoodsCategory.vue b/src/pages/gds/goods-category/GoodsCategory.vue index 615380a..79244ac 100644 --- a/src/pages/gds/goods-category/GoodsCategory.vue +++ b/src/pages/gds/goods-category/GoodsCategory.vue @@ -5,25 +5,46 @@ :left-tools="leftTools" :paging="paging"> @@ -38,9 +59,60 @@ import FormPage, { type ActionColumnType, type ToolType, } from '@/components/page/FormPage.vue' +import Times from '@/common/utils/times.ts' const goodsCategoryFormIns = useTemplateRef>('goodsCategoryForm') const formPageIns = useTemplateRef>('formPage') +const createTimeDefaultTime: [ Date, Date ] = [ + Times.toDate(Times.beginOfDay()), + Times.toDate(Times.endOfDay()), +] +const bizList = [ + { + value: 'ZaiShengPin', + label: '再生品', + }, + { + value: 'HuiShouPin', + label: '回收品', + }, + { + value: 'QiTa', + label: '其他', + }, +] + +const shortcuts = [ + { + text: '今天', + value: () => [ Times.toDate(Times.beginOfDay()), Times.toDate(Times.endOfDay()) ], + }, + { + text: '昨天', + value: () => { + const time = Times.now().minus({day: 1}) + return [ Times.toDate(Times.beginOfDay(time)), Times.toDate(Times.endOfDay(time)) ] + }, + }, + { + text: '本周', + value: () => { + return [ Times.toDate(Times.beginOfWeek()), Times.toDate(Times.endOfWeek()) ] + }, + }, + { + text: '本月', + value: () => { + return [ Times.toDate(Times.beginOfMonth()), Times.toDate(Times.endOfMonth()) ] + }, + }, + { + text: '今年', + value: () => { + return [ Times.toDate(Times.beginOfYear()), Times.toDate(Times.endOfYear()) ] + }, + }, +] const leftTools: ToolType[] = [ { icon: 'Plus', @@ -83,6 +155,11 @@ function research() { } function paging(param: GoodsCategoryTypes.SearchGoodsCategoryParam) { - return GoodsCategoryApi.paging(param) + return GoodsCategoryApi.paging({ + bizType: param.bizType, + categoryName: param.categoryName, + createTimeStart: param.createTimes?.[0] ? Times.format(param.createTimes[0]) : undefined, + createTimeEnd: param.createTimes?.[1] ? Times.format(param.createTimes[1]) : undefined, + }) } diff --git a/src/pages/gds/goods-category/GoodsCategoryForm.vue b/src/pages/gds/goods-category/GoodsCategoryForm.vue index 3af0a99..ba62a43 100644 --- a/src/pages/gds/goods-category/GoodsCategoryForm.vue +++ b/src/pages/gds/goods-category/GoodsCategoryForm.vue @@ -6,124 +6,128 @@ - + - + - - - + - - - + - +