Module: CollectiveIdea::Acts::NestedSet::Base::Columns
- Defined in:
- lib/awesome_nested_set/base.rb
Overview
Mixed into both classes and instances to provide easy access to the column names
Instance Method Summary collapse
- #left_column_name ⇒ Object
- #parent_column_name ⇒ Object
- #quoted_left_column_name ⇒ Object
- #quoted_parent_column_name ⇒ Object
- #quoted_right_column_name ⇒ Object
- #quoted_scope_column_names ⇒ Object
- #right_column_name ⇒ Object
- #scope_column_names ⇒ Object
Instance Method Details
#left_column_name ⇒ Object
240 241 242 |
# File 'lib/awesome_nested_set/base.rb', line 240 def left_column_name [:left_column] end |
#parent_column_name ⇒ Object
248 249 250 |
# File 'lib/awesome_nested_set/base.rb', line 248 def parent_column_name [:parent_column] end |
#quoted_left_column_name ⇒ Object
256 257 258 |
# File 'lib/awesome_nested_set/base.rb', line 256 def quoted_left_column_name connection.quote_column_name(left_column_name) end |
#quoted_parent_column_name ⇒ Object
264 265 266 |
# File 'lib/awesome_nested_set/base.rb', line 264 def quoted_parent_column_name connection.quote_column_name(parent_column_name) end |
#quoted_right_column_name ⇒ Object
260 261 262 |
# File 'lib/awesome_nested_set/base.rb', line 260 def quoted_right_column_name connection.quote_column_name(right_column_name) end |
#quoted_scope_column_names ⇒ Object
268 269 270 |
# File 'lib/awesome_nested_set/base.rb', line 268 def quoted_scope_column_names scope_column_names.collect {|column_name| connection.quote_column_name(column_name) } end |
#right_column_name ⇒ Object
244 245 246 |
# File 'lib/awesome_nested_set/base.rb', line 244 def right_column_name [:right_column] end |
#scope_column_names ⇒ Object
252 253 254 |
# File 'lib/awesome_nested_set/base.rb', line 252 def scope_column_names Array([:scope]) end |