No commit activity in last 3 years
No release in over 3 years
It adds possibility for sorting relation
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Runtime

>= 4.2.0, ~> 4.2
 Project Readme

Activerecord sortable

Installation

gem install activerecord_sortable

Usage

Add sortable option to relation. Table should contain column position or you can define column name.

# has many
has_many :posts, :sortable => true
has_many :user_posts, :class_name => 'Post', :sortable => true, :sortable_field => 'user_position'

# many to many
has_many :tags, :through => :post_tags, :sortable => true