dynamodb_geo 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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d340e57a2a4560a39e25bced58d8bbef10427e1d7597cfb855dee033f4592ebe
4
- data.tar.gz: 26125976630f46b293e2903155c242c89f32e1b8aab70f9a545042cbf3cb1438
3
+ metadata.gz: f54f79a1153702913ca165972a8936865949156e28970e62efc06e23076b0773
4
+ data.tar.gz: 4171efed028b0cc80b39b35fe951c065da01ac6b7978c11e4264e9da5e0d5be1
5
5
  SHA512:
6
- metadata.gz: 0d6c3b08e34a6fe3414d6694694294171fe561e05f11028f426971efef422505474646518bee6f9a767ba66f7b798a886c794c095b3671c1b4853b1b61a3d332
7
- data.tar.gz: 10ef5eb008734bf7dcb536e2d276c28e59a581515637a3ba69746a45fa07f712856d49f694209f222a915ab138328aabaac6dc7414d9dae44310e5ec93965f9a
6
+ metadata.gz: 04fec0da4cf2f1f62df873fd364dda594028ad566b283bd6ad56573f5d8c156237c5eb691546697001195944a483038931ee4728a8f317d9600b5114bb22af57
7
+ data.tar.gz: d3a7da451c4e43850c0a3b44db65f967bd28df66ea35848be57d28eb5755a47a1cb1df7a2d87a29bb0af94eec583a889ba0231f35112f4bafa0003a86a539e68
@@ -1,5 +1,5 @@
1
1
  module DynamodbGeo
2
2
  class Version
3
- STRING = '0.1.4'
3
+ STRING = '0.1.5'
4
4
  end
5
5
  end
@@ -69,7 +69,28 @@ class DynamodbManager
69
69
  neighbours.each do |neighbour|
70
70
  resp = query(neighbour)
71
71
  resp.items.each do |item|
72
- all_stores << Store.new(item['geoJson'])
72
+ latitude = item[@geojson]['latitude']
73
+ longitude = item[@geojson]['longitude']
74
+ address = item[@geojson]['address']
75
+ city = item[@geojson]['city']
76
+ state = item[@geojson]['state']
77
+ zip = item[@geojson]['zip']
78
+ area_code = item[@geojson]['area_code']
79
+ phone = item[@geojson]['phone']
80
+ name = item[@geojson]['name']
81
+ geohash = item[@geohash_key]
82
+ all_stores << Store.new(
83
+ latitude: latitude,
84
+ longitude: longitude,
85
+ address: address,
86
+ city: city,
87
+ state: state,
88
+ zip: zip,
89
+ area_code: area_code,
90
+ phone: phone,
91
+ name: name,
92
+ geohash: geohash
93
+ )
73
94
  end
74
95
  break if all_stores.length >= max_item_return
75
96
  end
@@ -11,7 +11,7 @@ describe DynamodbGeo do
11
11
  )
12
12
  expect(dynamo).to be_a DynamodbManager
13
13
 
14
- debugger;1
14
+ dynamo.get_stores(37.746825, -122.413637)
15
15
  puts 'foo'
16
16
  end
17
17
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dynamodb_geo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justin Ahn
@@ -127,7 +127,7 @@ requirements: []
127
127
  rubygems_version: 3.1.2
128
128
  signing_key:
129
129
  specification_version: 4
130
- summary: dynamodb_geo-0.1.4
130
+ summary: dynamodb_geo-0.1.5
131
131
  test_files:
132
132
  - spec/dynamodb_geo_spec.rb
133
133
  - spec/geohash_spec.rb