liquid-rails 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 54955a6c51334d96d643bbbbd38c1525249fd772
4
- data.tar.gz: b950dc24be7dd7bd91cf7694006c8a4de8791cff
3
+ metadata.gz: 6cf80003f4e5afccb1bb11c63598451b490cbc3c
4
+ data.tar.gz: 9da75ddc9f386a7d89daded403b7661080ca8cc5
5
5
  SHA512:
6
- metadata.gz: 58bf7986347e7bf2785b23765b16f9061b94f3c86f0e29d9d22e3ae049e835de7ed2e1aabbf0e4ec9a796cf622b29a5ad149033eb1e9212943972ed5a53c0aa6
7
- data.tar.gz: 2a2ee583078fc85af996b4f58185d790a4fdc3a9dc5ae4dfdda6f8d4c58d9f5f2c5e8d35a0bc86592d977952a0f6beb061c46bcde08d5c779aceb25b2754199b
6
+ metadata.gz: 46cb2385e33a844d8a34127f571f3b28d53d33969c1d73e331935fddd04a94cbce98ba7d6005b564376bd73f473dab1a7300d21d104259b3529f36a8158d5617
7
+ data.tar.gz: 7882c2d36e2353de0422c2e2d55457369b6534592404bff711ce940df4e102582dac1debde8323b5f2192b6f7a3a64ee968ea46214430bfd7445438b47ca1608
@@ -71,6 +71,7 @@ module Liquid
71
71
 
72
72
  association = associations[name]
73
73
  result = association.present? && association[:type] == options[:type]
74
+ result = result && association[:options][:scope] == options[:scope] if options[:scope]
74
75
  result = result && association[:options][:with] == options[:with] if options[:with]
75
76
  result = result && association[:options][:class_name] == options[:class_name] if options[:class_name]
76
77
 
@@ -82,6 +83,11 @@ module Liquid
82
83
  self
83
84
  end
84
85
 
86
+ def scope(scope_name)
87
+ @options[:scope] = scope_name
88
+ self
89
+ end
90
+
85
91
  def class_name(class_name)
86
92
  @options[:class_name] = class_name
87
93
  self
@@ -1,5 +1,5 @@
1
1
  module Liquid
2
2
  module Rails
3
- VERSION = '0.1.2'
3
+ VERSION = '0.1.3'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: liquid-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chamnap Chhorn
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-18 00:00:00.000000000 Z
11
+ date: 2015-09-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -197,7 +197,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
197
197
  version: 1.8.11
198
198
  requirements: []
199
199
  rubyforge_project:
200
- rubygems_version: 2.4.5
200
+ rubygems_version: 2.4.6
201
201
  signing_key:
202
202
  specification_version: 4
203
203
  summary: Renders liquid templates with layout and partial support