Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
model_auto_completer provides autocompletion 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 model that corresponds to the selected completion. This version works with Ruby 1.8.7
Ruby
branch: master

This branch is 3 commits ahead of dipnlik:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
test
ChangeLog
MIT-LICENSE
README.rdoc
Rakefile
THANKS
about.yml
init.rb
install.rb
model_auto_completer.gemspec
uninstall.rb

README.rdoc

model_auto_completer

Project description

model_auto_completer provides auto completion for models. That is, the user autocompletes a text field, and the widget manages a hidden field that stores the ID of the selected model.

Fork description

This fork adds the :id_prefix option to have known IDs for both the text field and the hidden field (so they can be used via javascript or have an associated label).

It also replaces :append_random_suffix with an improved :append_suffix option, that not only allows for random suffixes but also for non-random suffixes.

Usage

This plugin offers three helpers and a class method for controllers. See the documentation of ModelAutoCompleterHelper.

Installation

To install this version of model_auto_completer run

script/plugin install https://github.com/dipnlik/model_auto_completer.git

In Rails 2 you need the auto_complete plugin as well:

script/plugin install auto_complete

Copyright

License

This code is available under the MIT license.

Something went wrong with that request. Please try again.