molten-trunk/molten5_withgrid/app/models/sfsolution.rb
def category_tree
    cats = []
    categories.each do |cat|
      cats << cat
      cats = cats + cat.ancestors
    end
    return cats
  end
# Returns an array of +Sfnodes+ with all of the categories that the solution belongs to, including
# its ancestors.
Returns an array of +Sfnodes+ with all of the categories that the solution belongs to, including
its ancestors.
Returns an array of + Sfnodes + with all of the categories that the solution belongs to including its ancestors .
def category_tree
    cats = []
    categories.each do |cat|
      cats << cat
      cats = cats + cat.ancestors
    end
    return cats
  end
def category_tree cats = [ ] categories . each do | cat | cats << cat cats = cats + cat . ancestors end return cats end
Returns an array of +Sfnodes+ with all of the categories that the solution belongs to, including
its ancestors.
Returns an array of + Sfnodes + with all of the categories that the solution belongs to including its ancestors .