@fe-free/core 3.0.20 → 3.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/package.json +2 -2
- package/src/crud/crud.tsx +1 -0
- package/src/route/index.tsx +2 -1
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fe-free/core",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.22",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./src/index.ts",
|
|
6
6
|
"author": "",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"safe-stable-stringify": "^2.5.0",
|
|
42
42
|
"vanilla-jsoneditor": "^0.23.1",
|
|
43
43
|
"zustand": "^4.5.4",
|
|
44
|
-
"@fe-free/tool": "3.0.
|
|
44
|
+
"@fe-free/tool": "3.0.22"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"@ant-design/pro-components": "2.8.9",
|
package/src/crud/crud.tsx
CHANGED
|
@@ -111,6 +111,7 @@ function CRUD<DataSource extends Record<string, any> = any, Key extends string |
|
|
|
111
111
|
const operateColumn = {
|
|
112
112
|
title: '操作',
|
|
113
113
|
fixed: 'right',
|
|
114
|
+
align: 'center',
|
|
114
115
|
width: operateColumnProps?.width || 80,
|
|
115
116
|
render: function (_, record) {
|
|
116
117
|
const btns: React.ReactNode[] = [];
|
package/src/route/index.tsx
CHANGED
|
@@ -33,7 +33,8 @@ const routeTool = {
|
|
|
33
33
|
params?: Record<string, string>;
|
|
34
34
|
searchParams?: Record<string, string>;
|
|
35
35
|
}) => {
|
|
36
|
-
|
|
36
|
+
const sp = new URLSearchParams(searchParams);
|
|
37
|
+
return `${routeTool.getBaseName()}${generatePath(path, params)}${searchParams ? `?${sp.toString()}` : ''}`;
|
|
37
38
|
},
|
|
38
39
|
setSearchParams: (sp: Record<string, any>) => {
|
|
39
40
|
const url = new URL(window.location.href);
|