diff options
| author | hukl <hukl@eight.local> | 2009-01-31 16:00:05 +0100 |
|---|---|---|
| committer | hukl <hukl@eight.local> | 2009-01-31 16:00:05 +0100 |
| commit | 482448d05686b6aaa549208dafa36d682b3059b6 (patch) | |
| tree | d2c7cd8c5539506600667c56e74602bc54b85edc /app | |
| parent | 5b06d137fc6143ff679d1ce6048c4149ca23f4e2 (diff) | |
made sure that returned pages are always ordered
by there revision
Diffstat (limited to 'app')
| -rw-r--r-- | app/models/node.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/node.rb b/app/models/node.rb index cac4495..6e54004 100644 --- a/app/models/node.rb +++ b/app/models/node.rb | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | class Node < ActiveRecord::Base | 1 | class Node < ActiveRecord::Base |
| 2 | acts_as_nested_set | 2 | acts_as_nested_set |
| 3 | 3 | ||
| 4 | has_many :pages | 4 | has_many :pages, :order => "revision ASC" |
| 5 | 5 | ||
| 6 | # returns array with pages up to root excluding root | 6 | # returns array with pages up to root excluding root |
| 7 | def path_to_root | 7 | def path_to_root |
