mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 17:59:47 +02:00
9 lines
258 B
Ruby
9 lines
258 B
Ruby
class Admin::LegalDocumentsController < AdminController
|
|
load_and_authorize_resource
|
|
|
|
def show
|
|
@ld = LegalDocument.find(params[:id])
|
|
file = Base64.decode64(@ld.body)
|
|
send_data file, filename: "#{@ld.created_at}.#{@ld.document_type}"
|
|
end
|
|
end
|