Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' into some-tidyup

  • Loading branch information...
commit 5bb6c920f5bca666304beac7dcc58c25d2a075fc 2 parents 5d450c4 + 3c694d1
@gunn authored
View
1  README.md
@@ -85,7 +85,6 @@ mount RailsAdmin::Engine => '/admin', :as => 'rails_admin' # Feel free to change
```
Note: The `devise_for` route must be placed before the mounted engine. The following will generate infinite redirects.
-The following will generate infinite redirects.
```ruby
mount RailsAdmin::Engine => '/admin', :as => 'rails_admin'
View
2  app/views/rails_admin/main/_form_filtering_multiselect.html.haml
@@ -43,5 +43,5 @@
= form.select field.method_name, collection, { :selected => selected_ids, :object => form.object }, field.html_attributes.reverse_merge({:data => { :filteringmultiselect => true, :options => js_data.to_json }, :multiple => true})
- if authorized? :new, config.abstract_model
- path_hash = { :model_name => config.abstract_model.to_param, :modal => true }
- - path_hash.merge!({ :associations => { field.inverse_of => (form.object.id || 'new') } }) if field.inverse_of
+ - path_hash.merge!({ :associations => { field.inverse_of => (form.object.persisted? ? form.object.id : 'new') } }) if field.inverse_of
= link_to "<i class=\"icon-plus icon-white\"></i> ".html_safe + wording_for(:link, :new, config.abstract_model), '#', :data => { :link => new_path(path_hash) }, :class => "create btn btn-info", :style => 'margin-left:10px'
View
2  app/views/rails_admin/main/_form_filtering_select.html.haml
@@ -30,7 +30,7 @@
- if authorized? :new, config.abstract_model
- path_hash = { :model_name => config.abstract_model.to_param, :modal => true }
- - path_hash.merge!({ :associations => { field.inverse_of => (form.object.id || 'new') } }) if field.inverse_of
+ - path_hash.merge!({ :associations => { field.inverse_of => (form.object.persisted? ? form.object.id : 'new') } }) if field.inverse_of
= link_to "<i class=\"icon-plus icon-white\"></i> ".html_safe + wording_for(:link, :new, config.abstract_model), '#', :data => { :link => new_path(path_hash) }, :class => "btn btn-info create", :style => 'float:left; margin-left:10px'
- if edit_url.present?
Please sign in to comment.
Something went wrong with that request. Please try again.