omniorder 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/omniorder/import_strategy/base.rb +18 -0
- data/lib/omniorder/import_strategy/groupon.rb +1 -1
- data/lib/omniorder/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: d7e7efc2ebd649ff319459de8a0760bcd6331001
|
4
|
+
data.tar.gz: 711d3f5d76e2650a6a499926b0be94bd31f346ee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 29329c7d41987a63e67eda25e248ec7655216f0d4dfbf65660b91b1af5d5f09084395247547f9f866272a7395e8d1483650fb2e0cb44f4611624071b5f026fbd
|
7
|
+
data.tar.gz: 501165b13166f32f1b514a839fe4cc43e17693f2b94096c92f79add4b78e09edee7133a8f227043168b711929aa9f9a7160c32d9d6d0518b32d5d8f40816c6f8
|
@@ -20,6 +20,16 @@ module Omniorder
|
|
20
20
|
def from_name(name)
|
21
21
|
Utils.constantize "Omniorder::ImportStrategy::#{Utils.camelize name}"
|
22
22
|
end
|
23
|
+
|
24
|
+
def after_build_order(&block)
|
25
|
+
if block_given?
|
26
|
+
@after_build_order_block = block
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
def after_build_order_block
|
31
|
+
@after_build_order_block
|
32
|
+
end
|
23
33
|
end
|
24
34
|
|
25
35
|
def initialize(import, options = {})
|
@@ -49,6 +59,14 @@ module Omniorder
|
|
49
59
|
country
|
50
60
|
end
|
51
61
|
end
|
62
|
+
|
63
|
+
def after_build_order(order, order_info)
|
64
|
+
if self.class.after_build_order_block
|
65
|
+
self.class.after_build_order_block.call(order, order_info)
|
66
|
+
end
|
67
|
+
|
68
|
+
order
|
69
|
+
end
|
52
70
|
end
|
53
71
|
end
|
54
72
|
end
|
data/lib/omniorder/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniorder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Howard Wilson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-11-
|
11
|
+
date: 2014-11-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: crack
|