Commit b4f794e865e631e9ac6058b3365dcba713c2d0c2
1 parent
30d9d3f5
Exists in
master
and in
22 other branches
ActionItem93: fixing routing bug on blocks
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@976 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
4 changed files
with
9 additions
and
4 deletions
Show diff stats
app/design_blocks/favorite_links_profile/controllers/favorite_links_profile_controller.rb
app/views/layouts/application.rhtml
| ... | ... | @@ -30,8 +30,7 @@ |
| 30 | 30 | <%= javascript_tag(visual_effect(:fade, "notice", :duration => 2.0)) %> |
| 31 | 31 | </div> |
| 32 | 32 | <% end %> |
| 33 | - | |
| 34 | - <%= image_tag 'loading.gif', :id => 'spinner', :style => "display:none; float:right;", :alt => _('Image for Loading...') %> | |
| 33 | + <%= image_tag 'comatose/spinner.gif', :id=>'spinner', :align=>'absmiddle', :style=>'display:none;' %> | |
| 35 | 34 | |
| 36 | 35 | <div id="wrap" class='category<%= category_color %>'> |
| 37 | 36 | ... | ... |
config/routes.rb
| ... | ... | @@ -37,7 +37,7 @@ ActionController::Routing::Routes.draw do |map| |
| 37 | 37 | map.category 'cat/*path', :controller => 'category', :action => 'view' |
| 38 | 38 | |
| 39 | 39 | # controllers for blocks |
| 40 | - map.controllers 'block/:controller/:action/:id', :controller => Noosfero.pattern_for_controllers_from_design_blocks | |
| 40 | + map.controllers 'block/:profile/:controller/:action/:id', :controller => Noosfero.pattern_for_controllers_from_design_blocks | |
| 41 | 41 | |
| 42 | 42 | ###################################################### |
| 43 | 43 | ## Controllers that are profile-specific (for profile admins ) | ... | ... |
test/integration/routing_test.rb
| ... | ... | @@ -85,7 +85,8 @@ class RoutingTest < ActionController::IntegrationTest |
| 85 | 85 | end |
| 86 | 86 | |
| 87 | 87 | def test_routing_to_controllers_inside_design_blocks_directory |
| 88 | - assert_routing('/block/favorite_links/show/1', :controller => 'favorite_links', :action => 'show', :id => '1') | |
| 88 | + assert_routing('/block/cojones/favorite_links_profile/show/1', :profile => 'cojones', :controller => 'favorite_links_profile', :action => 'show', :id => '1') | |
| 89 | + assert_routing('/block/cojones/favorite_links_profile/save', :profile => 'cojones', :controller => 'favorite_links_profile', :action => 'save') | |
| 89 | 90 | end |
| 90 | 91 | |
| 91 | 92 | end | ... | ... |