shipstation 0.14.5 → 0.15.5
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/Rakefile +1 -5
- data/lib/shipstation.rb +53 -49
- data/lib/shipstation/api_operations/create.rb +7 -7
- data/lib/shipstation/api_operations/delete.rb +9 -9
- data/lib/shipstation/api_operations/list.rb +7 -7
- data/lib/shipstation/api_operations/retrieve.rb +7 -7
- data/lib/shipstation/api_operations/update.rb +9 -9
- data/lib/shipstation/api_resource.rb +4 -4
- data/lib/shipstation/carrier.rb +7 -7
- data/lib/shipstation/customer.rb +4 -4
- data/lib/shipstation/order.rb +34 -26
- data/lib/shipstation/product.rb +5 -5
- data/lib/shipstation/shipment.rb +8 -8
- data/lib/shipstation/store.rb +10 -10
- data/lib/shipstation/tag.rb +8 -8
- data/lib/shipstation/version.rb +1 -1
- data/lib/shipstation/warehouse.rb +10 -10
- data/test/dummy/Gemfile +3 -4
- data/test/dummy/app/views/layouts/application.html.erb +4 -4
- data/test/dummy/bin/setup +1 -1
- data/test/dummy/bin/spring +1 -1
- data/test/dummy/config/environments/development.rb +1 -1
- data/test/dummy/config/environments/production.rb +1 -1
- data/test/dummy/config/environments/test.rb +2 -2
- data/test/dummy/public/404.html +52 -52
- data/test/dummy/public/422.html +52 -52
- data/test/dummy/public/500.html +51 -51
- data/test/test_helper.rb +2 -2
- 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: 4833914777ca0e291463f3fb3ba1a39035096868
|
4
|
+
data.tar.gz: b3995a0bbc710f96635c6f5b26aafe20b74518da
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4f81fd828b7379643f0d1015d2e35fea518f1d3642a32dc364c6deec35c6fe7b0210e1aa6e91194d0a02ee36508fe981fc753824587bb509046bb1adc57c377e
|
7
|
+
data.tar.gz: 99340d2f36adb97cfc99c3c2a89c3ad2054f74e25b483f23618b701fa185dd7773ff1bc125a4f5bc6732a04c743a6019ba79c16e167332248ee5317137c2383c
|
data/Rakefile
CHANGED
@@ -8,17 +8,13 @@ require 'rdoc/task'
|
|
8
8
|
|
9
9
|
RDoc::Task.new(:rdoc) do |rdoc|
|
10
10
|
rdoc.rdoc_dir = 'rdoc'
|
11
|
-
rdoc.title
|
11
|
+
rdoc.title = 'Shipstation'
|
12
12
|
rdoc.options << '--line-numbers'
|
13
13
|
rdoc.rdoc_files.include('README.rdoc')
|
14
14
|
rdoc.rdoc_files.include('lib/**/*.rb')
|
15
15
|
end
|
16
16
|
|
17
17
|
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
18
|
Bundler::GemHelper.install_tasks
|
23
19
|
|
24
20
|
require 'rake/testtask'
|
data/lib/shipstation.rb
CHANGED
@@ -17,63 +17,67 @@ require 'shipstation/product'
|
|
17
17
|
require 'shipstation/tag'
|
18
18
|
|
19
19
|
module Shipstation
|
20
|
-
|
20
|
+
API_BASE = "https://ssapi.shipstation.com/"
|
21
21
|
|
22
|
-
|
22
|
+
class ShipstationError < StandardError
|
23
|
+
end
|
24
|
+
|
25
|
+
class AuthenticationError < ShipstationError;
|
26
|
+
end
|
27
|
+
class ConfigurationError < ShipstationError;
|
28
|
+
end
|
29
|
+
|
30
|
+
class << self
|
31
|
+
def username
|
32
|
+
defined? @username and @username or raise(
|
33
|
+
ConfigurationError, "Shipstation username not configured"
|
34
|
+
)
|
23
35
|
end
|
24
36
|
|
25
|
-
|
26
|
-
class ConfigurationError < ShipstationError; end
|
37
|
+
attr_writer :username
|
27
38
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
end
|
34
|
-
attr_writer :username
|
39
|
+
def password
|
40
|
+
defined? @password and @password or raise(
|
41
|
+
ConfigurationError, "Shipstation password not configured"
|
42
|
+
)
|
43
|
+
end
|
35
44
|
|
36
|
-
|
37
|
-
defined? @password and @password or raise(
|
38
|
-
ConfigurationError, "Shipstation password not configured"
|
39
|
-
)
|
40
|
-
end
|
41
|
-
attr_writer :password
|
45
|
+
attr_writer :password
|
42
46
|
|
43
|
-
|
44
|
-
|
45
|
-
|
47
|
+
def request method, resource, params = {}
|
48
|
+
ss_username = params[:username] || Shipstation.username
|
49
|
+
ss_password = params[:password] || Shipstation.password
|
46
50
|
|
47
|
-
|
51
|
+
params.except!(:username, :password)
|
48
52
|
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
53
|
+
defined? method or raise(
|
54
|
+
ArgumentError, "Request method has not been specified"
|
55
|
+
)
|
56
|
+
defined? resource or raise(
|
57
|
+
ArgumentError, "Request resource has not been specified"
|
58
|
+
)
|
59
|
+
if method == :get
|
60
|
+
headers = {:accept => :json, content_type: :json}.merge({params: params})
|
61
|
+
payload = nil
|
62
|
+
else
|
63
|
+
headers = {:accept => :json, content_type: :json}
|
64
|
+
payload = params
|
65
|
+
end
|
66
|
+
RestClient::Request.new({
|
67
|
+
method: method,
|
68
|
+
url: API_BASE + resource,
|
69
|
+
user: ss_username,
|
70
|
+
password: ss_password,
|
71
|
+
payload: payload ? payload.to_json : nil,
|
72
|
+
headers: headers
|
73
|
+
}).execute do |response, request, result|
|
74
|
+
str_response = response.to_str
|
75
|
+
str_response.blank? ? '' : JSON.parse(str_response)
|
76
|
+
end
|
77
|
+
end
|
74
78
|
|
75
|
-
|
76
|
-
|
77
|
-
end
|
79
|
+
def datetime_format datetime
|
80
|
+
datetime.strftime("%Y-%m-%d %T")
|
78
81
|
end
|
82
|
+
end
|
79
83
|
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
2
|
+
module APIOperations
|
3
|
+
module Create
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
end
|
5
|
+
def create params = {}
|
6
|
+
response = Shipstation.request(:post, "#{class_name.downcase.pluralize}/create#{class_name.downcase}", params)
|
7
|
+
return response
|
8
|
+
end
|
10
9
|
end
|
10
|
+
end
|
11
11
|
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
2
|
+
module APIOperations
|
3
|
+
module Delete
|
4
|
+
|
5
|
+
def delete object_id, params = {}
|
6
|
+
Shipstation.request(:delete, "#{class_name.downcase.pluralize}/#{object_id}", params)
|
7
|
+
end
|
8
|
+
|
9
|
+
end
|
10
|
+
end
|
11
11
|
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
2
|
+
module APIOperations
|
3
|
+
module List
|
4
4
|
|
5
|
-
|
6
|
-
|
5
|
+
def list params = {}
|
6
|
+
response = Shipstation.request(:get, class_name.downcase.pluralize, params)
|
7
7
|
|
8
|
-
|
9
|
-
|
10
|
-
end
|
8
|
+
return response
|
9
|
+
end
|
11
10
|
end
|
11
|
+
end
|
12
12
|
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
2
|
+
module APIOperations
|
3
|
+
module Retrieve
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
end
|
5
|
+
def retrieve object_id, params = {}
|
6
|
+
response = Shipstation.request(:get, "#{class_name.downcase.pluralize}/#{object_id}", params)
|
7
|
+
return response
|
8
|
+
end
|
10
9
|
end
|
10
|
+
end
|
11
11
|
end
|
@@ -1,11 +1,11 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
2
|
+
module APIOperations
|
3
|
+
module Update
|
4
|
+
|
5
|
+
def update object_id, params = {}
|
6
|
+
Shipstation.request(:put, "#{class_name.downcase.pluralize}/#{object_id}", params)
|
7
|
+
end
|
8
|
+
|
9
|
+
end
|
10
|
+
end
|
11
11
|
end
|
data/lib/shipstation/carrier.rb
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
2
|
+
class Carrier < ApiResource
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
end
|
4
|
+
class << self
|
5
|
+
def list
|
6
|
+
response = Shipstation.request(:get, 'carriers')
|
7
|
+
return response
|
8
|
+
end
|
10
9
|
end
|
10
|
+
end
|
11
11
|
end
|
data/lib/shipstation/customer.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
class Customer < ApiResource
|
3
|
+
extend Shipstation::APIOperations::List
|
4
|
+
extend Shipstation::APIOperations::Retrieve
|
5
|
+
end
|
6
6
|
end
|
data/lib/shipstation/order.rb
CHANGED
@@ -1,28 +1,36 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
4
|
+
class Order < ApiResource
|
5
|
+
extend Shipstation::APIOperations::List
|
6
|
+
extend Shipstation::APIOperations::Create
|
7
|
+
extend Shipstation::APIOperations::Retrieve
|
8
|
+
extend Shipstation::APIOperations::Delete
|
9
|
+
|
10
|
+
class << self
|
11
|
+
def create_label(params = {})
|
12
|
+
response = Shipstation.request(:post, 'orders/createlabelfororder', params)
|
13
|
+
|
14
|
+
response
|
15
|
+
end
|
16
|
+
|
17
|
+
def assign_tag(params = {})
|
18
|
+
response = Shipstation.request(:post, 'orders/addtag', params)
|
19
|
+
|
20
|
+
response
|
21
|
+
end
|
22
|
+
|
23
|
+
def remove_tag(params = {})
|
24
|
+
response = Shipstation.request(:post, 'orders/removetag', params)
|
25
|
+
|
26
|
+
response
|
27
|
+
end
|
28
|
+
|
29
|
+
# params: { [:username], [:password], input: [ {:order_number, ... }, { :order_number, ... } ] }
|
30
|
+
# todo: complete in future phase
|
31
|
+
# def create_update_orders params
|
32
|
+
# Shipstation.request(:post, "orders/createorders", params)
|
33
|
+
# end
|
27
34
|
end
|
28
|
-
end
|
35
|
+
end
|
36
|
+
end
|
data/lib/shipstation/product.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
2
|
+
class Product < ApiResource
|
3
|
+
extend Shipstation::APIOperations::List
|
4
|
+
extend Shipstation::APIOperations::Retrieve
|
5
|
+
extend Shipstation::APIOperations::Update
|
6
|
+
end
|
7
7
|
end
|
data/lib/shipstation/shipment.rb
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
2
|
+
class Shipment < ApiResource
|
3
|
+
extend Shipstation::APIOperations::List
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
5
|
+
class << self
|
6
|
+
def get_rates params = {}
|
7
|
+
response = Shipstation.request(:post, "shipments/getrates", params)
|
8
8
|
|
9
|
-
|
10
|
-
|
11
|
-
end
|
9
|
+
return response
|
10
|
+
end
|
12
11
|
end
|
12
|
+
end
|
13
13
|
end
|
data/lib/shipstation/store.rb
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
2
|
+
class Store < ApiResource
|
3
|
+
extend Shipstation::APIOperations::Retrieve
|
4
|
+
extend Shipstation::APIOperations::Update
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
end
|
6
|
+
class << self
|
7
|
+
def list
|
8
|
+
response = Shipstation.request(:get, 'stores')
|
9
|
+
|
10
|
+
return response
|
11
|
+
end
|
13
12
|
end
|
13
|
+
end
|
14
14
|
end
|
data/lib/shipstation/tag.rb
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
2
|
+
class Tag < ApiResource
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
end
|
4
|
+
class << self
|
5
|
+
def list
|
6
|
+
response = Shipstation.request(:get, 'accounts/listtags')
|
7
|
+
|
8
|
+
return response
|
9
|
+
end
|
11
10
|
end
|
11
|
+
end
|
12
12
|
end
|
data/lib/shipstation/version.rb
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
module Shipstation
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
class Warehouse < ApiResource
|
3
|
+
extend Shipstation::APIOperations::Create
|
4
|
+
extend Shipstation::APIOperations::Retrieve
|
5
|
+
extend Shipstation::APIOperations::Update
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
7
|
+
class << self
|
8
|
+
def list
|
9
|
+
response = Shipstation.request(:get, 'warehouses')
|
10
10
|
|
11
|
-
|
12
|
-
|
13
|
-
end
|
11
|
+
return response
|
12
|
+
end
|
14
13
|
end
|
14
|
+
end
|
15
15
|
end
|
data/test/dummy/Gemfile
CHANGED
@@ -26,14 +26,13 @@ gem 'sdoc', '~> 0.4.0', group: :doc
|
|
26
26
|
gem 'ffi', '~> 1.9.24'
|
27
27
|
gem 'sprockets', '~> 3.7.2'
|
28
28
|
|
29
|
-
gem 'rest-client'
|
30
|
-
gem 'shipstation'
|
29
|
+
gem 'rest-client'
|
30
|
+
gem 'shipstation'
|
31
31
|
|
32
|
-
|
33
32
|
|
34
33
|
# Use ActiveModel has_secure_password
|
35
34
|
# gem 'bcrypt', '~> 3.1.7'
|
36
|
-
|
35
|
+
|
37
36
|
# Use Unicorn as the app server
|
38
37
|
# gem 'unicorn'
|
39
38
|
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<!DOCTYPE html>
|
2
2
|
<html>
|
3
3
|
<head>
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
<title>Dummy</title>
|
5
|
+
<%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true %>
|
6
|
+
<%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
|
7
|
+
<%= csrf_meta_tags %>
|
8
8
|
</head>
|
9
9
|
<body>
|
10
10
|
|
data/test/dummy/bin/setup
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
require 'pathname'
|
3
3
|
|
4
4
|
# path to your application root.
|
5
|
-
APP_ROOT = Pathname.new File.expand_path('../../',
|
5
|
+
APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
|
6
6
|
|
7
7
|
Dir.chdir APP_ROOT do
|
8
8
|
# This script is a starting point to setup your application.
|
data/test/dummy/bin/spring
CHANGED
@@ -8,7 +8,7 @@ unless defined?(Spring)
|
|
8
8
|
require 'bundler'
|
9
9
|
|
10
10
|
lockfile = Bundler::LockfileParser.new(Bundler.default_lockfile.read)
|
11
|
-
spring = lockfile.specs.detect {
|
11
|
+
spring = lockfile.specs.detect {|spec| spec.name == "spring"}
|
12
12
|
if spring
|
13
13
|
Gem.use_paths Gem.dir, Bundler.bundle_path.to_s, *Gem.path
|
14
14
|
gem 'spring', spring.version
|
@@ -10,7 +10,7 @@ Rails.application.configure do
|
|
10
10
|
config.eager_load = false
|
11
11
|
|
12
12
|
# Show full error reports and disable caching.
|
13
|
-
config.consider_all_requests_local
|
13
|
+
config.consider_all_requests_local = true
|
14
14
|
config.action_controller.perform_caching = false
|
15
15
|
|
16
16
|
# Don't care if the mailer can't send.
|
@@ -11,7 +11,7 @@ Rails.application.configure do
|
|
11
11
|
config.eager_load = true
|
12
12
|
|
13
13
|
# Full error reports are disabled and caching is turned on.
|
14
|
-
config.consider_all_requests_local
|
14
|
+
config.consider_all_requests_local = false
|
15
15
|
config.action_controller.perform_caching = true
|
16
16
|
|
17
17
|
# Enable Rack::Cache to put a simple HTTP cache in front of your application
|
@@ -13,11 +13,11 @@ Rails.application.configure do
|
|
13
13
|
config.eager_load = false
|
14
14
|
|
15
15
|
# Configure static file server for tests with Cache-Control for performance.
|
16
|
-
config.serve_static_files
|
16
|
+
config.serve_static_files = true
|
17
17
|
config.static_cache_control = 'public, max-age=3600'
|
18
18
|
|
19
19
|
# Show full error reports and disable caching.
|
20
|
-
config.consider_all_requests_local
|
20
|
+
config.consider_all_requests_local = true
|
21
21
|
config.action_controller.perform_caching = false
|
22
22
|
|
23
23
|
# Raise exceptions instead of rendering exception templates.
|
data/test/dummy/public/404.html
CHANGED
@@ -1,67 +1,67 @@
|
|
1
1
|
<!DOCTYPE html>
|
2
2
|
<html>
|
3
3
|
<head>
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
4
|
+
<title>The page you were looking for doesn't exist (404)</title>
|
5
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
6
|
+
<style>
|
7
|
+
body {
|
8
|
+
background-color: #EFEFEF;
|
9
|
+
color: #2E2F30;
|
10
|
+
text-align: center;
|
11
|
+
font-family: arial, sans-serif;
|
12
|
+
margin: 0;
|
13
|
+
}
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
15
|
+
div.dialog {
|
16
|
+
width: 95%;
|
17
|
+
max-width: 33em;
|
18
|
+
margin: 4em auto 0;
|
19
|
+
}
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
21
|
+
div.dialog > div {
|
22
|
+
border: 1px solid #CCC;
|
23
|
+
border-right-color: #999;
|
24
|
+
border-left-color: #999;
|
25
|
+
border-bottom-color: #BBB;
|
26
|
+
border-top: #B00100 solid 4px;
|
27
|
+
border-top-left-radius: 9px;
|
28
|
+
border-top-right-radius: 9px;
|
29
|
+
background-color: white;
|
30
|
+
padding: 7px 12% 0;
|
31
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
32
|
+
}
|
33
33
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
34
|
+
h1 {
|
35
|
+
font-size: 100%;
|
36
|
+
color: #730E15;
|
37
|
+
line-height: 1.5em;
|
38
|
+
}
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
40
|
+
div.dialog > p {
|
41
|
+
margin: 0 0 1em;
|
42
|
+
padding: 1em;
|
43
|
+
background-color: #F7F7F7;
|
44
|
+
border: 1px solid #CCC;
|
45
|
+
border-right-color: #999;
|
46
|
+
border-left-color: #999;
|
47
|
+
border-bottom-color: #999;
|
48
|
+
border-bottom-left-radius: 4px;
|
49
|
+
border-bottom-right-radius: 4px;
|
50
|
+
border-top-color: #DADADA;
|
51
|
+
color: #666;
|
52
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
53
|
+
}
|
54
|
+
</style>
|
55
55
|
</head>
|
56
56
|
|
57
57
|
<body>
|
58
|
-
|
59
|
-
|
58
|
+
<!-- This file lives in public/404.html -->
|
59
|
+
<div class="dialog">
|
60
60
|
<div>
|
61
|
-
|
62
|
-
|
61
|
+
<h1>The page you were looking for doesn't exist.</h1>
|
62
|
+
<p>You may have mistyped the address or the page may have moved.</p>
|
63
63
|
</div>
|
64
64
|
<p>If you are the application owner check the logs for more information.</p>
|
65
|
-
|
65
|
+
</div>
|
66
66
|
</body>
|
67
67
|
</html>
|
data/test/dummy/public/422.html
CHANGED
@@ -1,67 +1,67 @@
|
|
1
1
|
<!DOCTYPE html>
|
2
2
|
<html>
|
3
3
|
<head>
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
4
|
+
<title>The change you wanted was rejected (422)</title>
|
5
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
6
|
+
<style>
|
7
|
+
body {
|
8
|
+
background-color: #EFEFEF;
|
9
|
+
color: #2E2F30;
|
10
|
+
text-align: center;
|
11
|
+
font-family: arial, sans-serif;
|
12
|
+
margin: 0;
|
13
|
+
}
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
15
|
+
div.dialog {
|
16
|
+
width: 95%;
|
17
|
+
max-width: 33em;
|
18
|
+
margin: 4em auto 0;
|
19
|
+
}
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
21
|
+
div.dialog > div {
|
22
|
+
border: 1px solid #CCC;
|
23
|
+
border-right-color: #999;
|
24
|
+
border-left-color: #999;
|
25
|
+
border-bottom-color: #BBB;
|
26
|
+
border-top: #B00100 solid 4px;
|
27
|
+
border-top-left-radius: 9px;
|
28
|
+
border-top-right-radius: 9px;
|
29
|
+
background-color: white;
|
30
|
+
padding: 7px 12% 0;
|
31
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
32
|
+
}
|
33
33
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
34
|
+
h1 {
|
35
|
+
font-size: 100%;
|
36
|
+
color: #730E15;
|
37
|
+
line-height: 1.5em;
|
38
|
+
}
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
40
|
+
div.dialog > p {
|
41
|
+
margin: 0 0 1em;
|
42
|
+
padding: 1em;
|
43
|
+
background-color: #F7F7F7;
|
44
|
+
border: 1px solid #CCC;
|
45
|
+
border-right-color: #999;
|
46
|
+
border-left-color: #999;
|
47
|
+
border-bottom-color: #999;
|
48
|
+
border-bottom-left-radius: 4px;
|
49
|
+
border-bottom-right-radius: 4px;
|
50
|
+
border-top-color: #DADADA;
|
51
|
+
color: #666;
|
52
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
53
|
+
}
|
54
|
+
</style>
|
55
55
|
</head>
|
56
56
|
|
57
57
|
<body>
|
58
|
-
|
59
|
-
|
58
|
+
<!-- This file lives in public/422.html -->
|
59
|
+
<div class="dialog">
|
60
60
|
<div>
|
61
|
-
|
62
|
-
|
61
|
+
<h1>The change you wanted was rejected.</h1>
|
62
|
+
<p>Maybe you tried to change something you didn't have access to.</p>
|
63
63
|
</div>
|
64
64
|
<p>If you are the application owner check the logs for more information.</p>
|
65
|
-
|
65
|
+
</div>
|
66
66
|
</body>
|
67
67
|
</html>
|
data/test/dummy/public/500.html
CHANGED
@@ -1,66 +1,66 @@
|
|
1
1
|
<!DOCTYPE html>
|
2
2
|
<html>
|
3
3
|
<head>
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
4
|
+
<title>We're sorry, but something went wrong (500)</title>
|
5
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
6
|
+
<style>
|
7
|
+
body {
|
8
|
+
background-color: #EFEFEF;
|
9
|
+
color: #2E2F30;
|
10
|
+
text-align: center;
|
11
|
+
font-family: arial, sans-serif;
|
12
|
+
margin: 0;
|
13
|
+
}
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
15
|
+
div.dialog {
|
16
|
+
width: 95%;
|
17
|
+
max-width: 33em;
|
18
|
+
margin: 4em auto 0;
|
19
|
+
}
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
21
|
+
div.dialog > div {
|
22
|
+
border: 1px solid #CCC;
|
23
|
+
border-right-color: #999;
|
24
|
+
border-left-color: #999;
|
25
|
+
border-bottom-color: #BBB;
|
26
|
+
border-top: #B00100 solid 4px;
|
27
|
+
border-top-left-radius: 9px;
|
28
|
+
border-top-right-radius: 9px;
|
29
|
+
background-color: white;
|
30
|
+
padding: 7px 12% 0;
|
31
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
32
|
+
}
|
33
33
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
34
|
+
h1 {
|
35
|
+
font-size: 100%;
|
36
|
+
color: #730E15;
|
37
|
+
line-height: 1.5em;
|
38
|
+
}
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
40
|
+
div.dialog > p {
|
41
|
+
margin: 0 0 1em;
|
42
|
+
padding: 1em;
|
43
|
+
background-color: #F7F7F7;
|
44
|
+
border: 1px solid #CCC;
|
45
|
+
border-right-color: #999;
|
46
|
+
border-left-color: #999;
|
47
|
+
border-bottom-color: #999;
|
48
|
+
border-bottom-left-radius: 4px;
|
49
|
+
border-bottom-right-radius: 4px;
|
50
|
+
border-top-color: #DADADA;
|
51
|
+
color: #666;
|
52
|
+
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
|
53
|
+
}
|
54
|
+
</style>
|
55
55
|
</head>
|
56
56
|
|
57
57
|
<body>
|
58
|
-
|
59
|
-
|
58
|
+
<!-- This file lives in public/500.html -->
|
59
|
+
<div class="dialog">
|
60
60
|
<div>
|
61
|
-
|
61
|
+
<h1>We're sorry, but something went wrong.</h1>
|
62
62
|
</div>
|
63
63
|
<p>If you are the application owner check the logs for more information.</p>
|
64
|
-
|
64
|
+
</div>
|
65
65
|
</body>
|
66
66
|
</html>
|
data/test/test_helper.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# Configure Rails Environment
|
2
2
|
ENV["RAILS_ENV"] = "test"
|
3
3
|
|
4
|
-
require File.expand_path("../../test/dummy/config/environment.rb",
|
4
|
+
require File.expand_path("../../test/dummy/config/environment.rb", __FILE__)
|
5
5
|
ActiveRecord::Migrator.migrations_paths = [File.expand_path("../../test/dummy/db/migrate", __FILE__)]
|
6
6
|
require "rails/test_help"
|
7
7
|
|
@@ -10,7 +10,7 @@ require "rails/test_help"
|
|
10
10
|
Minitest.backtrace_filter = Minitest::BacktraceFilter.new
|
11
11
|
|
12
12
|
# Load support files
|
13
|
-
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {
|
13
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
|
14
14
|
|
15
15
|
# Load fixtures from the engine
|
16
16
|
if ActiveSupport::TestCase.respond_to?(:fixture_path=)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: shipstation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.15.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tom Dallimore
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-06-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rest-client
|