This is a migrated thread and some comments may be shown as answers.

Foreign key with the "values" property of the column

2 Answers 224 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Todd
Top achievements
Rank 1
Todd asked on 19 Oct 2012, 01:01 AM
I see the grid demo has a "foreign key" option where the "values" property of the grid column can point to a data-source, and will automatically build a drop-down widget for that column.  I also saw in a forum post where Telerik says the values object must have 2 properties (value and text).

The grid documentation page mentions nothing about the values property.  Is it documented anywhere???

2 Answers, 1 is accepted

Sort by
0
leniency
Top achievements
Rank 1
answered on 23 Oct 2012, 05:16 PM
It doesn't seem to be documented anywhere yet, unfortunetly.

I have a simple example here demonstrating foreign key columns, as well as a separate issue with group headers and foreign key columns.  Namely, the text part isn't used in the group header.  Also, sorting runs by the value part, not text, which can lead to unexpected results.

However, the example does show how filtering will automatically populate the available options from the column's values list.
0
Todd
Top achievements
Rank 1
answered on 24 Oct 2012, 02:52 AM
Ahh, you're right...I see that grouping problem.  With Telerik, the squeaky wheel usually gets the grease, so this will likely stay broken unless you push for it to be fixed.

Not documenting the foreign key feature is bad enough, but now that I think about it, even if they had documented it, it would have been a tiny one-liner about the feature....it would have said nothing about sort order or any detail.
Tags
Grid
Asked by
Todd
Top achievements
Rank 1
Answers by
leniency
Top achievements
Rank 1
Todd
Top achievements
Rank 1
Share this question
or