Commit 08e8a955 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

Create helper for sort drowdown option names


Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 7edb030b6164
module SortingHelper
def sort_title_oldest_updated
'Oldest updated'
end
def sort_title_recently_updated
'Recently updated'
end
def sort_title_oldest_created
'Recently updated'
end
def sort_title_recently_created
'Recently updated'
end
end
......@@ -56,5 +56,5 @@
= link_to admin_projects_path(sort: nil) do
Name
= link_to admin_projects_path(sort: 'newest') do
Newest
= sort_title_recently_created
= link_to admin_projects_path(sort: 'oldest') do
......@@ -60,3 +60,3 @@
= link_to admin_projects_path(sort: 'oldest') do
Oldest
= sort_title_oldest_created
= link_to admin_projects_path(sort: 'recently_updated') do
......@@ -62,3 +62,3 @@
= link_to admin_projects_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to admin_projects_path(sort: 'last_updated') do
......@@ -64,5 +64,5 @@
= link_to admin_projects_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
= link_to admin_projects_path(sort: 'largest_repository') do
Largest repository
= link_to 'New Project', new_project_path, class: "btn btn-new"
......
......@@ -49,5 +49,5 @@
= link_to admin_users_path(sort: 'oldest_sign_in') do
Oldest sign in
= link_to admin_users_path(sort: 'recently_created') do
Recently created
= sort_title_recently_created
= link_to admin_users_path(sort: 'late_created') do
......@@ -53,5 +53,6 @@
= link_to admin_users_path(sort: 'late_created') do
Late created
= sort_title_oldest_created
= link_to 'New User', new_admin_user_path, class: "btn btn-new"
%ul.well-list
- @users.each do |user|
......
......@@ -14,5 +14,5 @@
= link_to projects_dashboard_filter_path(sort: nil) do
Name
= link_to projects_dashboard_filter_path(sort: 'newest') do
Newest
= sort_title_recently_created
= link_to projects_dashboard_filter_path(sort: 'oldest') do
......@@ -18,3 +18,3 @@
= link_to projects_dashboard_filter_path(sort: 'oldest') do
Oldest
= sort_title_oldest_created
= link_to projects_dashboard_filter_path(sort: 'recently_updated') do
......@@ -20,3 +20,3 @@
= link_to projects_dashboard_filter_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to projects_dashboard_filter_path(sort: 'last_updated') do
......@@ -22,5 +22,6 @@
= link_to projects_dashboard_filter_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
%p.light
All projects you have access to are listed here. Public projects are not included here unless you are a member
%hr
......
......@@ -20,5 +20,5 @@
= link_to explore_groups_path(sort: nil) do
Name
= link_to explore_groups_path(sort: 'newest') do
Newest
= sort_title_recently_created
= link_to explore_groups_path(sort: 'oldest') do
......@@ -24,3 +24,3 @@
= link_to explore_groups_path(sort: 'oldest') do
Oldest
= sort_title_oldest_created
= link_to explore_groups_path(sort: 'recently_updated') do
......@@ -26,3 +26,3 @@
= link_to explore_groups_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to explore_groups_path(sort: 'last_updated') do
......@@ -28,5 +28,5 @@
= link_to explore_groups_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
%hr
......
......@@ -20,5 +20,5 @@
= link_to explore_projects_path(sort: nil) do
Name
= link_to explore_projects_path(sort: 'newest') do
Newest
= sort_title_recently_created
= link_to explore_projects_path(sort: 'oldest') do
......@@ -24,3 +24,3 @@
= link_to explore_projects_path(sort: 'oldest') do
Oldest
= sort_title_oldest_created
= link_to explore_projects_path(sort: 'recently_updated') do
......@@ -26,3 +26,3 @@
= link_to explore_projects_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to explore_projects_path(sort: 'last_updated') do
......@@ -28,5 +28,5 @@
= link_to explore_projects_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
%hr
.public-projects
......
......@@ -20,5 +20,5 @@
= link_to project_branches_path(sort: nil) do
Name
= link_to project_branches_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to project_branches_path(sort: 'last_updated') do
......@@ -24,5 +24,5 @@
= link_to project_branches_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
%hr
- unless @branches.empty?
%ul.bordered-list.top-list.all-branches
......
......@@ -9,5 +9,5 @@
%ul.dropdown-menu
%li
= link_to project_filter_path(sort: 'newest') do
Newest
= sort_title_recently_created
= link_to project_filter_path(sort: 'oldest') do
......@@ -13,3 +13,3 @@
= link_to project_filter_path(sort: 'oldest') do
Oldest
= sort_title_oldest_created
= link_to project_filter_path(sort: 'recently_updated') do
......@@ -15,3 +15,3 @@
= link_to project_filter_path(sort: 'recently_updated') do
Recently updated
= sort_title_recently_updated
= link_to project_filter_path(sort: 'last_updated') do
......@@ -17,5 +17,5 @@
= link_to project_filter_path(sort: 'last_updated') do
Last updated
= sort_title_oldest_updated
= link_to project_filter_path(sort: 'milestone_due_soon') do
Milestone due soon
= link_to project_filter_path(sort: 'milestone_due_later') do
......
Supports Markdown
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