0.0
Repository is archived
No commit activity in last 3 years
No release in over 3 years
ScatterSwapper
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.10
~> 10.0

Runtime

~> 5.0
 Project Readme

ScatterSwapper

Installation

Add to your Gemfile:

gem 'scatter_swapper'

Now, everytime an URL has a parameter with a name like id or any_name_id, it will be automatically converted to the decoded id. So, no need to change your controller code when accessing resources.

Although, URL generation isn't modified... yet (still not sure if overriding to_param is the best solution), so you will need to pass the encoded id which is available through your model by the method encoded_id.

Since scatter_swap isn't maintained anymore, the code has been brought back into this gem.

This project rocks and uses MIT-LICENSE.