Changeset 11

Show
Ignore:
Timestamp:
09/11/06 15:22:39 (2 years ago)
Author:
jcm
Message:

#16 some more corrs

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/better_nested_set_helper.rb

    r10 r11  
    4343      #  * +&block+ - a block { |item, current?| ... item.name } 
    4444      # 
    45       def nested_set_full_outline(item, options=nil
     45      def nested_set_full_outline(item, options={}
    4646        return if item.nil? 
    4747        raise 'Not a nested set model !' if !item.respond_to? :acts_as_nested_set_options 
     
    5050          :text_column => options[:text_column] || item.acts_as_nested_set_options[:text_column], 
    5151          :action => options[:action] || :show, 
    52           :controller => options[:controller] || item.class.underscore, 
     52          :controller => options[:controller] || item.class.to_s.underscore, 
    5353          :separator => options[:separator] || ' > ' } 
    5454         
     
    6464          s + yield(item) 
    6565        else 
    66           s + h(item[:text_column]) 
     66          s + h(item[options[:text_column]]) 
    6767        end 
    6868      end