The Features store is not the solution: -I have a WFS layer with a features store and a gridPanel, all it's good. My features have an attributes ID_SITE.
-I make Ajax request for load other data in a store and a second gridpanel. I want to link this data with my layer (or gridpanel), I can have more several rows for one features of the layers. My ideas is: when I click on my feature (on the map) I select the row of the feature in the gridpanel of the layer (it's ok) and I select the rows with the same ID_SITE in the second Panel. I think I can make an event (layer.event.on) with a function. Actually I can select the ID_SITE of my selected features but I don't know what do I do to select the rows with the same ID_SITE in my second gridpanel (gridpanel2.selectRows?). Pierre Giraud a écrit : > Actually, you don't really need to load the data twice. The features > in your layer should help you fill the grid. > Consider using a FeatureStore bound to your layer. > http://geoext.org/lib/GeoExt/data/FeatureStore.html > > var store = new Ext.data.FeatureStore({ > layer: yourLayer, > fields: [{ > ... > }] > }); > > Then use this store for your grid panel. > > Regards, > Pierre > > > 2010/6/2 François Boussuges <[email protected]>: > >> Hello, >> I have a question about the feature selection and the grid panel. >> >> I have a WFS layers with a grid panel, in this layer I have an ID_SITE >> attribute. >> In a second grid panel I load XML files (with Ajax), this files contains >> the ID_SITE attribute. >> >> When I select à features of my WFS layer (on the map or the gridpanel) >> what do I do to select automaticaly rows with the same ID_SITE in the >> second grid panel? >> >> Thank youvery much! >> >> François >> _______________________________________________ >> Users mailing list >> [email protected] >> http://www.geoext.org/cgi-bin/mailman/listinfo/users >> >> > > > > _______________________________________________ Users mailing list [email protected] http://www.geoext.org/cgi-bin/mailman/listinfo/users
