Migrate procedure logo to active_storage
This commit is contained in:
parent
ce97b8c359
commit
cc35a04e26
14 changed files with 85 additions and 40 deletions
|
@ -20,20 +20,6 @@ module ProcedureHelper
|
|||
t(action, scope: [:modal, :publish, key])
|
||||
end
|
||||
|
||||
def logo_img(procedure)
|
||||
logo = procedure.logo
|
||||
|
||||
if logo.blank?
|
||||
ActionController::Base.helpers.image_url("marianne.svg")
|
||||
else
|
||||
if Rails.application.secrets.fog[:enabled]
|
||||
RemoteDownloader.new(logo.filename).url
|
||||
else
|
||||
LocalDownloader.new(logo.path, 'logo').url
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def types_de_champ_data(procedure)
|
||||
{
|
||||
isAnnotation: false,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue