Class: Hyrax::Transactions::Steps::SaveCollectionLogo
- Inherits:
-
Object
- Object
- Hyrax::Transactions::Steps::SaveCollectionLogo
- Defined in:
- lib/hyrax/transactions/steps/save_collection_logo.rb
Overview
Adds logo info via ‘ChangeSet`.
During the update collection process this step is called to update the file(s) to be used as logo(s) for the collection.
Instance Method Summary collapse
-
#call(collection_resource, update_logo_file_ids: nil, alttext_values: nil, linkurl_values: nil) ⇒ Dry::Monads::Result
‘Failure` if the work fails to save; `Success(input)`, otherwise.
Instance Method Details
#call(collection_resource, update_logo_file_ids: nil, alttext_values: nil, linkurl_values: nil) ⇒ Dry::Monads::Result
Returns ‘Failure` if the work fails to save; `Success(input)`, otherwise.
22 23 24 25 26 |
# File 'lib/hyrax/transactions/steps/save_collection_logo.rb', line 22 def call(collection_resource, update_logo_file_ids: nil, alttext_values: nil, linkurl_values: nil) collection_id = collection_resource.id.to_s process_logo_input(collection_id: collection_id, update_logo_file_ids: update_logo_file_ids, alttext_values: alttext_values, linkurl_values: linkurl_values) Success(collection_resource) end |