Commit e208d179bb4dd2cbf5f62d6adefe0ed589cdfad8

Authored by AntonioTerceiro
1 parent 2aeda104

ActionItem93: removing extra space



git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@1070 3f533792-8f58-4932-b0fe-aaf55b0a4547
app/helpers/application_helper.rb
... ... @@ -265,7 +265,7 @@ module ApplicationHelper
265 265  
266 266 def link_to_category(category)
267 267 return _('Uncategorized product') unless category
268   - link_to category.name, :controller => 'category', :action => 'view', :path => category.path.split('/')
  268 + link_to category.full_name, :controller => 'category', :action => 'view', :path => category.path.split('/')
269 269 end
270 270  
271 271 def link_to_product(product)
... ...
app/views/catalog/show.rhtml
... ... @@ -3,4 +3,6 @@
3 3 <%= image_tag @product.image.public_filename if @product.image %> <br/>
4 4 <%= @product.price %> <br/>
5 5 <%= @product.description %> <br/>
6   -<%= link_to_category(@product.product_category) %> <br/>
  6 +
  7 +
  8 +<%= _('Category: %s ') % link_to_category(@product.product_category) %> <br/>
... ...
app/views/category/_product_category.rhtml
1 1 <ul>
2   - <li><%= _("%d products in this category") % @products.size.to_s %></li>
3   - <li><%= _("%d enterprises sells products in this category") % @enterprises.size.to_s %></li>
  2 + <li><%= n_("One product in this category.", "%{num} products in this category.", @products.size) % { :num => @products.size } %></li>
  3 + <li><%= n_("One enterprise sells products in this category.", "%{num} enterprises sells products in this category.", @enterprises.size) % { :num => @enterprises.size} %></li>
4 4 </ul>
5 5  
6 6 <ul>
... ...
app/views/category/view.rhtml
... ... @@ -4,8 +4,10 @@
4 4  
5 5 <%= render :partial => @category.class.name.underscore %>
6 6  
7   -<h4> <%= _('Children categories: ') %> </h4>
8   -<% unless @category.children.empty? %>
  7 +<% if @category.children.empty? %>
  8 + <strong><%= _('No children categories') %></strong>
  9 +<% else %>
  10 +<h4> <%= _('Children categories:') %> </h4>
9 11 <ul>
10 12 <% @category.children.each do |c| %>
11 13 <li> <%= link_to_category(c) %> </li>
... ...
app/views/consumed_products/new.rhtml
... ... @@ -3,8 +3,8 @@
3 3 <%= error_messages_for :consumption %>
4 4  
5 5 <% form_for :consumption, @consumption do |f| %>
6   - <p> <%= _('Product: ') %> <%= f.select "product_category_id", ProductCategory.find(:all).map{|pc| [pc.name, pc.id]} %></p>
7   - <p> <%= _('Aditional specifications: ') %><br> <%= f.text_area "aditional_specifications" %> </p>
  6 + <p> <%= _('Product:') %> <%= f.select "product_category_id", ProductCategory.find(:all).map{|pc| [pc.name, pc.id]} %></p>
  7 + <p> <%= _('Aditional specifications:') %><br> <%= f.text_area "aditional_specifications" %> </p>
8 8 <%= submit_tag _('Add product') %>
9 9 <%= link_to _('Cancel'), :action => 'index' %>
10 10 <% end %>
... ...
app/views/enterprise_editor/index.rhtml
... ... @@ -2,15 +2,15 @@
2 2  
3 3 <%= error_messages_for 'profile' %>
4 4  
5   -<p> <%= _('Identifier: ') %> <%= @enterprise.identifier %> </p>
6   -<p> <%= _('Address: ') %> <%= @enterprise.address %> </p>
7   -<p> <%= _('Contact phone: ') %> <%= @enterprise.contact_phone %> </p>
8   -<p> <%= _('Contact person: ') %> <%= @enterprise.organization_info.contact_person %> </p>
9   -<p> <%= _('Acronym: ') %> <%= @enterprise.organization_info.acronym %> </p>
10   -<p> <%= _('Foundation year: ') %> <%= @enterprise.organization_info.foundation_year %> </p>
11   -<p> <%= _('Legal Form: ') %> <%= @enterprise.organization_info.legal_form %> </p>
12   -<p> <%= _('Economic activity: ') %> <%= @enterprise.organization_info.economic_activity %> </p>
13   -<p> <%= _('Management infomation: ') %> <%= @enterprise.organization_info.management_information %> </p>
  5 +<p> <%= _('Identifier:') %> <%= @enterprise.identifier %> </p>
  6 +<p> <%= _('Address:') %> <%= @enterprise.address %> </p>
  7 +<p> <%= _('Contact phone:') %> <%= @enterprise.contact_phone %> </p>
  8 +<p> <%= _('Contact person:') %> <%= @enterprise.organization_info.contact_person %> </p>
  9 +<p> <%= _('Acronym:') %> <%= @enterprise.organization_info.acronym %> </p>
  10 +<p> <%= _('Foundation year:') %> <%= @enterprise.organization_info.foundation_year %> </p>
  11 +<p> <%= _('Legal Form:') %> <%= @enterprise.organization_info.legal_form %> </p>
  12 +<p> <%= _('Economic activity:') %> <%= @enterprise.organization_info.economic_activity %> </p>
  13 +<p> <%= _('Management infomation:') %> <%= @enterprise.organization_info.management_information %> </p>
14 14  
15 15 <%= link_to _('Edit enterprise'), :action => 'edit', :id => @enterprise %>
16 16 <%= help _('Change the information about the enterprise') %>
... ...
app/views/environment_role_manager/change_role.rhtml
... ... @@ -2,7 +2,7 @@
2 2  
3 3 <% labelled_form_for :member, @admin, :url => {:action => 'update_roles'} do |f| %>
4 4  
5   - <%= _('Roles: ') %> <br>
  5 + <%= _('Roles:') %> <br>
6 6 <% @roles.each do |r| %>
7 7 <%= labelled_form_field(r.name, (check_box_tag "roles[]", r.id, @admin.role_assignments.map{|ra|ra.role}.include?(r))) %>
8 8 <% end %>
... ...
app/views/environment_role_manager/make_admin.rhtml
... ... @@ -5,7 +5,7 @@
5 5 <% @people.each do |p| %>
6 6 <%= labelled_form_field(p.name, (radio_button_tag "person", p.id)) %>
7 7 <% end %>
8   - <%= _('Roles: ') %> <br>
  8 + <%= _('Roles:') %> <br>
9 9 <% @roles.each do |r| %>
10 10 <%= labelled_form_field(r.name, (check_box_tag "roles[]", r.id)) %>
11 11 <% end %>
... ...
app/views/manage_products/index.rhtml
... ... @@ -4,7 +4,7 @@
4 4  
5 5 <% @products.each do |product| %>
6 6 <p> <b> <%= link_to product.name, :action => 'show', :id => product %> </b>
7   - <%= _('Price: ') %> <%= product.price %>
  7 + <%= _('Price:') %> <%= product.price %>
8 8 <%= link_to _('edit'), :action => 'edit', :id => product %>
9 9 <%= link_to _('destroy'), :action => 'destroy', :id => product %> </p>
10 10 <% end %>
... ...
app/views/manage_products/show.rhtml
1 1 <h3> <%= @product.name %> </h3>
2 2  
3 3 <p> <%= image_tag @product.image.public_filename if @product.image %> </p>
4   -<p> <%= _('Price: ') %> <%= @product.price %> </p>
5   -<p> <%= _('Description: ') %> <%= @product.description %> </p>
6   -<p> <%= _('Category: ') %> <%= link_to_category(@product.product_category) %> </p>
  4 +<p> <%= _('Price:') %> <%= @product.price %> </p>
  5 +<p> <%= _('Description:') %> <%= @product.description %> </p>
  6 +<p> <%= _('Category:') %> <%= link_to_category(@product.product_category) %> </p>
7 7  
8 8 <%= link_to _('edit'), :action => 'edit', :id => @product %>
9 9 <%= link_to _('destroy'), :action => 'destroy', :id => @product %>
... ...
app/views/profile_members/change_role.rhtml
... ... @@ -2,7 +2,7 @@
2 2  
3 3 <% labelled_form_for :member, @member, :url => {:action => 'update_roles'} do |f| %>
4 4  
5   - <%= _('Roles: ') %> <br>
  5 + <%= _('Roles:') %> <br>
6 6 <% @roles.each do |r| %>
7 7 <%= check_box_tag "roles[]", r.id, @associations.map(&:role).include?(r) %>
8 8 <%= r.name.capitalize %><br/>
... ...
app/views/role/_form.rhtml
... ... @@ -4,7 +4,7 @@
4 4  
5 5 <%= f.text_field :name %>
6 6  
7   - <%= _('Permissions: ') %> <br>
  7 + <%= _('Permissions:') %> <br>
8 8 <% permissions.keys.each do |p| %>
9 9 <%= labelled_form_field(permission_name(p), (check_box_tag "role[permissions][]", p, @role.has_permission?(p))) %>
10 10 <% end %>
... ...