Skip to content
Extraits de code Groupes Projets
Valider 66f79b13 rédigé par Gonzalo Rodriguez's avatar Gonzalo Rodriguez
Parcourir les fichiers

Minor aspect_listings cleanup

parent 924e1888
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -21,7 +21,7 @@ module AspectGlobalHelper
str = "<span class='aspect_badge single'>"
link = opts.delete(:link)
if !link
str << link_to(aspect.name, "#", 'data-guid' => aspect.id, :class => 'hard_aspect_link').html_safe
str << link_to(aspect.name, "#", 'data-guid' => aspect.id).html_safe
else
str << link_for_aspect(aspect).html_safe
end
......@@ -32,7 +32,7 @@ module AspectGlobalHelper
str = ""
aspects.each do |aspect|
str << '<li>'
str << link_for_aspect(aspect, :params => opts, 'data-guid' => aspect.id, :class => 'hard_aspect_link').html_safe
str << link_for_aspect(aspect, :params => opts, 'data-guid' => aspect.id).html_safe
str << '</li>'
end
str.html_safe
......@@ -42,8 +42,6 @@ module AspectGlobalHelper
opts[:params] ||= {}
params ||= {}
opts[:params] = opts[:params].merge("a_ids[]" => aspect.id, :created_at => params[:created_at])
opts[:class] ||= ""
opts[:class] << " hard_aspect_link"
opts['data-guid'] = aspect.id
link_to aspect.name, aspects_path( opts[:params] ), opts
......
......@@ -3,7 +3,7 @@
-# the COPYRIGHT file.
%ul#aspect_nav.left_nav
%li.all_aspects{:class => ("active" if params["set"] != "all" && params["set"] != "only_sharing" && !@featured && !@finder)}
%li.all_aspects
.root_element= link_to t('aspects.index.your_aspects'), aspects_path
%ul.sub_nav
......@@ -14,8 +14,7 @@
%li{:data => {:aspect_id => aspect.id}, :class => ("active" if defined?(stream) && stream.aspect_ids.include?(aspect.id))}
.edit
= link_to image_tag("icons/pencil.svg", :height => 12, :title => t('.edit_aspect', :name => aspect.name)), edit_aspect_path(aspect), :rel => "facebox"
%a.aspect_selector{:href => aspects_path("a_ids[]" => aspect.id), :class => "aspect_selector name hard_aspect_link", 'data-guid' => aspect.id}
%a.aspect_selector{:href => aspects_path("a_ids[]" => aspect.id), :class => "name", 'data-guid' => aspect.id}
= aspect
%li
......
......@@ -5,31 +5,31 @@
%ul#aspect_nav.left_nav
%li.all_aspects{:class => ("active" if params["set"] != "all" && params["set"] != "only_sharing" && !@featured && !@finder)}
%a.home_selector{:href => contacts_path, :class => ("sub_selected" if params["a_id"])}
= t('contacts.index.my_contacts')
.contact_count
= my_contacts_count
= t('contacts.index.my_contacts')
%ul.sub_nav
- for aspect in all_aspects
%li{:data => {:aspect_id => aspect.id}, :class => ("active" if params["a_id"].to_i == aspect.id)}
%a.aspect_selector{:href => contacts_path(:a_id => aspect.id)}
= aspect
.contact_count
= aspect.contacts.size
= aspect
%li
= link_to t('aspects.aspect_listings.add_an_aspect'), new_aspect_path, :class => "new_aspect", :rel => "facebox"
%li.all_contacts{:class => ("active" if params["set"] == "all" || params["set"] == "only_sharing")}
%a.home_selector{:href => contacts_path(:set => "all"), :class => ("sub_selected" if params["set"] == "only_sharing")}
= t('contacts.index.all_contacts')
.contact_count
= all_contacts_count
= t('contacts.index.all_contacts')
%ul.sub_nav
%li{:class => ("active" if params["set"] == "only_sharing")}
%a.aspect_selector{:href => contacts_path(:set => "only_sharing")}
= t('contacts.index.only_sharing_with_me')
.contact_count
= only_sharing_count
= t('contacts.index.only_sharing_with_me')
......@@ -2928,7 +2928,7 @@ ul.left_nav
:padding 0
:margin 0
li
:width 155px
:width 162px
a.aspect_selector,
a.toggle_selector,
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter