Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

field 能否支持object形式? #700

Open
YLeeXIE opened this issue May 16, 2024 · 0 comments
Open

field 能否支持object形式? #700

YLeeXIE opened this issue May 16, 2024 · 0 comments

Comments

@YLeeXIE
Copy link

YLeeXIE commented May 16, 2024

版本号 (version)
@form-create/ant-design-vue@2.5.27

UI 框架的版本 (UI version)
1.7.8

问题描述 (Issue):
field支持以对象的形式声明吗?value赋值后解构这个对象加入到formData中;类似于我自定义了这样一个组件
image
开始日期startDate和结束日期endData分别对应接口body的startData和endData;在UI中这是一个区域,但数据逻辑中其实这是两个数据,如果不声明field则这自定义组件就不能当成表单组件,而目前的field只支持字符串string,不支持对象每次初始化数据和提交数据都需要对数据二次处理,这对于公共组件来说是异常麻烦的

field支持以对象的形式存储,或者能以配置的方式对当初项的field值重写

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant