Sha256: 50eeaf99c18ee17065a1e6c25a503d1612067f3fc6f056c722fa45654f36a737

Contents?: true

Size: 387 Bytes

Versions: 234

Compression:

Stored size: 387 Bytes

Contents

module Avo
  module Fields
    class IdField < BaseField
      attr_reader :link_to_resource

      def initialize(id, **args, &block)
        args[:readonly] = true
        args[:sortable] = true

        hide_on [:edit, :new]

        super(id, **args, &block)

        @link_to_resource = args[:link_to_resource].present? ? args[:link_to_resource] : false
      end
    end
  end
end

Version data entries

234 entries across 234 versions & 1 rubygems

Version Path
avo-2.30.0 lib/avo/fields/id_field.rb
avo-2.29.1 lib/avo/fields/id_field.rb
avo-2.29.1.pre.pr1652 lib/avo/fields/id_field.rb
avo-2.29.0 lib/avo/fields/id_field.rb
avo-2.28.3.pre.pr1646 lib/avo/fields/id_field.rb
avo-2.28.2.pre.pr1642 lib/avo/fields/id_field.rb
avo-2.28.1.pre.pr1642 lib/avo/fields/id_field.rb
avo-2.28.0 lib/avo/fields/id_field.rb
avo-2.27.2.pre.pr1606 lib/avo/fields/id_field.rb
avo-2.27.1 lib/avo/fields/id_field.rb
avo-2.27.0 lib/avo/fields/id_field.rb
avo-2.26.3.pre.pr1601 lib/avo/fields/id_field.rb
avo-2.26.2.pre.pr1579 lib/avo/fields/id_field.rb
avo-2.26.1.pr1584.pre.1 lib/avo/fields/id_field.rb
avo-2.25.1.pre.1.pr1579 lib/avo/fields/id_field.rb
avo-2.26.0 lib/avo/fields/id_field.rb
avo-2.25.0 lib/avo/fields/id_field.rb
avo-2.24.1 lib/avo/fields/id_field.rb
avo-2.24.0 lib/avo/fields/id_field.rb
avo-2.23.3.pre.1.pr1529 lib/avo/fields/id_field.rb