From f2686288b7a85b2ad126d4db886d784c5fed2e0f Mon Sep 17 00:00:00 2001 From: Pfingstfrosch Date: Sat, 16 May 2020 14:09:11 +0200 Subject: [PATCH] moved into proper folder location --- app/helpers/{ => crawlers}/courses_crawler_helper.rb | 0 app/helpers/{ => crawlers}/people_crawler_helper.rb | 0 app/helpers/{ => crawlers}/projects_crawler_helper.rb | 0 app/helpers/{ => crawlers}/theses_crawler_helper.rb | 0 app/helpers/{ => crawlers}/tiss_crawler_helper.rb | 0 app/helpers/favorites_helper.rb | 6 ++++++ 6 files changed, 6 insertions(+) rename app/helpers/{ => crawlers}/courses_crawler_helper.rb (100%) rename app/helpers/{ => crawlers}/people_crawler_helper.rb (100%) rename app/helpers/{ => crawlers}/projects_crawler_helper.rb (100%) rename app/helpers/{ => crawlers}/theses_crawler_helper.rb (100%) rename app/helpers/{ => crawlers}/tiss_crawler_helper.rb (100%) diff --git a/app/helpers/courses_crawler_helper.rb b/app/helpers/crawlers/courses_crawler_helper.rb similarity index 100% rename from app/helpers/courses_crawler_helper.rb rename to app/helpers/crawlers/courses_crawler_helper.rb diff --git a/app/helpers/people_crawler_helper.rb b/app/helpers/crawlers/people_crawler_helper.rb similarity index 100% rename from app/helpers/people_crawler_helper.rb rename to app/helpers/crawlers/people_crawler_helper.rb diff --git a/app/helpers/projects_crawler_helper.rb b/app/helpers/crawlers/projects_crawler_helper.rb similarity index 100% rename from app/helpers/projects_crawler_helper.rb rename to app/helpers/crawlers/projects_crawler_helper.rb diff --git a/app/helpers/theses_crawler_helper.rb b/app/helpers/crawlers/theses_crawler_helper.rb similarity index 100% rename from app/helpers/theses_crawler_helper.rb rename to app/helpers/crawlers/theses_crawler_helper.rb diff --git a/app/helpers/tiss_crawler_helper.rb b/app/helpers/crawlers/tiss_crawler_helper.rb similarity index 100% rename from app/helpers/tiss_crawler_helper.rb rename to app/helpers/crawlers/tiss_crawler_helper.rb diff --git a/app/helpers/favorites_helper.rb b/app/helpers/favorites_helper.rb index 4e9a950..fae53e7 100644 --- a/app/helpers/favorites_helper.rb +++ b/app/helpers/favorites_helper.rb @@ -1,2 +1,8 @@ module FavoritesHelper + def sortable(title, column) + title ||= column.titelize + puts title + direction = column == sort_column && sort_direction == 'asc' ? 'desc' : 'asc' + link_to title, :sort => column, :direction => direction + end end