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

组件内部通过api获取到某些数据,如何用这些数据去反向修改右侧编辑框中的数据呢? #595

Closed
microNewLife opened this issue Apr 22, 2024 · 3 comments

Comments

@microNewLife
Copy link

microNewLife commented Apr 22, 2024

如题,之前查找issue,并没遭到类似的答案,现在是可以通过editor来修改,那在组件中 如何修改这些数据呢?

@jia000
Copy link
Collaborator

jia000 commented Apr 23, 2024

无法做到,也不建议这样做,是什么场景需要这样?

@microNewLife
Copy link
Author

那是否是我使用上有错误呢?比如组件中展示某些数据,可以从api中获取也可以手动编辑;当从api获取的时候,需要同步修改编辑框中对应的数据,以免组件展示的数据与编辑框中的数据不一致。

@jia000
Copy link
Collaborator

jia000 commented Apr 25, 2024

应该在formConfig中配置一个select,这个select可以是remote模式,通过api获取下拉列表,然后用户配置的时候选择列表中的某一项后,在onChange中取设置其他配置数据

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

2 participants