45 lines
1.8 KiB
Plaintext
45 lines
1.8 KiB
Plaintext
.side-filters.hidden-xs.hidden-sm
|
|
= form_tag filter_path(entity), method: 'get' do
|
|
- if current_user
|
|
%fieldset.scope-filter
|
|
%ul.nav.nav-pills.nav-stacked
|
|
%li{class: ("active" if params[:scope] == 'assigned-to-me')}
|
|
= link_to filter_path(entity, scope: 'assigned-to-me') do
|
|
Assigned to me
|
|
%li{class: ("active" if params[:scope] == 'authored')}
|
|
= link_to filter_path(entity, scope: 'authored') do
|
|
Created by me
|
|
%li{class: ("active" if params[:scope] == 'all')}
|
|
= link_to filter_path(entity, scope: 'all') do
|
|
Everyone's
|
|
|
|
%fieldset.status-filter
|
|
%legend State
|
|
%ul.nav.nav-pills
|
|
%li{class: ("active" if params[:state] == 'opened')}
|
|
= link_to filter_path(entity, state: 'opened') do
|
|
Open
|
|
%li{class: ("active" if params[:state] == 'closed')}
|
|
= link_to filter_path(entity, state: 'closed') do
|
|
Closed
|
|
%li{class: ("active" if params[:state] == 'all')}
|
|
= link_to filter_path(entity, state: 'all') do
|
|
All
|
|
|
|
%fieldset
|
|
%legend Projects
|
|
%ul.nav.nav-pills.nav-stacked.nav-small
|
|
- @projects.each do |project|
|
|
- unless entities_per_project(project, entity).zero?
|
|
%li{class: ("active" if params[:project_id] == project.id.to_s)}
|
|
= link_to filter_path(entity, project_id: project.id) do
|
|
= project.name_with_namespace
|
|
%small.pull-right= entities_per_project(project, entity)
|
|
|
|
%fieldset
|
|
- if params[:state].present? || params[:project_id].present?
|
|
= link_to filter_path(entity, state: nil, project_id: nil), class: 'pull-right cgray' do
|
|
%i.icon-remove
|
|
%strong Clear filter
|
|
|