Skip to content

Commit

Permalink
Add support for namespaces like Refinery::Image and Refinery::Blog::P…
Browse files Browse the repository at this point in the history
…ost. Prefix url helpers with refinery and change routes like refinery_admin_images_path to refinery.admin_images_path.
  • Loading branch information
ugisozols committed Jan 27, 2012
1 parent fbe48a6 commit 0c8b912
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 9 deletions.
5 changes: 0 additions & 5 deletions core/lib/refinery/activity.rb
Expand Up @@ -96,12 +96,7 @@ def url_prefix
attr_writer :url

def url
<<<<<<< HEAD
@url ||= "refinery.#{url_prefix}#{Refinery.namespace(klass)}"
=======
"#{self.url_prefix}#{@url ||= [ class_name.underscore.gsub(%r{/?#{klass.model_name.param_key}($|/)}, '').gsub('/', '_'),
'admin', klass.model_name.param_key, 'path' ].join('_')}"
>>>>>>> Restructured engine generator according to namespacing conventions. Made form_actions, activity and crud forward and backward compatible in this regard
end
end
end
4 changes: 0 additions & 4 deletions core/lib/refinery/crud.rb
Expand Up @@ -30,11 +30,7 @@ def self.default_options(model_name)
:order => ('position ASC' if this_class.table_exists? && this_class.column_names.include?('position')),
:paging => true,
:per_page => false,
<<<<<<< HEAD
:redirect_to_url => "refinery.#{Refinery.namespace(class_name.constantize, true)}",
=======
:redirect_to_url => "main_app.#{namespacing}_admin_#{plural_name}_path",
>>>>>>> Restructured engine generator according to namespacing conventions. Made form_actions, activity and crud forward and backward compatible in this regard
:searchable => true,
:search_conditions => '',
:sortable => true,
Expand Down

0 comments on commit 0c8b912

Please sign in to comment.