[ANN] model_auto_completer plugin

Just a brief email to announce the first release of
model_auto_completer.

model_auto_completer provides auto completion for models. That is,
the user autocompletes a text field, but the widget is able to manage
a hidden field that stores the ID of the corresponding model.

Such a widget may be useful when the number of options is too much
for a select. Say you need to assign a director to a movie having a
database of hundreds of directors. With this plugin it is easy to let
the user autocomplete by director name, and have a robust database ID
managed under the hood.

The plugin has been designed following standard Rails idioms, so in
its most basic use case you just need to do this in the view:

<%= belongs_to_auto_completer :movie, :director, :fullname %>

There are a few configuration options, and a much more generic
helper. The home page documents everything. See

http://model-ac.rubyforge.org

This is my first plugin, any feedback will be very welcome!

– fxn

On Thursday 18 January 2007 19:34, Xavier N. wrote:

Just a brief email to announce the first release of
model_auto_completer.

model_auto_completer provides auto completion for models. That is,
the user autocompletes a text field, but the widget is able to manage
a hidden field that stores the ID of the corresponding model.

I haven’t tried it, but had a look at the code. Nice. I especially like
the use of a regexp to obtain the model id from the selected element.

Michael


Michael S.
mailto:[email protected]
http://www.schuerig.de/michael/