shopping_mall 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/shopping_mall/engine.rb +14 -0
- data/lib/shopping_mall/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 74c4b187808c6221adf48e43422b69d56ac71cfb
|
4
|
+
data.tar.gz: 0538b25abf28709c37a52843ab4307e7c9b7f759
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ce2ce527e9f5bd0d35f147dc60e0494f8bfb1dd444191c1b8f59378c163f4f92fb70a3e4e922181529ca3c17bb2209893ce2cd84bd1767201c2f79ff2783b51
|
7
|
+
data.tar.gz: 67574904f5bb721ed8db80049c11b9ccd321c50b911851e0ea0c3a7fe9efaf2133e6dd33643b81ea41a5edcd2ecc76b37f53b2b4328159b4555f43f31e571492
|
data/lib/shopping_mall/engine.rb
CHANGED
@@ -14,5 +14,19 @@ module ShoppingMall
|
|
14
14
|
end
|
15
15
|
|
16
16
|
config.to_prepare(&method(:activate).to_proc)
|
17
|
+
|
18
|
+
initializer "shopping_mall.user_roles" do
|
19
|
+
Spree.user_class.class_eval do
|
20
|
+
# Unfortunately, since `Spree.user_class#spree_roles is a HABTM
|
21
|
+
# association, it won't work with apartment / shopping_mall
|
22
|
+
#
|
23
|
+
# This also won't work if it resides on app/models/user_decorator.rb
|
24
|
+
# because it gets eval'ed (above in `.activate`) *after* Spree Core
|
25
|
+
# adds extensions to Spree.user_class
|
26
|
+
def spree_roles
|
27
|
+
roles
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
17
31
|
end
|
18
32
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: shopping_mall
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vincent Franco
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-03-
|
12
|
+
date: 2015-03-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: apartment
|