camaleon_spree 0.0.1 → 0.0.2
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 +4 -4
- data/config/initializers/routes.rb +15 -10
- data/lib/camaleon_spree/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: 0dfaf8971a7a688eb8494173bd9831aa327c1839
|
|
4
|
+
data.tar.gz: adbead18ce9160dc0f24c46e97d016efb0465cfd
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 28adadb28f2699ada78c886923a2b50313f038f6cba3ed1cb63d4ed54aa63d463cf8283edd644efa631f1517d6d6ace6226f2677e3894565075481a2ebe5b62b
|
|
7
|
+
data.tar.gz: 2af69f1cafd2c4b523ad602c83611d33dbda58d0db3675f84231a64ca31486ef7727dd4b6a79e3377c43caaf3f141955e45089024b9d152151b0fcdb0aeee240
|
|
@@ -1,9 +1,21 @@
|
|
|
1
1
|
class Camaspreehelperroutes
|
|
2
2
|
def self.update_helper_routes
|
|
3
|
-
|
|
3
|
+
|
|
4
|
+
# not arguments
|
|
5
|
+
_routes = ['cama_profile', 'cama_search', 'cama_post_of_posttype', 'cama_save_comment', 'cama_save_form', 'cama_post_type', 'cama_hierarchy_post', 'cama_post_tag', 'cama_post', 'cama_root', 'cama_admin', 'cama_admin_dashboard',
|
|
6
|
+
'cama_category', 'cama_post_of_category', 'cama_post_of_post_type', 'cama_post_type']
|
|
4
7
|
_routes += Cama::PostType.pluck(:id).map{|id| "cama_post_type_#{id}"}
|
|
5
8
|
|
|
6
|
-
|
|
9
|
+
# three arguments
|
|
10
|
+
['edit_cama_admin_post_type_post_tag_url', 'edit_cama_admin_post_type_post_url'].each do |u|
|
|
11
|
+
Spree::BaseHelper.module_eval <<-eoruby, __FILE__, __LINE__ + 1
|
|
12
|
+
def #{u}(pt_id, object, args)
|
|
13
|
+
Rails.application.routes.url_helpers.#{u}(pt_id, object, args)
|
|
14
|
+
end
|
|
15
|
+
eoruby
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
_cama_lang_routes = ['cama_post_type']
|
|
7
19
|
Cama::Site.main_site.get_languages.each{|_l| _cama_lang_routes.each{|_r| _routes << "#{_r}_#{_l}" } }
|
|
8
20
|
_routes.each do |x|
|
|
9
21
|
Spree::BaseHelper.module_eval <<-eoruby, __FILE__, __LINE__ + 1
|
|
@@ -17,14 +29,7 @@ class Camaspreehelperroutes
|
|
|
17
29
|
eoruby
|
|
18
30
|
end
|
|
19
31
|
|
|
20
|
-
|
|
21
|
-
Spree::BaseHelper.module_eval <<-eoruby, __FILE__, __LINE__ + 1
|
|
22
|
-
def #{u}(pt_id, object, args)
|
|
23
|
-
Rails.application.routes.url_helpers.#{u}(pt_id, object, args)
|
|
24
|
-
end
|
|
25
|
-
eoruby
|
|
26
|
-
end
|
|
27
|
-
|
|
32
|
+
# two arguments
|
|
28
33
|
['edit_cama_admin_post_type_category_url', 'edit_cama_admin_settings_post_type_url'].each do |u|
|
|
29
34
|
Spree::BaseHelper.module_eval <<-eoruby, __FILE__, __LINE__ + 1
|
|
30
35
|
def #{u}(id, args)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: camaleon_spree
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Owen Peredo
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-01-
|
|
11
|
+
date: 2017-01-08 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|