Uploaded image for project: 'ZK Charts'
  1. ZK Charts
  2. ZKCHARTS-69

drill down failed with an error IndexOutOfBoundsException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 3.0.2
    • 3.0.0
    • None

      Steps to Reproduce

      1. load the attached zul
      2. click IE to drill down
      3. click v6.0 to drill down again

      Current Result

      SEVERE:
      java.lang.IndexOutOfBoundsException: Index: 5, Size: 5
      at java.util.LinkedList.checkElementIndex(LinkedList.java:555)
      at java.util.LinkedList.get(LinkedList.java:476)
      at org.zkoss.chart.Series.getPoint(Series.java:378)
      at org.zkoss.chart.ChartsEvent.getPoint(ChartsEvent.java:106)
      at support.charts.pie.PieDrilldownComposer.lambda$doAfterCompose$0(PieDrilldownComposer.java:45)
      at org.zkoss.zk.ui.AbstractComponent.onEvent(AbstractComponent.java:3162)
      at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3132)
      at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3074)
      ...

      Expected Result

      no error.

      Debug Information

      • this bug happens since 2.1.2-FL-20170619-Eval
      • sIndex in au request is always 0, but it should be 1 after the first drill down
        dtid: z_5rc
        cmd_0: onPlotDrillDown
        uuid_0: dFDP1
        data_0: {"sIndex":0,"pIndex":9,"category":"v3.5"}
      • Charts.service()
        			} else if (ChartsEvents.ON_PLOT_DRILL_DOWN.equals(cmd)) {
        				int sIndex = AuRequests.getInt(data, "sIndex", -1);
        				ChartsEvent evt = null;
        				if (sIndex == 0) {// first time drilldown
        					evt = ChartsEvent.getChartsEvent(request);
        				} else {
        					...
        				}
        

        1. Browser.java
          1 kB
        2. BrowserMarketShare.java
          5 kB
        3. pie-drilldown.zul
          0.4 kB
        4. PieDrilldownComposer.java
          4 kB

            rudyhuang rudyhuang
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 hours
                3h