VTable icon indicating copy to clipboard operation
VTable copied to clipboard

[Feature] 希望支持多维表指标自定义分组

Open Huangjiahui2233 opened this issue 1 year ago • 5 comments

What problem does this feature solve?

指标过多时可以自定义指标的分组,能够解决不同人查看同一个图表时能够迅速着重关心自己需要查看的数据。 类似ListTable中columns嵌套columns的效果

What does the proposed API look like?

image

图中仅为测试数据

分别将前两个指标和后两个指标分组为A类B类,指标在行时左侧新增一列显示分组,指标在列时上方新增一行显示分组。 和ListTable中columns相似的配置成这样应该就可以

const option = {
  indicator: [{
    title: 'A类',
    indicator: [{
      title: '达标首单商户数',
      indicatorKey: 'test1'
    },{
      title: '达标首单商户数占比',
      indicatorKey: 'test2'
    }]
  },{
    title: 'B类',
    indicator: [{
      title: '目标首单商户数',
      indicatorKey: 'test3'
    },{
      title: '目标首单商户数占比',
      indicatorKey: 'test4'
    }]
  }]
}

Huangjiahui2233 avatar Mar 11 '24 09:03 Huangjiahui2233

代码中的配置和图里画的不一致,领会意思就好

Huangjiahui2233 avatar Mar 11 '24 09:03 Huangjiahui2233

image 目前是可以自定义的 https://workspace-ws7ff8843a58ad4e8aba91c12c1e32f61c-http-5173.ide.byted.org/vtable/guide/table_type/Pivot_table/pivot_table_dataAnalysis image

fangsmile avatar Mar 12 '24 02:03 fangsmile

我看了下文档,好想和需求不太一样,这个是对维度进行自定义,我这边需要实现的是对指标进行分组自定义

Huangjiahui2233 avatar Mar 12 '24 03:03 Huangjiahui2233

维度和指标都包括了 整个树自定义 可以实现你的需求。你提的这个配置方式有些定制,最近也没有时间安排开发, 所以想要解决的话 可以用完整自定义的方式来做

fangsmile avatar Mar 12 '24 03:03 fangsmile

维度和指标都包括了 整个树自定义 可以实现你的需求。你提的这个配置方式有些定制,最近也没有时间安排开发, 所以想要解决的话 可以用完整自定义的方式来做

好的,谢谢

Huangjiahui2233 avatar Mar 12 '24 06:03 Huangjiahui2233