<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:arial, helvetica, sans-serif;font-size:10pt"><div>Hi,</div><div><br></div><div>Thanks for the tip.</div><div><br></div><div>The example shows a grid being fed from a store which has a reader attatched which reads xml data.</div><div><br></div><div>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"</div><div><br></div><div>Bare in mind the propertygrid turns database column headers into rows</div><div><br></div><div>yours,</div><div><br></div><div>Rob</div><div><br></div><div><br></div><div><br></div><div><br></div><div style="font-family:arial, helvetica, sans-serif;font-size:10pt"><br><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><font size="2" face="Tahoma"><hr size="1"><b><span
style="font-weight: bold;">Von:</span></b> Alexandre Dube <adube@mapgears.com><br><b><span style="font-weight: bold;">An:</span></b> users@geoext.org<br><b><span style="font-weight: bold;">Gesendet:</span></b> Mittwoch, den 17. August 2011, 14:22:55 Uhr<br><b><span style="font-weight: bold;">Betreff:</span></b> Re: [Users] popup Field alias possible?<br></font><br>
The Ext edit-grid example shows a grid with user-specified headers :<br>
<br>
<a rel="nofollow" class="moz-txt-link-freetext" target="_blank" href="http://dev.sencha.com/deploy/ext-3.3.1/examples/grid/edit-grid.html">http://dev.sencha.com/deploy/ext-3.3.1/examples/grid/edit-grid.html</a><br>
<br>
Regards,<br>
<br>
Alexandre<br>
<br>
<br>
On 11-08-17 04:02 AM, Robert Buckley wrote:
<blockquote type="cite">
<div style="font-family:arial, helvetica, sans-serif;
font-size:10pt;color:rgb(0, 0, 0);">
<div>Hi</div>
<div><br>
</div>
<div>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.</div>
<div><br>
</div>
<div>Has anyone done this, or does anyone have a workaround?</div>
<div><br>
</div>
<div><br>
</div>
<div>Yours,</div>
<div><br>
</div>
<div>Rob</div>
<div><br>
</div>
<div><code></div>
<div><br>
</div>
<div>
<div>var popup_wea</div>
<div> layer_wea.events.on({</div>
<div> featureselected: function (event) {</div>
<div> var propsGrid = new Ext.grid.PropertyGrid({</div>
<div> autoHeight: true,</div>
<div> source: event.feature.attributes</div>
<div> });</div>
<div> propsGrid.getColumnModel().setColumnHeader(0,
'EIGENSCHAFT');</div>
<div> propsGrid.getColumnModel().setColumnHeader(1,
'WERT');</div>
<div> popup_wea = new GeoExt.Popup({</div>
<div> id: 'popup_wea',</div>
<div> title: "Informationen",</div>
<div> feature: event.feature,</div>
<div> collapsible: true,</div>
<div> layout: "fit",</div>
<div> autoHeight: true,</div>
<div> panIn: true,</div>
<div> width: 270,</div>
<div> unpinnable: true,</div>
<div> border: false,</div>
<div> items: [propsGrid],</div>
<div> listeners: {</div>
<div> "close": function() {</div>
<div> select.unselect(this.feature);</div>
<div> }</div>
<div> }</div>
<div> });</div>
<div><span class="Apple-tab-span" style="white-space:pre;"> </span>//
unselect feature when the popup is closed</div>
<div> popup_wea.on({</div>
<div> close: function() {</div>
<div>
if(OpenLayers.Util.indexOf(layer_wea.selectedFeatures,
this.feature) > -1) {</div>
<div> select.unselect(this.feature);</div>
<div> }</div>
<div> }</div>
<div> });</div>
<div><span class="Apple-tab-span" style="white-space:pre;"> </span></div>
<div><span class="Apple-tab-span" style="white-space:pre;"> </span></div>
<div> popup_wea.show();</div>
<div><span class="Apple-tab-span" style="white-space:pre;"> <br>
</span></div>
<div> },</div>
<div> featureunselected: function (event) {</div>
<div> popup_wea.destroy();</div>
<div> }</div>
<div><span class="Apple-tab-span" style="white-space:pre;"> </span></div>
<div> });</div>
</div>
<div><br>
</div>
<div></code></div>
</div>
<pre><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a rel="nofollow" class="moz-txt-link-abbreviated" ymailto="mailto:Users@geoext.org" target="_blank" href="mailto:Users@geoext.org">Users@geoext.org</a>
<a rel="nofollow" class="moz-txt-link-freetext" target="_blank" href="http://www.geoext.org/cgi-bin/mailman/listinfo/users">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature">--
Alexandre Dubé
Mapgears
<a rel="nofollow" class="moz-txt-link-abbreviated" target="_blank" href="http://www.mapgears.com">www.mapgears.com</a>
</pre>
</div></div><div style="position:fixed"></div>
</div></body></html>