I have a categories dropdown list in the grid that i am populating very similar to the 'Editing custom editor' example. I populate the default categories in the index() method of my controller, just like the example shows and it works fine. When a 'organization dropdownlist' is chosen, I want to repopulate the categories based on what organization was chosen, but when I try to 'Add new record' in the grid, the old categories remain bound to the grid and it doesn't save properly.
I have in my grid something similar to this defined for the default value:
model.Field(p => p.Category).DefaultValue(ViewData["defaultCategory"] as Kendo.Mvc.Examples.Models.CategoryViewModel);
Every time a new organization dropdown item is chosen, and a read operation occurs, how would I update or rebind the model to reflect the new defaultCategory?
Thanks in advance,
Dave