Skip to content

ProTable物料表格列 数据字段应支持ArraySetter #61

@Great-old-one

Description

@Great-old-one

Describe the bug (required) / 详细描述 bug(必填)

A clear and concise description of what the bug is. / 请提供清晰且精确的 bug 描述

高级组件ProTable(@seada/antd-materials [1.0.0-rc.29]),目前的数据字段仅支持StringSetter(这里不考虑变量绑定),但是在实际业务中可能是嵌套的数据结构,如下

const data=[
     {
       userInfo:{name:"张三",age:18},
       time:"2023-08-09"
     },
    {
       userInfo:{name:"李四",age:19},
       time:"2023-08-10"
     }
]

如果使用源码开发,我们可以这样获取name字段

const columns=[
     {
       title:"姓名",
       dataIndex:["userInfo","name"]
     },
    {
       title:"年龄",
       dataIndex:["userInfo","age"]
     },
    {
       title:"时间",
       dataIndex:"time"
     }
]

但是物料中却只能填入字符串,极大的增加了使用成本,希望优化
image

To Reproduce (required) / 如何复现 bug?(必填,非常重要)

Steps to reproduce the behavior: / 详细复现步骤:


English version example:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

中文版示例:

  1. 打开 demo
  2. 点击标题;
  3. 在右侧修改标题内容为「修改后的标题」;
  4. 渲染画布标题组件没有更新显示为「修改后的标题」;

Expected behavior (required) / 预期行为(必填,非常重要)

A clear and concise description of what did you expect to happen. / 请清晰和精确的描述你预期的行为


Screenshots (optional) / bug 截图(可选)

Sceenshots for further information. (If applicable.) / 一些有用的截图将会帮助我们更好的明确以及定位问题


Environments (please complete the following information) (required): / 请提供如下信息(必填)

  • AliLowCodeEngine version: [1.1.8-beta.3] / 低代码引擎版本
  • AliLowCodeEngineExt version: [1.0.6-beta.28] / 低代码引擎扩展包版本
  • Browser [e.g. chrome, safari] / 浏览器版本
  • materials / plugins / tools / 其他物料 / 插件 / 工具链版本
  • @seada/antd-materials [1.0.0-rc.29]

(this information can be collected via the manual plugin / 版本信息可通过低代码用户手册插件收集)

Additional context (optional) / 更多额外信息(可选)

Any other context of the problem here. / 可以追加更多的额外信息,帮助定位问题

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions