Sha256: 4492c86b7e766c236d7ec126a4379998c11f1182c96acc5b4c3817449f8b9cff
Contents?: true
Size: 1021 Bytes
Versions: 25
Compression:
Stored size: 1021 Bytes
Contents
# frozen_string_literal: true module Hyrax module Forms module Admin class CollectionTypeForm include ActiveModel::Model attr_accessor :collection_type validates :title, presence: true delegate :title, :description, :brandable, :discoverable, :nestable, :sharable, :share_applies_to_new_works, :require_membership, :allow_multiple_membership, :assigns_workflow, :assigns_visibility, :id, :collection_type_participants, :persisted?, :admin_set?, :user_collection?, :badge_color, to: :collection_type ## # @return [Boolean] def all_settings_disabled? collections? || admin_set? || user_collection? end ## # @return [Boolean] def share_options_disabled? all_settings_disabled? || !sharable end ## # @return [Boolean] def collections? collection_type.collections.any? end end end end end
Version data entries
25 entries across 25 versions & 1 rubygems