Sha256: b5e478d4c6983714c410a63fc077cefecf61f7fa22b6d76c6357232d89c90746

Contents?: true

Size: 435 Bytes

Versions: 23

Compression:

Stored size: 435 Bytes

Contents

module Kuhsaft
  class LinkBrick < Brick
    attr_accessible :href, :caption, :link_style, :open_in_new_window

    validates :href, :caption, :presence => true

    def self.styles
      %w(pdf word excel button external)
    end

    def to_style_class
      [super, link_style.presence].join(' ')
    end

    def collect_fulltext
      [super, caption].join(' ')
    end

    def user_can_add_childs?
      false
    end
  end
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
kuhsaft-1.8.6 app/models/kuhsaft/link_brick.rb
kuhsaft-1.8.5 app/models/kuhsaft/link_brick.rb
kuhsaft-2.0.2 app/models/kuhsaft/link_brick.rb
kuhsaft-1.8.4 app/models/kuhsaft/link_brick.rb
kuhsaft-1.8.1 app/models/kuhsaft/link_brick.rb
kuhsaft-2.0.1 app/models/kuhsaft/link_brick.rb
kuhsaft-2.0.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.8.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.7.1 app/models/kuhsaft/link_brick.rb
kuhsaft-1.7.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.6.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.5.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.4.3 app/models/kuhsaft/link_brick.rb
kuhsaft-1.4.2 app/models/kuhsaft/link_brick.rb
kuhsaft-1.4.1 app/models/kuhsaft/link_brick.rb
kuhsaft-1.4.0 app/models/kuhsaft/link_brick.rb
kuhsaft-1.3.1 app/models/kuhsaft/link_brick.rb
kuhsaft-1.2.15 app/models/kuhsaft/link_brick.rb
kuhsaft-1.2.14 app/models/kuhsaft/link_brick.rb
kuhsaft-1.2.13 app/models/kuhsaft/link_brick.rb