import odin

from oscar.core.loading import get_class

BaseShippingAddressResource = get_class(
    "oscar_odin.resources.address", "ShippingAddressResource"
)
BaseBillingAddressResource = get_class(
    "oscar_odin.resources.address", "BillingAddressResource"
)


class ShippingAddressResource(BaseShippingAddressResource):
    house_number: str = odin.Options(empty=True)


class BillingAddressResource(BaseBillingAddressResource):
    email: str = odin.Options(empty=True)
    house_number: str = odin.Options(empty=True)
