Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
class Shipments(ResourceObject):
can_update = True
read_only = ["id", "date_created", "customer_id", "shipping_method", "items"]
sub_resource = Mapping(billing_address = Mapping(single=True),
shipping_address = Mapping(single=True),
items = Mapping())
pass
class ConfigurableFields(ResourceObject):
pass
class SKU(ResourceObject):
sub_resources = Mapping(options = Mapping())
read_only = ["id","product_id"]
can_update = True
@classmethod
def filter_set(cls):
return FilterSet(min_id = NumberFilter( info="Minimum id of the product" ),
max_id = NumberFilter( info="Minimum id of the product" ),
sku = StringFilter(),
upc = StringFilter(),
min_inventory_level = NumberFilter(),
max_inventory_level = NumberFilter(),
inventory_warning_level = NumberFilter(),
bin_picking_number = NumberFilter(),
)
read_only = ["id","product_id"]
can_update = True
@classmethod
def filter_set(cls):
return FilterSet(min_id = NumberFilter( info="Minimum id of the product" ),
max_id = NumberFilter( info="Minimum id of the product" ),
sku = StringFilter(),
upc = StringFilter(),
min_inventory_level = NumberFilter(),
max_inventory_level = NumberFilter(),
inventory_warning_level = NumberFilter(),
bin_picking_number = NumberFilter(),
)
class ProductOptions(ResourceObject):
pass
class States(ResourceObject):
@classmethod
def filter_set(cls):
return FilterSet(state = StringFilter(),
state_abbreviations = StringFilter()
)
class Images(ResourceObject):
can_update = True
read_only = ["id","product_id","date_created"]
from bigcommerce.api.resource import ResourceObject
class Brands(ResourceObject):
"""
"""
can_update = True
read_only = ["id"]
def __repr__(self):
return "%s- %s" % (self.id, self.name)
from bigcommerce.api.resource import ResourceObject
from bigcommerce.api.mapping import Mapping
from bigcommerce.api.filters import FilterSet, StringFilter, NumberFilter, DateFilter, BoolFilter
class ShippingAddresses(ResourceObject):
pass
class Coupons(ResourceObject):
pass
class OrderProducts(ResourceObject):
sub_resources = Mapping(
applied_discounts = Mapping(),
product_options = Mapping(),
configurable_fields = Mapping())
from bigcommerce.api.resource import ResourceObject
# TODO: why is this in its own module rather than being in subresources?
class OptionSetOptions(ResourceObject):
can_update = True
read_only = ["id"]
def __repr__(self):
return "%s- %s" % (self.id, self.display_name)
class Coupons(ResourceObject):
pass
class OrderProducts(ResourceObject):
sub_resources = Mapping(
applied_discounts = Mapping(),
product_options = Mapping(),
configurable_fields = Mapping())
class Shipments(ResourceObject):
can_update = True
read_only = ["id", "date_created", "customer_id", "shipping_method", "items"]
sub_resource = Mapping(billing_address = Mapping(single=True),
shipping_address = Mapping(single=True),
items = Mapping())
pass
class ConfigurableFields(ResourceObject):
pass
class SKU(ResourceObject):
sub_resources = Mapping(options = Mapping())
read_only = ["id","product_id"]
from bigcommerce.api.resource import ResourceObject
class OptionValues(ResourceObject):
"""
"""
can_update = True
read_only = ["id", "option_id"]
def __repr__(self):
return "%s- %s -> %s" % (self.id, self.label, self.value)
from bigcommerce.api.resource import ResourceObject
from bigcommerce.api.mapping import Mapping
from bigcommerce.api.filters import FilterSet, StringFilter, NumberFilter, DateFilter, BoolFilter
class ShippingAddresses(ResourceObject):
pass
class Coupons(ResourceObject):
pass
class OrderProducts(ResourceObject):
sub_resources = Mapping(
applied_discounts = Mapping(),
product_options = Mapping(),
configurable_fields = Mapping())
class Shipments(ResourceObject):
can_update = True
read_only = ["id", "date_created", "customer_id", "shipping_method", "items"]
sub_resource = Mapping(billing_address = Mapping(single=True),
from bigcommerce.api.resource import ResourceObject
from bigcommerce.api.mapping import Mapping
from bigcommerce.api.filters import FilterSet, StringFilter, NumberFilter, DateFilter, BoolFilter
class ShippingAddresses(ResourceObject):
pass
class Coupons(ResourceObject):
pass
class OrderProducts(ResourceObject):
sub_resources = Mapping(
applied_discounts = Mapping(),
product_options = Mapping(),
configurable_fields = Mapping())
class Shipments(ResourceObject):
can_update = True
read_only = ["id", "date_created", "customer_id", "shipping_method", "items"]
sub_resource = Mapping(billing_address = Mapping(single=True),
shipping_address = Mapping(single=True),
items = Mapping())
pass
product_options = Mapping(),
configurable_fields = Mapping())
class Shipments(ResourceObject):
can_update = True
read_only = ["id", "date_created", "customer_id", "shipping_method", "items"]
sub_resource = Mapping(billing_address = Mapping(single=True),
shipping_address = Mapping(single=True),
items = Mapping())
pass
class ConfigurableFields(ResourceObject):
pass
class SKU(ResourceObject):
sub_resources = Mapping(options = Mapping())
read_only = ["id","product_id"]
can_update = True
@classmethod
def filter_set(cls):
return FilterSet(min_id = NumberFilter( info="Minimum id of the product" ),
max_id = NumberFilter( info="Minimum id of the product" ),
sku = StringFilter(),
upc = StringFilter(),
min_inventory_level = NumberFilter(),