Skip to content

Instantly share code, notes, and snippets.

@ehoch
Created January 25, 2013 19:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ehoch/4637341 to your computer and use it in GitHub Desktop.
Save ehoch/4637341 to your computer and use it in GitHub Desktop.
How Alarm Grid (https://www.alarmgrid.com) created a flat taxon structure.
module Spree
Taxon.class_eval do
def set_permalink # No longer add in parent
self.permalink = name.to_url if permalink.blank?
end
end
end
@ehoch
Copy link
Author

ehoch commented Jan 25, 2013

This plus a new route let's us have urls such as

https://www.alarmgrid.com/browse/wireless-security-systems

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment