huacnlee / rails-settings-cached

Global settings for your Rails application.
Other
1.06k stars 202 forks source link

404 on key with dots #106

Closed romaslmd closed 8 years ago

romaslmd commented 8 years ago
# config/routes.rb
resources :settings
# views/settings/index.html.slim
= link_to 'Edit', edit_setting_path(id: 'site_name.en'), remote: true

After click:

No route matches [GET] "/settings/site_name.en/edit"`

is there any workaround? is it possible to add kind of slug to settings to use it in #to_param method?

huacnlee commented 8 years ago

You need change Rails routes.rb to :id contains .