Sha256: cd7c42b8f519b967e5b0d1b5d3cc7a487de1c63b71b16c8c001628a16a9a3da2

Contents?: true

Size: 218 Bytes

Versions: 58

Compression:

Stored size: 218 Bytes

Contents

# If you want to move all your works to an admin set run this.
class MoveAllWorksToAdminSet
  def self.run(admin_set)
    Hyrax::WorkRelation.new.find_each do |w|
      w.update(admin_set: admin_set)
    end
  end
end

Version data entries

58 entries across 58 versions & 2 rubygems

Version Path
hyrax-2.9.6 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.5 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.4 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.3 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.2 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.9.0 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.8.0 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.7.2 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.7.1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.7.0 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.6.0 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-3.0.0.pre.rc1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-3.0.0.pre.beta3 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.5.1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.5.0 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-3.0.0.pre.beta2 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.4.1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-3.0.0.pre.beta1 lib/hyrax/move_all_works_to_admin_set.rb
hyrax-2.4.0 lib/hyrax/move_all_works_to_admin_set.rb