Skip to content
This repository has been archived by the owner on Aug 21, 2019. It is now read-only.

Select field ordering #1

Open
afeld opened this issue Feb 3, 2011 · 1 comment
Open

Select field ordering #1

afeld opened this issue Feb 3, 2011 · 1 comment
Labels

Comments

@afeld
Copy link
Owner

afeld commented Feb 3, 2011

There should be a way to specify the ordering of select options passed in as a hash, either through :data or another param. Perhaps accepting two-dimensional array to :data instead?

editable_field @user, :zip_code, :data => [['visa', 'Visa'], ['mastercard', 'Mastercard'], ['amex', 'American Express']]
@tranquiliste
Copy link

Agree, Option are sorted by the key, not in the order you provide the data.
Any idea on what to modify to make the order in the data the order in the select?

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

No branches or pull requests

2 participants