PDA

View Full Version : Doubt about components



ricmelga
7 Aug 2017, 4:00 PM
I am looking a pareto chart example in http://examples.sencha.com/extjs/6.5.1/examples/kitchensink/?classic#combination-pareto that in source code shows "xtype: 'combination-pareto'" and when I go to the Architect don´t find that component

56745

¿Where can I find the pareto chart?

petr.vecera
8 Aug 2017, 12:32 AM
Hi

The top xtype in that class defines the xtype of the new class you are creating. So there is no xtype combination-pareto in the framework.

When you check the source code you can see that example, the whole class is panel (extend Ext.Panel).

That panel has 1 item a that's cartesian that's the chart component you are looking for.

What it makes "pareto" chart is the fact that when you look into the series config, you can see that it has 2 series, one is bar and the second one is line.

I hope it makes sense :)

Cheers
Petr

ricmelga
8 Aug 2017, 7:04 AM
Hi

The top xtype in that class defines the xtype of the new class you are creating. So there is no xtype combination-pareto in the framework.

When you check the source code you can see that example, the whole class is panel (extend Ext.Panel).

That panel has 1 item a that's cartesian that's the chart component you are looking for.

What it makes "pareto" chart is the fact that when you look into the series config, you can see that it has 2 series, one is bar and the second one is line.

I hope it makes sense :)

Cheers
Petr

Thanks Petr! Now I added the class but getting compilation error. Apparently is not finding Ext.ux.Gauge. What is missing?

petr.vecera
8 Aug 2017, 7:34 AM
Hm I am not sure why it needs that class but OK.

First make sure that you have that class in the requires in that class http://prntscr.com/g5xk9q if it's not there, just add it manually.

Second, Click on Library -> Library requires, if it's not there , add ux there. http://prntscr.com/g5xkoy

Save project, Or click on Restart App Watch and it should run.



These requires are usually handled by SA automatically but in some cases you need to set them up manually.