Sha256: cebeb7cdc7e749efadf59bc01b4c8f4439c107a482d1cc9f7867a8582d4f9fd4

Contents?: true

Size: 511 Bytes

Versions: 1

Compression:

Stored size: 511 Bytes

Contents

# frozen_string_literal: true

class Admin::Tramway::User::UserForm < ::Tramway::Core::ApplicationForm
  self.model_class = Tramway::User::User

  properties :email, :password, :first_name, :last_name, :role

  validates :email, email: true

  def initialize(object)
    super(object).tap do
      form_properties email: :string,
                      password: :string,
                      first_name: :string,
                      last_name: :string,
                      role: :default
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
tramway-user-2.1.1.1 app/forms/admin/tramway/user/user_form.rb