We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
请教个问题,和 list item 编辑有关,因为不知道如何描述标题,我就直接在微信群提问了,感谢
需求背景: 以在线demo 为例:https://vipshop.github.io/ams/example/#/cases-sence/add-item-action
表格现在是显示 全部的字段,而实际的需求是: 假如后端接口返回了 10个字段,其实显示在表格中,只是常见的 5个字段即可(配置在 resource 的 fields 字段中)
在【弹窗编辑】中希望可以编辑的 10个 fields ,这个需要怎么做呢?
editItemDialog 这个可以举一个例子吗?如何传入 Object 作为参数
The text was updated successfully, but these errors were encountered:
问题1: 你在resource里定义了10个字段,然后把不想显示的5个字段的hidden设置为true,在想显示的block,再定义同名的field,设置hidden为false
问题2: confirm、editItemDialog这些都是action,如果是在events里传参只能传字符串,如果是需要传复杂的参数,可以通过callAction()来调用和传参
Sorry, something went wrong.
问题1: 你在resource里定义了10个字段,然后把不想显示的5个字段的hidden设置为true,在想显示的block,再定义同名的field,设置hidden为false 问题2: confirm、editItemDialog这些都是action,如果是在events里传参只能传字符串,如果是需要传复杂的参数,可以通过callAction()来调用和传参
对问题2的回答做一些补充:
actions: { addItem: function({ item }) { this.callAction('addItemDialog') }, 'editItem': function() { // 唤起编辑 Dialog this.callAction('editItemDialog') }, }
No branches or pull requests
问题1
请教个问题,和 list item 编辑有关,因为不知道如何描述标题,我就直接在微信群提问了,感谢
需求背景:
以在线demo 为例:https://vipshop.github.io/ams/example/#/cases-sence/add-item-action
表格现在是显示 全部的字段,而实际的需求是:
假如后端接口返回了 10个字段,其实显示在表格中,只是常见的 5个字段即可(配置在 resource 的 fields 字段中)
在【弹窗编辑】中希望可以编辑的 10个 fields ,这个需要怎么做呢?
问题2
editItemDialog 这个可以举一个例子吗?如何传入 Object 作为参数
The text was updated successfully, but these errors were encountered: