chart_mogul 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/chart_mogul/import_api.rb +8 -5
- data/lib/chart_mogul/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 61990dbfe59f11eb6b6c2181ef43fb0aa6d8ce41
|
4
|
+
data.tar.gz: 419bb62bd7a07176816c7e71a86c5554af3e4c08
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1a48321b8452dca52862b161e4e7aa36b7ca97ca825eabb30ee37743307ccfc77d0b8dbb7dc6a96707f7527a8d17b17a0e412df4b1dae65aa7b36f2e54072902
|
7
|
+
data.tar.gz: 3f9ad234c0784a4a1d57eb2437937479c8574a463ebdd580101775f5d8ef7df987a0fd78d26a3f6b19ff6605a4d0b56fe9ac29c712e0e17d18c7686653144ec2
|
@@ -36,19 +36,22 @@ module ChartMogul
|
|
36
36
|
Import::DataSource.new(preprocess_response(response))
|
37
37
|
end
|
38
38
|
|
39
|
-
# Public - purge all data
|
39
|
+
# Public - delete DataSource and purge all related data
|
40
40
|
# super dangerous
|
41
41
|
#
|
42
42
|
# Returns nothing but an empty hole where your data was!
|
43
|
-
def
|
43
|
+
def delete_data_source!(data_source_uuid)
|
44
44
|
response = connection.delete do |request|
|
45
|
-
request.url "/v1/import/data_sources/#{data_source_uuid}
|
46
|
-
request.headers['Content-Type'] = "application/json"
|
47
|
-
request.body = { confirm: 1 }.to_json
|
45
|
+
request.url "/v1/import/data_sources/#{data_source_uuid}"
|
48
46
|
end
|
49
47
|
response.status == 202
|
50
48
|
end
|
51
49
|
|
50
|
+
|
51
|
+
# Public - purge all data for a DataSource
|
52
|
+
# alias for backwards compatibility
|
53
|
+
alias_method :purge_data_source!, :delete_data_source!
|
54
|
+
|
52
55
|
# Public - list all Customers.
|
53
56
|
# this will page through all customers see #list_customers_each
|
54
57
|
# for iterator method to prevent loading the whole array in
|
data/lib/chart_mogul/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chart_mogul
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Bird
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-06-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -127,7 +127,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
127
127
|
version: '0'
|
128
128
|
requirements: []
|
129
129
|
rubyforge_project:
|
130
|
-
rubygems_version: 2.
|
130
|
+
rubygems_version: 2.4.5.1
|
131
131
|
signing_key:
|
132
132
|
specification_version: 4
|
133
133
|
summary: Gem for working with the ChartMogul API
|