google-place-text-search 0.0.2 → 1.0.0
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/lib/google_place_text_search.rb +4 -5
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1dbf945f168328d10f9cae9238088c2635ea81ce
|
|
4
|
+
data.tar.gz: 7a61566ccf24e334c2b5e2fc19930f16494c4205
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 441063133b1292009014860bb47fc9177a9605ff56479ddf8b9884ec4bb03af9ca61597d24888550f52f72f90d64c8a9cd918297d94d53c4369dced7159b0ea9
|
|
7
|
+
data.tar.gz: 837dd8508bd7637bdc40d9692b6ddd5651ee09e118c1a501b904450929823ed3632bff7403a5039614eb58f2a658f71bf26905500c4f9fb6a52493482c4d3864
|
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
class GooglePlaceTextSearch
|
|
2
|
-
require 'debugger'
|
|
3
2
|
require 'httparty'
|
|
4
3
|
require 'json'
|
|
5
|
-
|
|
4
|
+
|
|
6
5
|
def get_response(api_key,radius,location,query)
|
|
7
6
|
url = "https://maps.googleapis.com/maps/api/place/textsearch/json"
|
|
8
7
|
#location="#{lat},#{lng}"
|
|
9
|
-
|
|
8
|
+
|
|
10
9
|
query_data = {:key=>api_key,:query=>query, :location=>location,:radius=>radius}
|
|
11
10
|
response = HTTParty.get("#{url}", :query=>query_data)
|
|
12
11
|
|
|
13
12
|
json = JSON.parse(response.body)
|
|
14
13
|
return json
|
|
15
14
|
end
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
|
|
16
|
+
|
|
18
17
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: google-place-text-search
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0
|
|
4
|
+
version: 1.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Abhishek Sharma
|
|
@@ -42,3 +42,4 @@ signing_key:
|
|
|
42
42
|
specification_version: 4
|
|
43
43
|
summary: Hello! This is for getting places with formatted address in bulk
|
|
44
44
|
test_files: []
|
|
45
|
+
has_rdoc:
|