mercadolibre 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/mercadolibre.rb +1 -0
- data/lib/mercadolibre/entity/feedback.rb +2 -0
- data/lib/mercadolibre/entity/feedback_reply.rb +33 -0
- data/lib/mercadolibre/entity/site.rb +1 -1
- data/lib/mercadolibre/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c5acc11835e2d0d774843063e4b453988fa6a0e1
|
4
|
+
data.tar.gz: adee422ec7ba5e0d366fe71ec556f4db6c7d9201
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 543a27fbe6cca691313d4e7ff6b49055fffe7df5a89105e7f2a5b4c52df104514ba9ac9f7c25c1e059abd72289cfb083c20e9830e57c21d7486fbc87a49a7899
|
7
|
+
data.tar.gz: fb4256f9de382ee5b65114847f651b6f3c2ab78fa5c666420292a70e37bb0e43e20ddc00530f99c6e00e96b25948b10f1bedd022b993c9ffc47a6ca1d202ca4c
|
data/CHANGELOG.md
CHANGED
data/lib/mercadolibre.rb
CHANGED
@@ -17,6 +17,7 @@ require "mercadolibre/entity/currency"
|
|
17
17
|
require "mercadolibre/entity/currency_conversion_ratio"
|
18
18
|
require "mercadolibre/entity/featured_item"
|
19
19
|
require "mercadolibre/entity/feedback"
|
20
|
+
require "mercadolibre/entity/feedback_reply"
|
20
21
|
require "mercadolibre/entity/item"
|
21
22
|
require "mercadolibre/entity/item_description"
|
22
23
|
require "mercadolibre/entity/item_picture"
|
@@ -0,0 +1,33 @@
|
|
1
|
+
module Mercadolibre
|
2
|
+
module Entity
|
3
|
+
class FeedbackReply
|
4
|
+
def self.attr_list
|
5
|
+
[:message, :reply_date, :reply_status]
|
6
|
+
end
|
7
|
+
|
8
|
+
attr_reader *attr_list
|
9
|
+
|
10
|
+
def initialize(attributes={})
|
11
|
+
attributes.each do |k, v|
|
12
|
+
if ['date_created', 'visibility_date'].include?(k.to_s)
|
13
|
+
self.date_created = Time.parse(v) unless v.nil?
|
14
|
+
elsif k.to_s == 'to'
|
15
|
+
self.to = User.new(v)
|
16
|
+
elsif k.to_s == 'from'
|
17
|
+
self.from = User.new(v)
|
18
|
+
elsif k.to_s == 'item'
|
19
|
+
self.item = Item.new(v)
|
20
|
+
elsif k.to_s == 'reply'
|
21
|
+
self.reply = FeedbackReply.new(v)
|
22
|
+
else
|
23
|
+
self.send("#{k}=", v) if self.respond_to?(k)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
private
|
29
|
+
|
30
|
+
attr_writer *attr_list
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
data/lib/mercadolibre/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mercadolibre
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matias Hick
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-11
|
11
|
+
date: 2014-12-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -87,6 +87,7 @@ files:
|
|
87
87
|
- lib/mercadolibre/entity/currency_conversion_ratio.rb
|
88
88
|
- lib/mercadolibre/entity/featured_item.rb
|
89
89
|
- lib/mercadolibre/entity/feedback.rb
|
90
|
+
- lib/mercadolibre/entity/feedback_reply.rb
|
90
91
|
- lib/mercadolibre/entity/item.rb
|
91
92
|
- lib/mercadolibre/entity/item_description.rb
|
92
93
|
- lib/mercadolibre/entity/item_picture.rb
|