Socket
Book a DemoInstallSign in
Socket

globalize3-jquery-autocomplete

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

globalize3-jquery-autocomplete

bundlerRubygems
Version
0.1.0
Version published
Maintainers
1
Created
Source

globalize3-jquery-autocomplete

Build Status

Use JQuery autocomplete (via rails3-jquery-autocomplete) with globalize3 translated ActiveRecord models.

Internals: This gem patches the get_autocomplete_items method (provided by rails3-jquery-autocomplete) so it works with translated model columns.

Compatibility

rails3-jquery-autocomplete 1.0 and globalize3 0.3 are supported.

Installation

This gem is not yet available via rubygems.

Add this line to your application's Gemfile:

gem 'globalize3-jquery-autocomplete', :git => 'https://github.com/emjot/globalize3-jquery-autocomplete.git'

And then execute:

$ bundle

Usage

Simply follow the documentation at globalize3 for how to translate your models and rails3-jquery-autocomplete for how to set up autocomplete.

You don't need any additional configuration. As soon as a column is translated, autocomplete will automatically be in context of the current locale.

Example (in your controller):

# query for matches in the current locale (given the 'name' column of your Brand model is translated):
autocomplete :brand, :name

Contributing

  • Fork it
  • Create your feature branch (git checkout -b my-new-feature)
  • Commit your changes (git commit -am 'Add some feature')
  • Push to the branch (git push origin my-new-feature)
  • Create new Pull Request

FAQs

Package last updated on 27 Mar 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts