diff options
Diffstat (limited to 'app/helpers/todos_helper.rb')
-rw-r--r-- | app/helpers/todos_helper.rb | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/app/helpers/todos_helper.rb b/app/helpers/todos_helper.rb index ecf29c41100..520cde9ecee 100644 --- a/app/helpers/todos_helper.rb +++ b/app/helpers/todos_helper.rb @@ -130,12 +130,12 @@ module TodosHelper def todos_filter_params { - state: params[:state], + state: params[:state].presence, project_id: params[:project_id], author_id: params[:author_id], type: params[:type], action_id: params[:action_id] - } + }.compact end def todos_filter_empty? @@ -168,22 +168,22 @@ module TodosHelper def todo_actions_options [ - { id: '', text: 'Any Action' }, - { id: Todo::ASSIGNED, text: 'Assigned' }, - { id: Todo::REVIEW_REQUESTED, text: 'Review requested' }, - { id: Todo::MENTIONED, text: 'Mentioned' }, - { id: Todo::MARKED, text: 'Added' }, - { id: Todo::BUILD_FAILED, text: 'Pipelines' } + { id: '', text: s_('Todos|Any Action') }, + { id: Todo::ASSIGNED, text: s_('Todos|Assigned') }, + { id: Todo::REVIEW_REQUESTED, text: s_('Todos|Review requested') }, + { id: Todo::MENTIONED, text: s_('Todos|Mentioned') }, + { id: Todo::MARKED, text: s_('Todos|Added') }, + { id: Todo::BUILD_FAILED, text: s_('Todos|Pipelines') } ] end def todo_types_options [ - { id: '', text: 'Any Type' }, - { id: 'Issue', text: 'Issue' }, - { id: 'MergeRequest', text: 'Merge request' }, - { id: 'DesignManagement::Design', text: 'Design' }, - { id: 'AlertManagement::Alert', text: 'Alert' } + { id: '', text: s_('Todos|Any Type') }, + { id: 'Issue', text: s_('Todos|Issue') }, + { id: 'MergeRequest', text: s_('Todos|Merge request') }, + { id: 'DesignManagement::Design', text: s_('Todos|Design') }, + { id: 'AlertManagement::Alert', text: s_('Todos|Alert') } ] end |