shopping_mall 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7b5fc44e44f6874db096fe4cb4e71d5fbc3795c9
4
- data.tar.gz: 90083938a7dcea8726c21baf9064aaedc01aab64
3
+ metadata.gz: 74c4b187808c6221adf48e43422b69d56ac71cfb
4
+ data.tar.gz: 0538b25abf28709c37a52843ab4307e7c9b7f759
5
5
  SHA512:
6
- metadata.gz: 3656cfe63e4b35ee5f31b94c70a0b69122f943a969c430c0fabe1f8f9e95a3c278154745602cc660aefe10a30d911e68b7f8e7aa46768b52ee7a70b210fa95c7
7
- data.tar.gz: 542079ae4d5dee56f4672ae578cfaa586b5507e0a4db1dca915764a15d5b4f91d41d15d4a3a33af0c03e761af9b979f1564199f9851f63405589abe5aeda644a
6
+ metadata.gz: 0ce2ce527e9f5bd0d35f147dc60e0494f8bfb1dd444191c1b8f59378c163f4f92fb70a3e4e922181529ca3c17bb2209893ce2cd84bd1767201c2f79ff2783b51
7
+ data.tar.gz: 67574904f5bb721ed8db80049c11b9ccd321c50b911851e0ea0c3a7fe9efaf2133e6dd33643b81ea41a5edcd2ecc76b37f53b2b4328159b4555f43f31e571492
@@ -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
@@ -1,3 +1,3 @@
1
1
  module ShoppingMall
2
- VERSION = '0.0.3'
2
+ VERSION = '0.0.4'
3
3
  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.3
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-11 00:00:00.000000000 Z
12
+ date: 2015-03-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: apartment