search for: taxtree_frozen

Displaying 1 result from an estimated 1 matches for "taxtree_frozen".

2006 Jan 19
0
Problem with an Tree-like object hierarchy (ActiveRecord acts_as_tree)
...hat its traversing all the way up to the root, but only the activation of the node called will ''stick''. speaking of ''stick'', to preserve the tree between requests I store it in the session variable and retrieve it from there: def unfreeze_taxtree if taxtree_frozen then return Marshal.load(session[:tax_tree]) else return nil end end def freeze_taxtree(tax) return session[:tax_tree] = Marshal.dump(tax) end def get_tax_from_freezer(tax_id) @@tax_tree = unfreeze_taxtree ObjectSpace._id2ref(@@tax_tree.find_tax(tax_id)) end...