ant-design / ant-design/pro-components

🧐[问题] EditableProTable 和 ProForm 联动

Open
#8,300 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
4.8k
Forks
1.4k
Avg merge
10h 44m
Merged PRs (30d)
3

Description

提问前先看看:

https://github.com/ryanhanwu/How-To-Ask-Questions-The-Smart-Way/blob/main/README-zh_CN.md

### 🧐 问题描述

### 💻 示例代码

我自己写了一个文件上传的组件,通过EditableProTable提供的renderFormItem绑定,我发现如果在EditableProTable外面套一个ProForm,编辑/保存的时候我的信息会丢失?我的字段变成一个空object,如果没有ProForm就是正常的,这是Bug吗?
### 🚑 其他信息

保存前
![image](https://github.com/ant-design/pro-components/assets/73346429/212062d1-c326-4c8c-bb2d-43b469f1c1c2)
保存后,信息丢失了(有跟ProForm绑定)
![image](https://github.com/ant-design/pro-components/assets/73346429/3743519f-351c-4abb-b959-cf5297e11972)

我用官方示例codesandbox修改了一下,能够复现这种情况:
https://codesandbox.io/p/sandbox/zi-ding-yi-ke-bian-ji-biao-ge-forked-2fqkkx

Contributor guide

Open the contributing guide

Research direction

Start with the linked CodeSandbox reproduction and inspect the EditableProTable renderFormItem integration with ProForm. Compare edit/save behavior with and without the surrounding ProForm; done means the custom upload field retains its object value after saving.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.