fix: 修复 crud column 中 searchable 表单项为 input-date-range 时重置无法重置 extraName Close: #8389 (#8390)

* bump: 3.4.2

* fix: 修复 crud column 中 searchable 表单项为 input-date-range 时重置无法重置 extraName Close: #8389
This commit is contained in:
liaoxuezhi 2023-10-17 11:39:02 +08:00 committed by GitHub
parent ad37a26ca8
commit aae65411c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 20 additions and 13 deletions

View File

@ -5,5 +5,6 @@
"packages/amis-ui", "packages/amis-ui",
"packages/amis" "packages/amis"
], ],
"version": "3.4.1" "useWorkspaces": true,
"version": "3.4.2"
} }

View File

@ -1,6 +1,6 @@
{ {
"name": "amis-core", "name": "amis-core",
"version": "3.4.1", "version": "3.4.2",
"description": "amis-core", "description": "amis-core",
"main": "lib/index.js", "main": "lib/index.js",
"module": "esm/index.js", "module": "esm/index.js",
@ -46,7 +46,7 @@
"esm" "esm"
], ],
"dependencies": { "dependencies": {
"amis-formula": "*", "amis-formula": "^3.4.2",
"classnames": "2.3.2", "classnames": "2.3.2",
"file-saver": "^2.0.2", "file-saver": "^2.0.2",
"hoist-non-react-statics": "^3.3.2", "hoist-non-react-statics": "^3.3.2",

View File

@ -698,6 +698,9 @@ export const FormStore = ServiceStore.named('FormStore')
if (item.name && item.type !== 'hidden') { if (item.name && item.type !== 'hidden') {
setVariable(toClear, item.name, item.resetValue); setVariable(toClear, item.name, item.resetValue);
} }
if (item.extraName && typeof item.extraName === 'string') {
setVariable(toClear, item.extraName, item.resetValue);
}
}); });
setValues(toClear); setValues(toClear);
self.validated = false; self.validated = false;

View File

@ -1,6 +1,6 @@
{ {
"name": "amis-formula", "name": "amis-formula",
"version": "3.4.1", "version": "3.4.2",
"description": "负责 amis 里面的表达式实现,内置公式,编辑器等", "description": "负责 amis 里面的表达式实现,内置公式,编辑器等",
"main": "lib/index.js", "main": "lib/index.js",
"module": "esm/index.js", "module": "esm/index.js",

View File

@ -3,7 +3,7 @@
"main": "lib/index.js", "main": "lib/index.js",
"module": "esm/index.js", "module": "esm/index.js",
"types": "lib/index.d.ts", "types": "lib/index.d.ts",
"version": "3.4.1", "version": "3.4.2",
"description": "", "description": "",
"scripts": { "scripts": {
"build": "npm run clean-dist && NODE_ENV=production rollup -c ", "build": "npm run clean-dist && NODE_ENV=production rollup -c ",
@ -36,8 +36,8 @@
}, },
"dependencies": { "dependencies": {
"@rc-component/mini-decimal": "^1.0.1", "@rc-component/mini-decimal": "^1.0.1",
"amis-core": "^3.4.1", "amis-core": "^3.4.2",
"amis-formula": "^3.4.1", "amis-formula": "^3.4.2",
"classnames": "2.3.2", "classnames": "2.3.2",
"codemirror": "^5.63.0", "codemirror": "^5.63.0",
"downshift": "6.1.12", "downshift": "6.1.12",

View File

@ -1,6 +1,6 @@
{ {
"name": "amis", "name": "amis",
"version": "3.4.1", "version": "3.4.2",
"description": "一种MIS页面生成工具", "description": "一种MIS页面生成工具",
"main": "lib/index.js", "main": "lib/index.js",
"module": "esm/index.js", "module": "esm/index.js",
@ -37,8 +37,8 @@
} }
], ],
"dependencies": { "dependencies": {
"amis-core": "^3.4.1", "amis-core": "^3.4.2",
"amis-ui": "^3.4.1", "amis-ui": "^3.4.2",
"attr-accept": "2.2.2", "attr-accept": "2.2.2",
"blueimp-canvastoblob": "2.1.0", "blueimp-canvastoblob": "2.1.0",
"classnames": "2.3.2", "classnames": "2.3.2",

View File

@ -80,9 +80,12 @@ export function HeadCellSearchDropDown({
if (schema) { if (schema) {
Array.isArray(schema.body) && Array.isArray(schema.body) &&
schema.body.forEach( schema.body.forEach((item: any) => {
(item: any) => item.name && formItems.push(item.name) item.name && formItems.push(item.name);
); item.extraName &&
typeof item.extraName === 'string' &&
formItems.push(item.extraName);
});
schema = { schema = {
...schema, ...schema,
type: 'form', type: 'form',