Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion for Select options having a different key and display #17

Open
avinashjoshi opened this issue Jul 29, 2015 · 3 comments
Open

Comments

@avinashjoshi
Copy link
Contributor

I can think of these two:

Option 1

var authors = {"values": [
    {"value": "1", "display": "Bob"}, 
    {"value": "2", "display": "John"}
]};

Option 2

var authors = {
    "display": ["Bob", "John", "Alice", "Jane"],
    "values": ["1", "TWO", "3", "4"]
};

I would like your thoughts before messing around and creating a PR

@lauris
Copy link
Member

lauris commented Feb 6, 2016

Normally select input element can have different key from display value, but Sensei Grid doesn't support hidden values for cells, so key and display value should be the same.

@lauris lauris closed this as completed Feb 6, 2016
@lauris lauris reopened this Feb 6, 2016
@timwis
Copy link

timwis commented Mar 3, 2016

I came here specifically looking for this feature as well, as it would enable you to show values for foreign keys (instead of the ID of the foreign record, some other, human-readable value from it). Any chance this could be supported or achieved somehow?

@kharitonovpavel
Copy link

Still need?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants