Sha256: 394e5062380eceb28a1d3ede14195721ae465048999ebdc08c691ecaa873815f

Contents?: true

Size: 327 Bytes

Versions: 2

Compression:

Stored size: 327 Bytes

Contents

# frozen_string_literal: true
module Hyrax
  module Test
    class FormWithValidations < Hyrax::Forms::ResourceForm
      property :title

      validates :title, presence: true

      # Added to comply with Hyrax::Forms::FailedSubmissionFormWrapper
      def permitted_params
        { title: [] }
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
hyrax-5.0.0 spec/support/form_with_validations.rb
hyrax-5.0.0.rc3 spec/support/form_with_validations.rb