Hi,

Thanks for the tip.

The example shows a grid being fed from a store which has a reader attatched 
which reads xml data.

I´m not quite sure how to adapt this to the property grid. How on earth can I 
attatch a reader to the "event.feature.attributes" array which is obtained from 
 "layer_wea.events.on"

Bare in mind the propertygrid turns database column headers into rows

yours,

Rob







________________________________
Von: Alexandre Dube <ad...@mapgears.com>
An: users@geoext.org
Gesendet: Mittwoch, den 17. August 2011, 14:22:55 Uhr
Betreff: Re: [Users] popup Field alias possible?

The Ext edit-grid example shows a grid with user-specified headers :

http://dev.sencha.com/deploy/ext-3.3.1/examples/grid/edit-grid.html

Regards,

Alexandre


On 11-08-17 04:02 AM, Robert Buckley wrote: 
Hi
>
>
>i have a popup which lists the attributes from my wfs layer           in a 
>PropertyGrid. This looks really great, but my Fieldnames           are coded 
>and 
>have little meaning on first glance. I would           like to assign aliases 
>to 
>the Fields and show them in the           EditorGrid.
>
>
>Has anyone done this, or does anyone have a workaround?
>
>
>
>
>Yours,
>
>
>Rob
>
>
><code>
>
>
>var popup_wea
>    layer_wea.events.on({
>        featureselected: function (event) {
>            var propsGrid = new Ext.grid.PropertyGrid({
>                autoHeight: true,
>                source: event.feature.attributes
>            });
>            propsGrid.getColumnModel().setColumnHeader(0,             
>'EIGENSCHAFT');
>            propsGrid.getColumnModel().setColumnHeader(1,             'WERT');
>           popup_wea = new GeoExt.Popup({
>                id: 'popup_wea',
>                title: "Informationen",
>                feature: event.feature,
>                collapsible: true,
>                layout: "fit",
>                autoHeight: true,
>                panIn: true,
>                width: 270,
>                unpinnable: true,
>                border: false,
>                items: [propsGrid],
>            listeners: {
>               "close": function() {
>                select.unselect(this.feature);
>                            }
>                        }
>            });
>//             unselect feature when the popup is closed
>        popup_wea.on({
>            close: function() {
>                            
>if(OpenLayers.Util.indexOf(layer_wea.selectedFeatures,             
>this.feature) 
>> -1) {
>                    select.unselect(this.feature);
>                      }
>            }
>        });
>            popup_wea.show();
>
>
>        },
>        featureunselected: function (event) {
>            popup_wea.destroy();
>        }
>    });
>
>
></code>
> _______________________________________________ Users mailing list 
>Users@geoext.org http://www.geoext.org/cgi-bin/mailman/listinfo/users 
>


--  Alexandre Dubé Mapgears www.mapgears.com 
_______________________________________________
Users mailing list
Users@geoext.org
http://www.geoext.org/cgi-bin/mailman/listinfo/users

Reply via email to