Sha256: 64909503eb603dcad8b5ab015557d5289b0655adac2c5955ea639b1f41ba8268

Contents?: true

Size: 516 Bytes

Versions: 126

Compression:

Stored size: 516 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Admin
    # A form object to create or update scopes.
    class ScopeTypeForm < Form
      include TranslatableAttributes

      translatable_attribute :name, String
      translatable_attribute :plural, String
      attribute :organization, Decidim::Organization

      mimic :scope_type

      validates :name, :plural, translatable_presence: true
      validates :organization, presence: true

      alias organization current_organization
    end
  end
end

Version data entries

126 entries across 126 versions & 2 rubygems

Version Path
decidim-admin-0.7.3 app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.7.2 app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.7.1 app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.7.0 app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.8 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.8 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.7 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.7 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.6 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.6 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.5 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.5 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.4 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.4 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.3 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.3 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.2 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.2 decidim-admin/app/forms/decidim/admin/scope_type_form.rb
decidim-admin-0.6.1 app/forms/decidim/admin/scope_type_form.rb
decidim-0.6.1 decidim-admin/app/forms/decidim/admin/scope_type_form.rb