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

桑基图对数字的文本数据会造成显示异常🐛 [BUG] #2825

Closed
wuhuanyan opened this issue Aug 31, 2021 · 0 comments · Fixed by #2897
Closed

桑基图对数字的文本数据会造成显示异常🐛 [BUG] #2825

wuhuanyan opened this issue Aug 31, 2021 · 0 comments · Fixed by #2897
Labels
Bug Something isn't working

Comments

@wuhuanyan
Copy link

wuhuanyan commented Aug 31, 2021

🐛 Bug description

桑基图的数据如果带了数字的文本,显示的图形不正确

📷 Step to reproduce

1、在官方示例桑基图
2、修改DATA为

[
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 15726800.41},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 0},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 500000},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 928590.24},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 0},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 90000},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 7828281},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 2000384.93},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1", value: 205964.97},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "2", value: 20682265.98},
    {source: "1", target: "基本性零余额现金", value: 0},
    {source: "1", target: "基本性零余额用款额度", value: 500000},
    {source: "1", target: "日常公用经费", value: 928590.24},
    {source: "1", target: "累计结转", value: 0},
    {source: "1", target: "项目性零余额现金", value: 90000},
    {source: "1", target: "项目性零余额用款额度", value: 7828281},
    {source: "1", target: "项目支出", value: 2000384.93},
    {source: "1", target: "项目支出结转", value: 205964.97},
    {source: "1", target: "人员经费", value: 15726800.41},
    {source: "2", target: "人员经费", value: 20682265.98}
]

3、图形展示情况不对
image

🏞 Expected result

1、如果把"1"改成"1月份"、"2"改成"2月份"
2、即修改DATA为

[
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 15726800.41},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 0},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 500000},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 928590.24},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 0},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 90000},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 7828281},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 2000384.93},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "1月份", value: 205964.97},
    {source: "某某市某某区中国人民政治协商会议某某市某某区委员会办公室20192019", target: "2月份", value: 20682265.98},
    {source: "1月份", target: "基本性零余额现金", value: 0},
    {source: "1月份", target: "基本性零余额用款额度", value: 500000},
    {source: "1月份", target: "日常公用经费", value: 928590.24},
    {source: "1月份", target: "累计结转", value: 0},
    {source: "1月份", target: "项目性零余额现金", value: 90000},
    {source: "1月份", target: "项目性零余额用款额度", value: 7828281},
    {source: "1月份", target: "项目支出", value: 2000384.93},
    {source: "1月份", target: "项目支出结转", value: 205964.97},
    {source: "1月份", target: "人员经费", value: 15726800.41},
    {source: "2月份", target: "人员经费", value: 20682265.98}
]

3、则图形预览正常
image
4、期望予以修复

G2Plot Version: 官方示例
Platform: 官方示例

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant