tap/app/controllers/admins_controller.rb
2014-12-15 19:43:02 +01:00

14 lines
337 B
Ruby

require 'csv'
class AdminsController < ApplicationController
def schulden
authorize! :schulden, :admins
@users = User.all
respond_to do |format|
format.csv do
headers['Content-Disposition'] = "attachment; filename=\"zeus-schulden\""
headers['Content-Type'] ||= 'text/csv'
end
end
end
end