Class: Refinery::Pages::Tab
- Inherits:
-
Object
- Object
- Refinery::Pages::Tab
- Defined in:
- pages/lib/refinery/pages/tab.rb
Instance Attribute Summary (collapse)
-
- (Object) name
Returns the value of attribute name.
-
- (Object) partial
Returns the value of attribute partial.
Class Method Summary (collapse)
Instance Attribute Details
- (Object) name
Returns the value of attribute name
11 12 13 |
# File 'pages/lib/refinery/pages/tab.rb', line 11 def name @name end |
- (Object) partial
Returns the value of attribute partial
11 12 13 |
# File 'pages/lib/refinery/pages/tab.rb', line 11 def partial @partial end |
Class Method Details
+ (Object) register {|tab| ... }
13 14 15 16 17 18 19 20 |
# File 'pages/lib/refinery/pages/tab.rb', line 13 def self.register(&block) tab = self.new yield tab raise "A tab MUST have a name!: #{tab.inspect}" if tab.name.blank? raise "A tab MUST have a partial!: #{tab.inspect}" if tab.partial.blank? end |