Feb 12, 2014, 11:56 AM
Reload Store of GridPanel with DirectEvent Method
hi,
i got a GridPanel as follows:
My attempt fails.
Regards
EDIT: when i debug with firebug, i get the error msg:
ReferenceError: App is not defined
i got a GridPanel as follows:
Html.X().GridPanel()
.Title("Dateien")
.Width(600)
.Height(350)
.ID("Grid")
.Store(Html.X().Store()
.ID("TableStore")
.Model(Html.X().Model()
.Fields(
new ModelField("FullName", ModelFieldType.String),
new ModelField("Name", ModelFieldType.String),
new ModelField("Length", ModelFieldType.Int),
new ModelField("CreationTime", ModelFieldType.String)
)
)
.DataSource(Model.getObj())
)
.ColumnModel(
Html.X().Column().Text("FullName").DataIndex("FullName"),
Html.X().Column().Text("Name").DataIndex("Name"),
Html.X().Column().Text("Length").DataIndex("Length"),
Html.X().Column().Text("CreationTime").DataIndex("CreationTime")
)
by clicking on a node in a TreePanel, i call a Method in the controller to fill the GridPanel with data. (Model.getObj() is at the beginning an empty list) :public ActionResult GetGridPanel(string path)
{
Store store = this.GetCmp<Store>("TableStore");
FolderDataModel model = new FolderDataModel();
model.setObj(FolderDataModel.GetFiles(path));
store.DataSource = model.getObj();
store.DataBind();
return this.Direct();
}
model.getObj() receives - when i debug - the filled List of Objects. The question is now how can i load this store / List into the GridPanel's store?My attempt fails.
Regards
EDIT: when i debug with firebug, i get the error msg:
ReferenceError: App is not defined
Last edited by novacp; Feb 12, 2014 at 1:32 PM.
Reason: Error message