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

Reply via email to