Hybrid View
-
7 Nov 2012 6:46 AM #1
Configure dynamic columns in gridpanel
Configure dynamic columns in gridpanel
How can I set column property of gridpanel to accept dynamic variable using Architect? I have a working extjs code (non-Architect) that defines column property like this:
var grid = Ext.create('Ext.grid.Panel', {
columns: {
items: gridColumns
where gridColumns is some variable I create when i get json from the server.
I need to recreate this code into Architect, but column property seems to always require at least one field to be present. Is there a way to set column property in Architect same way as I set it in non-Architect code?
Thank you.
-
7 Nov 2012 9:21 AM #2
radmila80 -
You can either dynamically call the reconfigure method to inject new columns or you can create an override and replace the columns.Aaron Conran
@aconran
Sencha Architect Development Team
-
7 Nov 2012 10:10 AM #3
Thank you for a quick reply. I do call grid reconfig to populate dynamic columns. I was looking for a way to make code less confusing and not having to declare unused column definition. My coworker suggested to manually update metadata file but we are not sure if it is a good idea.


Reply With Quote