Commit c91554de authored by Rubén Dávila's avatar Rubén Dávila

Add link with filter by milestone for labels and avatar.

Closes #13628
parent baa782ac
-# @project is present when viewing Project's milestone -# @project is present when viewing Project's milestone
- project = @project || record.project - project = @project || record.project
- record_type = record.class.table_name
- base_url_args = [project.namespace.becomes(Namespace), project, record_type]
%li{ id: dom_id(record, 'sortable'), class: "#{dom_class(record)}-row", 'data-iid' => record.iid, 'data-url' => polymorphic_path(record) } %li{ id: dom_id(record, 'sortable'), class: "#{dom_class(record)}-row", 'data-iid' => record.iid, 'data-url' => polymorphic_path(record) }
%span %span
...@@ -11,7 +13,11 @@ ...@@ -11,7 +13,11 @@
%div{class: "#{dom_class(record)}-detail"} %div{class: "#{dom_class(record)}-detail"}
= link_to [project.namespace.becomes(Namespace), project, record] do = link_to [project.namespace.becomes(Namespace), project, record] do
%span{ class: "#{dom_class(record)}-number" } ##{record.iid} %span{ class: "#{dom_class(record)}-number" } ##{record.iid}
- record.labels.each do |label| - record.labels.each do |label|
= render_colored_label(label) %a{ href: polymorphic_path(base_url_args, { milestone_title: @milestone.title, label_name: label.title, state: 'all' }) }<
= render_colored_label(label)
- if record.assignee - if record.assignee
= image_tag avatar_icon(record.assignee, 16), class: "avatar s16", alt: '' %a{ href: polymorphic_path(base_url_args, { milestone_title: @milestone.title, assignee_id: record.assignee_id, state: 'all' }) }
= image_tag(avatar_icon(record.assignee, 16), class: "avatar s16", alt: '')
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment