rosa-build/app/controllers/downloads_controller.rb

16 lines
416 B
Ruby
Raw Normal View History

2011-10-14 07:35:25 +01:00
class DownloadsController < ApplicationController
2011-10-24 14:01:15 +01:00
before_filter :authenticate_user!
before_filter :check_global_access
2011-10-24 14:01:15 +01:00
2011-10-14 07:35:25 +01:00
def index
@downloads = Download.paginate :page => params[:page], :per_page => 30
end
def refresh
Download.rotate_nginx_log
Download.send_later :parse_and_remove_nginx_log
redirect_to downloads_path, :notice => t('flash.downloads.statistics_refreshed')
end
2011-10-14 07:35:25 +01:00
end