oare 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/active_resource_override/base.rb +4 -0
- data/oare.gemspec +1 -1
- metadata +1 -1
@@ -4,6 +4,10 @@ module Oare
|
|
4
4
|
@associations ||= []
|
5
5
|
class_name = options[:class_name] || association_id.to_s.singularize.camelize
|
6
6
|
@associations << class_name.constantize
|
7
|
+
define_method(association_id) do |*args|
|
8
|
+
resource = find_or_create_resource_for_collection(class_name)
|
9
|
+
resource.reload
|
10
|
+
end
|
7
11
|
end
|
8
12
|
|
9
13
|
def connection(refresh = true)
|
data/oare.gemspec
CHANGED