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

希望列表生成器组件有默认数据,方便操作 #172

Closed
raoenhui opened this issue Jul 18, 2022 · 2 comments
Closed

希望列表生成器组件有默认数据,方便操作 #172

raoenhui opened this issue Jul 18, 2022 · 2 comments
Assignees
Labels
urgent Top priority

Comments

@raoenhui
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
使用表格生成器新增组件时,无法看到效果
Describe the solution you'd like
希望表头名称有默认值,另外有开放api开放兜底数据
image

@raoenhui raoenhui added the urgent Top priority label Jul 21, 2022
@helloqian12138
Copy link
Collaborator

helloqian12138 commented Jul 21, 2022

可以通过 Generator 的自定义属性面板功能来实现
示例代码如下:
{ 'ui:type': 'text', type: 'string', group: '基础组件库', fieldKey: 'mock_builtin_text', title: '内置文本', attrSchema: [ { name: 'title', group: '组件属性', 'ui:title': '表头名称', 'ui:type': 'text', type: 'string', default: '文本', }, { name: 'options.defaultValue', group: '组件属性', 'ui:title': '兜底文案', 'ui:type': 'input', 'ui:description': { trigger: 'hover', type: 'icon', title: '当数据不下发时展示的兜底文案', }, default: '文案', }, ] }
具体参考文档链接:https://drip-table.jd.com/drip-table-generator/props/custom-component-panel

@raoenhui
Copy link
Collaborator Author

image

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

No branches or pull requests

3 participants