mardi 15 avril 2014

ExtJs 4 Charts Tool tip issue.

I've implemented a multi series {more than one y-series} chart in extjs 4 for my client. Now the problem is, I have 3 vendors as Y-series like ["Vendor1", "Vendor2", "Vendor3"] and the corresponding data as [100,98,98]. I have implemented tooltips for the chart and it shows the correct data value but the wrong ySeries value if 2 ySeries have same value like 98,98. In this case it shows ["Vendor2",98] for both vendor2 and vendor3 under May-2011.

As shown in the image attached,

Code I've used is:

var label;

var position;

for(var i=0; i< ySeries.length; i++)

{

position = i;

//alert(storeItem.get(xCol)+'....'+storeItem.get(ySeries[i])+'....'+ySeries[i]+'........'+item.value[1]+'.......'+ySeries);

if(item.value[1] == storeItem.get(ySeries[i]))

{

label = ySeries[i];

break;

}

}

As soon as it matches the item.value[1] with the storeItem.get(ySeries[i]) it is giving the corresponding ySeries label. Please suggest me some other way to work around for the correct label.


Note : storeItem.get(xColumn) doesnt help me anything.Ideas regarding storeItem, record are needed as I'm not aware of them


Thanks in advance,

Satya Dileep Kumar.





Aucun commentaire:

Enregistrer un commentaire