plenty_client 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -1
- data/README.md +9 -36
- data/Rakefile +3 -3
- data/lib/plenty_client.rb +8 -5
- data/lib/plenty_client/accounting.rb +2 -2
- data/lib/plenty_client/authentication.rb +2 -2
- data/lib/plenty_client/authorization.rb +2 -2
- data/lib/plenty_client/basket.rb +2 -2
- data/lib/plenty_client/basket/item.rb +2 -2
- data/lib/plenty_client/category.rb +6 -7
- data/lib/plenty_client/category/branch.rb +2 -2
- data/lib/plenty_client/category/template.rb +3 -3
- data/lib/plenty_client/comment.rb +3 -3
- data/lib/plenty_client/config.rb +3 -1
- data/lib/plenty_client/endpoint.rb +74 -68
- data/lib/plenty_client/item.rb +7 -2
- data/lib/plenty_client/item/attribute.rb +3 -3
- data/lib/plenty_client/item/attribute/name.rb +12 -20
- data/lib/plenty_client/item/attribute/value.rb +13 -18
- data/lib/plenty_client/item/attribute/value_name.rb +12 -12
- data/lib/plenty_client/item/barcode.rb +3 -3
- data/lib/plenty_client/item/cross_selling.rb +3 -3
- data/lib/plenty_client/item/image.rb +6 -6
- data/lib/plenty_client/item/image/availability.rb +10 -10
- data/lib/plenty_client/item/image/name.rb +14 -24
- data/lib/plenty_client/item/manufacturer.rb +4 -4
- data/lib/plenty_client/item/manufacturer/commission.rb +3 -3
- data/lib/plenty_client/item/property.rb +3 -3
- data/lib/plenty_client/item/property/market_reference.rb +11 -11
- data/lib/plenty_client/item/property/name.rb +12 -17
- data/lib/plenty_client/item/property_group.rb +3 -3
- data/lib/plenty_client/item/property_group_name.rb +8 -10
- data/lib/plenty_client/item/sales_price.rb +3 -4
- data/lib/plenty_client/item/shipping_profile.rb +6 -6
- data/lib/plenty_client/item/unit.rb +3 -4
- data/lib/plenty_client/item/unit_name.rb +12 -11
- data/lib/plenty_client/item/variation.rb +10 -4
- data/lib/plenty_client/item/variation/barcode.rb +3 -3
- data/lib/plenty_client/item/variation/bundle.rb +14 -16
- data/lib/plenty_client/item/variation/category.rb +8 -10
- data/lib/plenty_client/item/variation/client.rb +3 -3
- data/lib/plenty_client/item/variation/default_category.rb +3 -3
- data/lib/plenty_client/item/variation/description.rb +3 -3
- data/lib/plenty_client/item/variation/image.rb +5 -4
- data/lib/plenty_client/item/variation/market.rb +3 -3
- data/lib/plenty_client/item/variation/market_ident_number.rb +3 -3
- data/lib/plenty_client/item/variation/sales_price.rb +13 -17
- data/lib/plenty_client/item/variation/sku.rb +12 -15
- data/lib/plenty_client/item/variation/stock.rb +3 -3
- data/lib/plenty_client/item/variation/supplier.rb +12 -15
- data/lib/plenty_client/item/variation/warehouse.rb +6 -5
- data/lib/plenty_client/item/variation_property.rb +3 -3
- data/lib/plenty_client/item/variation_property_value.rb +10 -14
- data/lib/plenty_client/item_set.rb +4 -4
- data/lib/plenty_client/item_set/component.rb +15 -22
- data/lib/plenty_client/item_set/config.rb +3 -2
- data/lib/plenty_client/order.rb +5 -4
- data/lib/plenty_client/order/contact_wish.rb +2 -3
- data/lib/plenty_client/order/coupon_code.rb +5 -7
- data/lib/plenty_client/order/coupon_code/contact.rb +4 -6
- data/lib/plenty_client/order/coupon_code/validation.rb +4 -6
- data/lib/plenty_client/order/currency.rb +2 -3
- data/lib/plenty_client/order/date.rb +3 -4
- data/lib/plenty_client/order/item.rb +3 -3
- data/lib/plenty_client/order/item/date.rb +2 -2
- data/lib/plenty_client/order/item/property.rb +2 -2
- data/lib/plenty_client/order/item/serial_number.rb +3 -3
- data/lib/plenty_client/order/property.rb +2 -3
- data/lib/plenty_client/order/referrer.rb +2 -3
- data/lib/plenty_client/order/shipping.rb +2 -3
- data/lib/plenty_client/order/shipping/country.rb +2 -2
- data/lib/plenty_client/order/shipping/information.rb +3 -3
- data/lib/plenty_client/order/shipping/package.rb +4 -4
- data/lib/plenty_client/order/shipping/profile.rb +2 -2
- data/lib/plenty_client/order/shipping/service_provider.rb +2 -2
- data/lib/plenty_client/request.rb +121 -98
- data/lib/plenty_client/sales_price/account.rb +2 -3
- data/lib/plenty_client/sales_price/country.rb +2 -2
- data/lib/plenty_client/sales_price/currency.rb +2 -2
- data/lib/plenty_client/sales_price/customer_class.rb +2 -2
- data/lib/plenty_client/sales_price/name.rb +4 -4
- data/lib/plenty_client/sales_price/online_store.rb +2 -3
- data/lib/plenty_client/sales_price/referrer.rb +3 -2
- data/lib/plenty_client/version.rb +1 -1
- metadata +2 -2
@@ -1,9 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class Account
|
4
|
-
|
5
|
-
|
6
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
7
6
|
|
8
7
|
LIST_REFERRER_ACCOUNTS = '/items/sales_prices/{salesPriceId}/accounts'.freeze
|
9
8
|
ACTIVATE_REFERRER_ACCOUNT = '/items/sales_prices/{salesPriceId}/accounts'.freeze
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class Country
|
4
|
-
|
5
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
6
|
|
7
7
|
LIST_SALES_PRICE_COUNTRIES = '/items/sales_prices/{salesPriceId}/countries'.freeze
|
8
8
|
ACTIVATE_SALES_PRICE_COUNTRY = '/items/sales_prices/{salesPriceId}/countries'.freeze
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class Currency
|
4
|
-
|
5
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
6
|
|
7
7
|
LIST_SALES_PRICE_CURRENCIES = '/items/sales_prices/{salesPriceId}/currencies'.freeze
|
8
8
|
ACTIVATE_SALES_PRICE_CURRENCY = '/items/sales_prices/{salesPriceId}/currencies'.freeze
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class CustomerClass
|
4
|
-
|
5
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
6
|
|
7
7
|
SALES_PRICE_PATH = '/items/sales_prices/{salesPriceId}'.freeze
|
8
8
|
LIST_SALES_PRICE_CUSTOMER_CLASSES = '/customer_classes'.freeze
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class Name
|
4
|
-
|
5
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
6
|
|
7
7
|
LIST_SALES_PRICE_NAMES = '/items/sales_prices/{salesPriceId}/names'.freeze
|
8
8
|
GET_SALES_PRICE_NAMES_BY_LANG = '/items/sales_prices/{salesPriceId}/names/{lang}'.freeze
|
@@ -22,12 +22,12 @@ module PlentyClient
|
|
22
22
|
def create(sales_price_id, headers = {})
|
23
23
|
post(build_endpoint(CREATE_SALES_PRICE_NAME, sales_price: sales_price_id), headers)
|
24
24
|
end
|
25
|
-
|
25
|
+
|
26
26
|
def update(sales_price_id, lang, headers = {})
|
27
27
|
post(build_endpoint(UPDATE_SALES_PRICE_NAME, sales_price: sales_price_id, lang: lang), headers)
|
28
28
|
end
|
29
29
|
|
30
|
-
def
|
30
|
+
def destroy(sales_price_id, lang)
|
31
31
|
delete(build_endpoint(DELETE_SALES_PRICE_NAME, sales_price: sales_price_id, lang: lang))
|
32
32
|
end
|
33
33
|
end
|
@@ -1,8 +1,8 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class OnlineStore
|
4
|
-
|
5
|
-
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
6
|
|
7
7
|
LIST_SALES_PRICE_ONLINE_STORES = '/items/sales_prices/{salesPriceId}/online_stores'.freeze
|
8
8
|
ACTIVATE_SALES_PRICE_ONLINE_STORE = '/items/sales_prices/{salesPriceId}/online_stores'.freeze
|
@@ -26,4 +26,3 @@ module PlentyClient
|
|
26
26
|
end
|
27
27
|
end
|
28
28
|
end
|
29
|
-
|
@@ -1,7 +1,9 @@
|
|
1
1
|
module PlentyClient
|
2
2
|
module SalesPrice
|
3
3
|
class Referrer
|
4
|
-
include Endpoint
|
4
|
+
include PlentyClient::Endpoint
|
5
|
+
include PlentyClient::Request
|
6
|
+
|
5
7
|
LIST_SALES_PRICE_REFERRER = '/items/sales_prices/{salesPriceId}/referrers'.freeze
|
6
8
|
ACTIVATE_SALES_PRICE_REFERRER = '/items/sales_prices/{salesPriceId}/referrers'.freeze
|
7
9
|
DEACTIVATE_SALES_PRICE_REFERRER = '/items/sales_prices/{salesPriceId}/referrers/{referrerId}'.freeze
|
@@ -22,4 +24,3 @@ module PlentyClient
|
|
22
24
|
end
|
23
25
|
end
|
24
26
|
end
|
25
|
-
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plenty_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dariusch Ochlast
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-07-
|
11
|
+
date: 2017-07-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|