Revision 2083
Added by Jean-Philippe Lang over 16 years ago
trunk/vendor/plugins/acts_as_activity_provider/lib/acts_as_activity_provider.rb | ||
---|---|---|
66 | 66 |
end |
67 | 67 |
cond.add(Project.allowed_to_condition(user, provider_options[:permission], options)) if provider_options[:permission] |
68 | 68 |
scope_options[:conditions] = cond.conditions |
69 |
scope_options[:order] = "#{provider_options[:timestamp]} DESC" |
|
70 |
scope_options[:limit] = options[:limit] |
|
69 |
if options[:limit] |
|
70 |
# id and creation time should be in same order in most cases |
|
71 |
scope_options[:order] = "#{table_name}.id DESC" |
|
72 |
scope_options[:limit] = options[:limit] |
|
73 |
end |
|
71 | 74 |
|
72 | 75 |
with_scope(:find => scope_options) do |
73 | 76 |
find(:all, provider_options[:find_options]) |
Also available in: Unified diff
Fixed: activity broken by r2066 with postgresql (#2266).