From d6ef1fe9c11506bbb47f4bb369145ac0b5786e73 Mon Sep 17 00:00:00 2001 From: yufei0306 <13417315+yufei0306@user.noreply.gitee.com> Date: Tue, 23 Apr 2024 08:39:00 +0800 Subject: [PATCH 01/31] =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E6=9D=A1=E4=BB=B6?= =?UTF-8?q?=E6=8E=92=E5=BA=8F&=E9=87=87=E8=B4=AD=E8=AE=A2=E5=8D=95?= =?UTF-8?q?=E5=8A=A0=E7=89=A9=E6=96=99=E6=9F=A5=E8=AF=A2=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.wyf | 22 ++++++++++++------- src/components/Search/src/Search.vue | 15 +++++++++++++ src/components/Table/src/Table.vue | 10 ++++----- src/components/rowDrop/index.vue | 10 ++++----- src/hooks/web/useCrudSchemas.ts | 3 ++- .../purchaseMain/purchaseMain.data.ts | 2 ++ .../supplierinvoiceRecordMain.data.ts | 12 +++++----- .../supplierinvoiceRequestMain.data.ts | 12 +++++----- 8 files changed, 55 insertions(+), 31 deletions(-) diff --git a/.env.wyf b/.env.wyf index 77639491b..a957ea11d 100644 --- a/.env.wyf +++ b/.env.wyf @@ -3,16 +3,16 @@ NODE_ENV=test VITE_DEV=false -# 请求路径 -VITE_BASE_URL='http://192.168.0.108:12080' -# 上传路径 -VITE_UPLOAD_URL='http://192.168.0.108:12080/api/admin-api/infra/file/upload' +# # # # 请求路径 +# VITE_BASE_URL='http://192.168.0.108:12080' +# # 上传路径 +# VITE_UPLOAD_URL='http://192.168.0.108:12080/admin-api/infra/file/upload' -# # 请求路径 -# VITE_BASE_URL='http://dev.ccwin-in.com:25300/api' +# 请求路径 +VITE_BASE_URL='http://dev.ccwin-in.com:25300/api' -# # 上传路径 -# VITE_UPLOAD_URL='http://dev.ccwin-in.com:25300/api/admin-api/infra/file/upload' +# 上传路径 +VITE_UPLOAD_URL='http://dev.ccwin-in.com:25300/api/admin-api/infra/file/upload' # 接口前缀 VITE_API_BASEPATH= @@ -40,3 +40,9 @@ VITE_INTERFACE_URL='http://192.168.0.108:12080/magic/web/index.html' # 积木报表请求路径 VITE_JMREPORT_BASE_URL='http://192.168.0.108:12080' + +# # 自定义接口路径 +# VITE_INTERFACE_URL='http://dev.ccwin-in.com:25310/magic/web/index.html' + +# # 积木报表请求路径 +# VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25310' diff --git a/src/components/Search/src/Search.vue b/src/components/Search/src/Search.vue index 78865acf7..3dd5b5ff3 100644 --- a/src/components/Search/src/Search.vue +++ b/src/components/Search/src/Search.vue @@ -66,8 +66,23 @@ const newSchema = computed(() => { } ]) } + updateSort(schema) return schema }) +const updateSort= (val)=>{ + val.forEach(item=>{ + if(!item.sortSearchDefault){ + if(item.field=="action"){ + item.sortSearchDefault = 9999 // 查询重置等操作按钮 + }else{ + item.sortSearchDefault = 999 // 默认999 + } + } + }) + val.sort((column1,column2)=>{ + return column1.sortSearchDefault - column2.sortSearchDefault + }) +} const { register, elFormRef, methods } = useForm({ model: props.model || {} diff --git a/src/components/Table/src/Table.vue b/src/components/Table/src/Table.vue index a7a988359..97a05b433 100644 --- a/src/components/Table/src/Table.vue +++ b/src/components/Table/src/Table.vue @@ -250,18 +250,18 @@ export default defineComponent({ // 默认排序 const updateSort= (val)=>{ val.forEach(item=>{ - if(!item.sortDefault){ + if(!item.sortTableDefault){ if(item.fixed=='left'){ - item.sortDefault = 0 + item.sortTableDefault = 0 }else if(item.fixed=='right'){ - item.sortDefault = 9999 + item.sortTableDefault = 9999 }else{ - item.sortDefault = 999 // 默认999 + item.sortTableDefault = 999 // 默认999 } } }) val.sort((column1,column2)=>{ - return column1.sortDefault - column2.sortDefault + return column1.sortTableDefault - column2.sortTableDefault }) } diff --git a/src/components/rowDrop/index.vue b/src/components/rowDrop/index.vue index a8333f833..20eecf240 100644 --- a/src/components/rowDrop/index.vue +++ b/src/components/rowDrop/index.vue @@ -202,18 +202,18 @@ const initSelectSta = () => { } const updateSort= (val)=>{ val.forEach(item=>{ - if(!item.sortDefault){ + if(!item.sortTableDefault){ if(item.fixed=='left'){ - item.sortDefault = 0 + item.sortTableDefault = 0 }else if(item.fixed=='right'){ - item.sortDefault = 9999 + item.sortTableDefault = 9999 }else{ - item.sortDefault = 999 // 默认999 + item.sortTableDefault = 999 // 默认999 } } }) val.sort((column1,column2)=>{ - return column1.sortDefault - column2.sortDefault + return column1.sortTableDefault - column2.sortTableDefault }) } // 更新主列表字段 diff --git a/src/hooks/web/useCrudSchemas.ts b/src/hooks/web/useCrudSchemas.ts index 1028821e3..f74c14467 100644 --- a/src/hooks/web/useCrudSchemas.ts +++ b/src/hooks/web/useCrudSchemas.ts @@ -140,7 +140,8 @@ const filterSearchSchema = (crudSchema: CrudSchema[], allSchemas: AllSchemas): F component, ...schemaItem.search, field: schemaItem.field, - label: schemaItem.search?.label || schemaItem.label + label: schemaItem.search?.label || schemaItem.label, + sortSearchDefault: schemaItem.sortSearchDefault || 999, }, { componentProps: comonentProps } ) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts b/src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts index 7c4f18e26..8fa7bef6d 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts @@ -68,6 +68,7 @@ export const PurchaseMain = useCrudSchemas(reactive([ isTable: true, isForm:false, isSearch: true, + sortSearchDefault:1000, sort: 'custom', table: { width: 150 @@ -401,6 +402,7 @@ export const PurchaseDetail = useCrudSchemas(reactive([ { label: '物料代码', field: 'itemCode', + isSearch: true, table: { width: 150 }, diff --git a/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRecordMain/supplierinvoiceRecordMain.data.ts b/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRecordMain/supplierinvoiceRecordMain.data.ts index d686f530c..12d78a6e6 100644 --- a/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRecordMain/supplierinvoiceRecordMain.data.ts +++ b/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRecordMain/supplierinvoiceRecordMain.data.ts @@ -365,7 +365,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ label: '创建者', field: 'creator', sort: 'custom', - sortDefault:1000, + sortTableDefault:1000, table: { width: 150 }, @@ -374,7 +374,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ label: '创建时间', field: 'createTime', isTable: true, - sortDefault:1001, + sortTableDefault:1001, formatter: dateFormatter, detail: { dateFormat: 'YYYY-MM-DD HH:mm:ss' @@ -387,7 +387,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ { label: '采购审批人', field: 'procurementCreator', - sortDefault:1002, + sortTableDefault:1002, sort: 'custom', table: { width: 150 @@ -397,7 +397,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ { label: '采购审批时间', field: 'procurementCreateTime', - sortDefault:1003, + sortTableDefault:1003, isTable: true, formatter: dateFormatter, detail: { @@ -412,7 +412,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ { label: '财务审批用户名', field: 'financialCreator', - sortDefault:1004, + sortTableDefault:1004, sort: 'custom', table: { width: 150 @@ -422,7 +422,7 @@ export const SupplierinvoiceRecordMain = useCrudSchemas(reactive([ { label: '财务审批时间', field: 'financialCreateTime', - sortDefault:1005, + sortTableDefault:1005, isTable: true, formatter: dateFormatter, detail: { diff --git a/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts b/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts index 76534660f..fd31f58fb 100644 --- a/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts +++ b/src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts @@ -414,7 +414,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( table: { width: 150 }, - sortDefault:1001, + sortTableDefault:1001, isForm: false, }, { @@ -422,7 +422,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( field: 'createTime', isTable: true, formatter: dateFormatter, - sortDefault:1000, + sortTableDefault:1000, detail: { dateFormat: 'YYYY-MM-DD HH:mm:ss' }, @@ -468,7 +468,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( label: '采购审批人', field: 'procurementCreator', sort: 'custom', - sortDefault:1003, + sortTableDefault:1003, table: { width: 150 }, @@ -478,7 +478,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( label: '采购审批时间', field: 'procurementCreateTime', isTable: true, - sortDefault:1004, + sortTableDefault:1004, formatter: dateFormatter, detail: { dateFormat: 'YYYY-MM-DD HH:mm:ss' @@ -502,7 +502,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( label: '财务审批时间', field: 'financialCreateTime', isTable: true, - sortDefault:1005, + sortTableDefault:1005, formatter: dateFormatter, detail: { dateFormat: 'YYYY-MM-DD HH:mm:ss' @@ -518,7 +518,7 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive( field: 'supplierCreator', sort: 'custom', isTable:false, - sortDefault:1006, + sortTableDefault:1006, table: { width: 180 }, From 63417765bdc1dfa00b78961c53be8470c7bd154b Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Tue, 23 Apr 2024 08:47:46 +0800 Subject: [PATCH 02/31] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wms/agvManage/interfaceInfo/index.vue | 10 +++---- .../interfaceInfo/interfaceInfo.data.ts | 30 +++++++++++++++++++ 2 files changed, 35 insertions(+), 5 deletions(-) diff --git a/src/views/wms/agvManage/interfaceInfo/index.vue b/src/views/wms/agvManage/interfaceInfo/index.vue index f89506d15..15fcdb1bc 100644 --- a/src/views/wms/agvManage/interfaceInfo/index.vue +++ b/src/views/wms/agvManage/interfaceInfo/index.vue @@ -27,9 +27,9 @@ v-model:currentPage="tableObject.currentPage" v-model:sort="tableObject.sort" > -