effective_qb_online 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/effective/qb_api.rb +10 -1
- data/lib/effective_qb_online/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b576a3949ed29e03fff73780968b77c380cd4454c8117b39aba87690f96a0ae9
|
4
|
+
data.tar.gz: c16c7f2ad020a416e0fae62fa98016cff913f1bd372e4e06feb8cd042954ebae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 07c548ac7ea522e377897dca08cb17f77b3db74b3633bd61135584297857c04100a7adc1942f410b141dbbb2c7e3968e748c2769f4e32c98fbd627977924c8fc
|
7
|
+
data.tar.gz: d4986d17edbe98241942c5888537f2593fcbab09a0ddf81c6194989a0daf7db7124025c992c0d39ac1157077314cd8b6dd3dcdbdecd6dabd05e4a00e428e6c99
|
@@ -75,10 +75,19 @@ module Effective
|
|
75
75
|
items
|
76
76
|
.reject { |item| item.type == 'Category' }
|
77
77
|
.sort_by { |item| [item.type, item.name] }
|
78
|
-
.map { |item| [item
|
78
|
+
.map { |item| [item_name(item), item.id, {'data-html': item_html(item)}, item.type] }
|
79
79
|
.group_by(&:last)
|
80
80
|
end
|
81
81
|
|
82
|
+
def item_name(item)
|
83
|
+
[
|
84
|
+
item.name,
|
85
|
+
("##{item.id}"),
|
86
|
+
(item.sku if item.sku.present?),
|
87
|
+
(item.description if item.description.present?)
|
88
|
+
].compact.join(' ')
|
89
|
+
end
|
90
|
+
|
82
91
|
def item_html(item)
|
83
92
|
details = [
|
84
93
|
("##{item.id}"),
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_qb_online
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|