Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄庭坚
jinfa-platform
Commits
1aa900fd
Commit
1aa900fd
authored
Aug 02, 2021
by
XieZhiXiong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修复外部传入 onSubmit 不生效的问题
parent
5e5ffd62
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
5 deletions
+3
-5
NormalTable.tsx
src/components/PolymericTable/NormalTable.tsx
+2
-2
SearchForm.tsx
src/components/PolymericTable/SearchForm.tsx
+1
-3
No files found.
src/components/PolymericTable/NormalTable.tsx
View file @
1aa900fd
...
...
@@ -2,7 +2,7 @@
* @Author: XieZhiXiong
* @Date: 2020-08-20 16:15:59
* @LastEditors: XieZhiXiong
* @LastEditTime: 2021-0
7-29 14:08:56
* @LastEditTime: 2021-0
8-02 15:44:03
* @Description: 可以带查询的表格,内置 formily,如果需要其他Form可以传入 customRenderSearchForm 配合 reload() 实现查询
*/
import
React
,
{
useState
,
useEffect
,
useRef
,
useImperativeHandle
}
from
'react'
;
...
...
@@ -181,8 +181,8 @@ const NormalTable: React.ForwardRefRenderFunction<NormalTableRefHandleType, Norm
{
searchFormProps
&&
!
customRenderSearchForm
&&
(
<
SearchForm
value=
{
searchValues
}
{
...
searchFormProps
}
onSubmit=
{
handleSearchFormSubmit
}
{
...
searchFormProps
}
/>
)
}
{
customRenderSearchForm
&&
!
searchFormProps
&&
customRenderSearchForm
()
}
...
...
src/components/PolymericTable/SearchForm.tsx
View file @
1aa900fd
...
...
@@ -12,9 +12,7 @@ import NiceForm from '@/components/NiceForm';
const
formActions
=
createFormActions
();
export
interface
SearchFormIProps
extends
Omit
<
IAntdSchemaFormProps
,
'actions'
>
{
}
export
interface
SearchFormIProps
extends
IAntdSchemaFormProps
{}
const
SearchForm
:
React
.
FC
<
SearchFormIProps
>
=
(
props
)
=>
{
const
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment