Skip to content

SinghSatyam/column_like

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Column Like

Gem Version

Security Feature

Code Complete

Code Coverage

Dependency Status

Column Like allows you to search using like query in ActiveRecord. It is:

  • LightWeight
  • Customizable
  • Available with every model

Getting started

Column Like works with ActiveRecord 3.0 onwards. You can add it to your Gemfile with:

gem 'column_like'

Run the bundle command to install it.

After you install Column Like and add it to your Gemfile, you need to run the generator:

rails generate column_like:install

You should restart your application after installing Column Like.

Usage

User.first_name_like('satyam')
User.last_name_like('satyam')
User.email_like('satyam')
User.first_name_like('saty%')
User.first_name_like('s_ty%')
User.first_name_like('%ty%')
User.first_name_like('%ty__')

Bug reports

If you discover a problem with Column Like, I would like to know about it. Send an email to satyam.mgs@gmail.com

Contribute

  1. Fork it ( http://github.com/SinghSatyam/column_like/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request