You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2020/09/26 10:52:03 UTC

[GitHub] [incubator-echarts] BiptJXu opened a new issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

BiptJXu opened a new issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348


   ### Version
   latest
   
   ### Steps to reproduce
   First, you need to define an array with repeated data, which is correct when drawn. However, if you modify the data "my_data[0]=140", you will find that the last data is also refreshed once.(CH:首先,你需要定义含有重复数据的数组,这时画出来时正确的。但是,如果你修改其中的数据“my_data[0]=140”,你会发现最后一个数据也刷新了一次)
   ```javascript
   var my_data=[130, 200, 150, 80, 70, 110, 130];
   my_data[0]=135;    //test code(is a example)
   option = {
       xAxis: {
           type: 'category',
           data: my_data
       },
       yAxis: {
           type: 'value'
       },
       series: [{
           data: my_data,
           type: 'bar'
       }]
   };
   ```
   This problem seems to have nothing to do with the version. Today, I also encountered this problem in the Example on the official website.(https://echarts.apache.org/examples/en/editor.html?c=bar-simple)
   
   ### What is expected?
   When the histogram(bar) has two duplicate data, modifying one will refresh the other at the same time, although I only want to show the change of one data.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个,虽然我只想展示一个数据的变化)
   
   ### What is actually happening?
   When modifying the first data, I found that the last data will also change, even though I only modified the first one in the array (when the first element is the same as the last one).
   CH:修改第一个数据时,发现最后一个数据也会变化,尽管我在数组中只修改了第一个(当第一个元素和最后一个相同时)。
   
   <!-- This issue is generated by echarts-issue-helper. DO NOT REMOVE -->
   <!-- This issue is in English. DO NOT REMOVE -->


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [incubator-echarts] echarts-bot[bot] commented on issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348#issuecomment-699478790


   Hi! We've received your issue and please be patient to get responded. 🎉
   The average response time is expected to be within one day for weekdays.
   
   In the meanwhile, please make sure that **you have posted enough image to demo your request**. You may also check out the [API](http://echarts.apache.org/api.html) and [chart option](http://echarts.apache.org/option.html) to get the answer.
   
   If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to dev@echarts.apache.org. Please attach the issue link if it's a technical questions.
   
   If you are interested in the project, you may also subscribe our [mail list](https://echarts.apache.org/en/maillist.html).
   
   Have a nice day! 🍵


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [incubator-echarts] Ovilia commented on issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348#issuecomment-700421872


   The animation does seem strange to me. Marked as a bug and hope someone can dive into the code and see why this is happening.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [incubator-echarts] Ovilia commented on issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

Posted by GitBox <gi...@apache.org>.
Ovilia commented on issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348#issuecomment-699576854


   Hi @BiptJXu ,
   
   I cannot reproduce your problem with
   ```js
   var my_data=[130, 200, 150, 80, 70, 110, 130];
   option = {
       xAxis: {
           type: 'category',
           data: my_data
       },
       yAxis: {
           type: 'value'
       },
       series: [{
           data: my_data,
           type: 'bar'
       }]
   };
   
   setTimeout(function() {
       my_data[0] = 1000;
       myChart.setOption(option);
   }, 1000);
   ```
   
   Could you make an online demo?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [incubator-echarts] BiptJXu commented on issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

Posted by GitBox <gi...@apache.org>.
BiptJXu commented on issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348#issuecomment-699578656


   Your code has the same meaning as I mean, which is great.
   
   When I run this code on the official website example (https://echarts.apache.org/examples/en/editor.html?c=bar-simple),
   
   The first step is correct.
   ![image](https://user-images.githubusercontent.com/45067585/94354878-013ebe80-00b2-11eb-9e1f-0c66f1477793.png)
   
   Second, when the function "SetTimeout" is executed, the data is changed. When rendering the chart, the last column of data was also refreshed, although I did not change it.
   This is only in the rendering process, it is a very short process, you must observe carefully, as I described in the screenshot.
   ![image](https://user-images.githubusercontent.com/45067585/94354823-bae95f80-00b1-11eb-8410-04b3695cb84a.png)
   
   Finally, I got the correct display. There is no problem in the last step, the problem appears in the second part.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [incubator-echarts] echarts-bot[bot] commented on issue #13348: When the bar has two duplicate data, modifying one will refresh the other at the same time.(CH:当柱状图有两个重复数据时,修改其中一个会同时刷新另外一个))

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #13348:
URL: https://github.com/apache/incubator-echarts/issues/13348#issuecomment-699576869


   @BiptJXu Please provide a demo for the issue either with https://codepen.io/Ovilia/pen/dyYWXWM or https://gallery.echartsjs.com/editor.html.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org