Module: SortingHelper

Defined in:
app/helpers/sorting_helper.rb

Instance Method Summary collapse

Instance Method Details

#projects_sort_options_hashObject


21
22
23
24
25
26
27
28
29
# File 'app/helpers/sorting_helper.rb', line 21

def projects_sort_options_hash
  {
    sort_value_name => sort_title_name,
    sort_value_recently_updated => sort_title_recently_updated,
    sort_value_oldest_updated => sort_title_oldest_updated,
    sort_value_recently_created => sort_title_recently_created,
    sort_value_oldest_created => sort_title_oldest_created,
  }
end

#sort_options_hashObject


2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'app/helpers/sorting_helper.rb', line 2

def sort_options_hash
  {
    sort_value_name => sort_title_name,
    sort_value_recently_updated => sort_title_recently_updated,
    sort_value_oldest_updated => sort_title_oldest_updated,
    sort_value_recently_created => sort_title_recently_created,
    sort_value_oldest_created => sort_title_oldest_created,
    sort_value_milestone_soon => sort_title_milestone_soon,
    sort_value_milestone_later => sort_title_milestone_later,
    sort_value_due_date_soon => sort_title_due_date_soon,
    sort_value_due_date_later => sort_title_due_date_later,
    sort_value_largest_repo => sort_title_largest_repo,
     => ,
     => ,
    sort_value_downvotes => sort_title_downvotes,
    sort_value_upvotes => sort_title_upvotes
  }
end

#sort_title_downvotesObject


79
80
81
# File 'app/helpers/sorting_helper.rb', line 79

def sort_title_downvotes
  'Least popular'
end

#sort_title_due_date_laterObject


59
60
61
# File 'app/helpers/sorting_helper.rb', line 59

def sort_title_due_date_later
  'Due later'
end

#sort_title_due_date_soonObject


55
56
57
# File 'app/helpers/sorting_helper.rb', line 55

def sort_title_due_date_soon
  'Due soon'
end

#sort_title_largest_repoObject


67
68
69
# File 'app/helpers/sorting_helper.rb', line 67

def sort_title_largest_repo
  'Largest repository'
end

#sort_title_milestone_laterObject


51
52
53
# File 'app/helpers/sorting_helper.rb', line 51

def sort_title_milestone_later
  'Milestone due later'
end

#sort_title_milestone_soonObject


47
48
49
# File 'app/helpers/sorting_helper.rb', line 47

def sort_title_milestone_soon
  'Milestone due soon'
end

#sort_title_nameObject


63
64
65
# File 'app/helpers/sorting_helper.rb', line 63

def sort_title_name
  'Name'
end

#sort_title_oldest_createdObject


39
40
41
# File 'app/helpers/sorting_helper.rb', line 39

def sort_title_oldest_created
  'Oldest created'
end

#sort_title_oldest_signinObject


75
76
77
# File 'app/helpers/sorting_helper.rb', line 75

def 
  'Oldest sign in'
end

#sort_title_oldest_updatedObject


31
32
33
# File 'app/helpers/sorting_helper.rb', line 31

def sort_title_oldest_updated
  'Oldest updated'
end

#sort_title_recently_createdObject


43
44
45
# File 'app/helpers/sorting_helper.rb', line 43

def sort_title_recently_created
  'Last created'
end

#sort_title_recently_signinObject


71
72
73
# File 'app/helpers/sorting_helper.rb', line 71

def 
  'Recent sign in'
end

#sort_title_recently_updatedObject


35
36
37
# File 'app/helpers/sorting_helper.rb', line 35

def sort_title_recently_updated
  'Last updated'
end

#sort_title_upvotesObject


83
84
85
# File 'app/helpers/sorting_helper.rb', line 83

def sort_title_upvotes
  'Most popular'
end

#sort_value_downvotesObject


135
136
137
# File 'app/helpers/sorting_helper.rb', line 135

def sort_value_downvotes
  'downvotes_desc'
end

#sort_value_due_date_laterObject


115
116
117
# File 'app/helpers/sorting_helper.rb', line 115

def sort_value_due_date_later
  'due_date_desc'
end

#sort_value_due_date_soonObject


111
112
113
# File 'app/helpers/sorting_helper.rb', line 111

def sort_value_due_date_soon
  'due_date_asc'
end

#sort_value_largest_repoObject


123
124
125
# File 'app/helpers/sorting_helper.rb', line 123

def sort_value_largest_repo
  'repository_size_desc'
end

#sort_value_milestone_laterObject


107
108
109
# File 'app/helpers/sorting_helper.rb', line 107

def sort_value_milestone_later
  'milestone_due_desc'
end

#sort_value_milestone_soonObject


103
104
105
# File 'app/helpers/sorting_helper.rb', line 103

def sort_value_milestone_soon
  'milestone_due_asc'
end

#sort_value_nameObject


119
120
121
# File 'app/helpers/sorting_helper.rb', line 119

def sort_value_name
  'name_asc'
end

#sort_value_oldest_createdObject


95
96
97
# File 'app/helpers/sorting_helper.rb', line 95

def sort_value_oldest_created
  'id_asc'
end

#sort_value_oldest_signinObject


131
132
133
# File 'app/helpers/sorting_helper.rb', line 131

def 
  'oldest_sign_in'
end

#sort_value_oldest_updatedObject


87
88
89
# File 'app/helpers/sorting_helper.rb', line 87

def sort_value_oldest_updated
  'updated_asc'
end

#sort_value_recently_createdObject


99
100
101
# File 'app/helpers/sorting_helper.rb', line 99

def sort_value_recently_created
  'id_desc'
end

#sort_value_recently_signinObject


127
128
129
# File 'app/helpers/sorting_helper.rb', line 127

def 
  'recent_sign_in'
end

#sort_value_recently_updatedObject


91
92
93
# File 'app/helpers/sorting_helper.rb', line 91

def sort_value_recently_updated
  'updated_desc'
end

#sort_value_upvotesObject


139
140
141
# File 'app/helpers/sorting_helper.rb', line 139

def sort_value_upvotes
  'upvotes_desc'
end