Display text from drop downlist after save item

2 posts, 0 answers
  1. Mateusz
    Mateusz avatar
    13 posts
    Member since:
    Jan 2015

    Posted 10 Dec 2015 Link to this post

    Hi

    I would like ask how to improve  example below to display text from drop down list after save item?

    https://github.com/telerik/ui-for-aspnet-mvc-examples/tree/master/grid/grid-editing-cascading-dropdownlist

    Drop down lists work as I need but after save I see id. How to change it to display text for example category name.

     

     

  2. Boyan Dimitrov
    Admin
    Boyan Dimitrov avatar
    1746 posts

    Posted 14 Dec 2015 Link to this post

    Hello Mateusz,

     

    In the current example the columns of the grid are bound to a property from integer type. In other words the "LicenseId" is a number and it will be shown as number. My suggestion is to bound the columns to complex object ( you can use the pattern shown in the Grid / Editing custom editor with Category field). The model field "Category" is a complex object and using template it is shown the text when cell is in read only mode. Just in case you can set valuePrimitive to false for the cascading DropDownLists in order to update the grid model with a complex object instead of just the number. 

     

    Regards,
    Boyan Dimitrov
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET MVC is VS 2017 Ready
Back to Top