manipulating client side columns by name instead of index

2 posts, 0 answers
  1. Albert Shenker
    Albert Shenker avatar
    567 posts
    Member since:
    Mar 2004

    Posted 26 Feb 2016 Link to this post

    You guys ought to create .hide(), .show(), etc, or similar methods on your client-side GridColumn object. In that way, users will be able to get a reference to a particular column by UniqueName using the tableView method getColumnByUniqueName and perform actions, like hiding. As it stands, in order to hide a column, one must use the hideColumn method of the TableView object and this expects an index argument. Referencing grid column indexes leads to really fragile code since grid columns can be inserted/removed all the time and one might not think to look at some obscure javascript that depends on the order of columns.

    You could also add a get_index() method to the GridColumn which would facilitate obtaining the index without hard-coding it.

  2. Maria Ilieva
    Maria Ilieva avatar
    4017 posts

    Posted 02 Mar 2016 Link to this post

    Hello Albert,

    Thank you for the provided suggestions. You can use our feedback portal to log all the feature requests you want. Thus other users can vote for your item and increase its priority.
    As for the current requirements we will take them into account, but note that currently you can hide/show a column on the client using the approach demonstrated in the demo below:

    Maria Ilieva
    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
Back to Top