Sha256: 722f2724da6cca6af9174a28cec0c2abe992b8421208129b4e00cb62ecd30b28

Contents?: true

Size: 512 Bytes

Versions: 9

Compression:

Stored size: 512 Bytes

Contents

module CmAdmin
  module Models
    class CmShowSection

      attr_accessor :section_name, :available_section_fields

      def initialize(section_name, &block)
        @available_section_fields = []
        @section_name = section_name
        puts "-- reached here --"
        instance_eval(&block)
      end

      def field(field_name, options={})
        puts "For printing field #{field_name}"
        @available_section_fields << CmAdmin::Models::Field.new(field_name, options)
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
cm-admin-0.5.4 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.5.3 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.5.2 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.5.0 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.4.4 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.4.3 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.4.2 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.4.1 lib/cm_admin/models/cm_show_section.rb
cm-admin-0.4.0 lib/cm_admin/models/cm_show_section.rb