Commit f78c0086e0a43b2fcb131c9ff0e0294bd2cdb51c
1 parent
6b82fa47
Exists in
staging
and in
42 other branches
ActionItem93: removing unused code
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@997 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
1 changed file
with
1 additions
and
21 deletions
Show diff stats
app/helpers/application_helper.rb
| @@ -127,7 +127,7 @@ module ApplicationHelper | @@ -127,7 +127,7 @@ module ApplicationHelper | ||
| 127 | # MUDAR, O ID acima deve ser no Link <a id=... | 127 | # MUDAR, O ID acima deve ser no Link <a id=... |
| 128 | # O ID icon_accessibility tambem tem que aparcer e testei o link nao ta funcionado. | 128 | # O ID icon_accessibility tambem tem que aparcer e testei o link nao ta funcionado. |
| 129 | ( link_to content_tag('span', _('Admin')), { :controller => 'admin_panel' }, :id => 'icon_admin' if current_user.person.is_admin?), | 129 | ( link_to content_tag('span', _('Admin')), { :controller => 'admin_panel' }, :id => 'icon_admin' if current_user.person.is_admin?), |
| 130 | - ( link_to content_tag('span', _('Logout')), { :controller => 'account', :action => 'logout', :method => 'post'}, :id => 'icon_logout'), | 130 | + ( link_to content_tag('span', _('Logout')), { :controller => 'account', :action => 'logout'}, :id => 'icon_logout', :method => 'post'), |
| 131 | ] | 131 | ] |
| 132 | else | 132 | else |
| 133 | [ | 133 | [ |
| @@ -136,26 +136,6 @@ module ApplicationHelper | @@ -136,26 +136,6 @@ module ApplicationHelper | ||
| 136 | end.join(" ") | 136 | end.join(" ") |
| 137 | end | 137 | end |
| 138 | 138 | ||
| 139 | - def login_or_register_or_logout | ||
| 140 | - if logged_in? | ||
| 141 | - user_links + " " + logout_box | ||
| 142 | - else | ||
| 143 | - login_box + " " + register_box | ||
| 144 | - end | ||
| 145 | - end | ||
| 146 | - | ||
| 147 | - def login_box | ||
| 148 | - content_tag('span', (link_to _('Login'), :controller => 'account', :action => 'login'), :id => 'login_box') | ||
| 149 | - end | ||
| 150 | - | ||
| 151 | - def register_box | ||
| 152 | - content_tag('span', (link_to _('Not a user yet? Register now!'), :controller => 'account', :action => 'signup'), :id => 'register_box') | ||
| 153 | - end | ||
| 154 | - | ||
| 155 | - def logout_box | ||
| 156 | - content_tag('span', (link_to _('Logout'), { :controller => 'account', :action => 'logout'}, :method => 'post'), :id => 'logout_box') | ||
| 157 | - end | ||
| 158 | - | ||
| 159 | def link_if_permitted(link, permission = nil, target = nil) | 139 | def link_if_permitted(link, permission = nil, target = nil) |
| 160 | if permission.nil? || current_user.person.has_permission?(permission, target) | 140 | if permission.nil? || current_user.person.has_permission?(permission, target) |
| 161 | link | 141 | link |