Sha256: 0409368b9a86029acde2275aeeb807406dc09f93dab05f2c4b194d1e239c4753

Contents?: true

Size: 326 Bytes

Versions: 11

Compression:

Stored size: 326 Bytes

Contents

module Sufia
  module DownloadsControllerBehavior
    extend ActiveSupport::Concern
    include Hydra::Controller::DownloadBehavior

    def file_name
      if !params[:file] || params[:file] == self.class.default_file_path
        params[:filename] || asset.label
      else
        params[:file]
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
sufia-6.7.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.6.1 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.6.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.5.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.4.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.3.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.2.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.1.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.0.0 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.0.0.rc4 app/controllers/concerns/sufia/downloads_controller_behavior.rb
sufia-6.0.0.rc3 app/controllers/concerns/sufia/downloads_controller_behavior.rb