Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Reformat code

dominik-zeglenb2018db2c90d
diff --git a/saleor/dashboard/order/utils.py b/saleor/dashboard/order/utils.py
index 0837e11571..7913aa9311 100644
--- a/saleor/dashboard/order/utils.py
+++ b/saleor/dashboard/order/utils.py
@@ -29,7 +29,7 @@ def _create_pdf(rendered_template, absolute_url):
def create_invoice_pdf(order_pk, absolute_url):
order = (Order.objects.prefetch_related(
'user', 'shipping_address',
- 'billing_address', 'voucher').get(
+ 'billing_address', 'voucher', 'groups').get(
pk=order_pk))
shipping_methods = [
{'name': d.shipping_method_name,
diff --git a/saleor/order/models.py b/saleor/order/models.py
index ccad21ce31..63d2cbcaba 100644
--- a/saleor/order/models.py
+++ b/saleor/order/models.py
@@ -278,10 +278,6 @@ class DeliveryGroup(models.Model, ItemSet):
subtotal = super(DeliveryGroup, self).get_total(**kwargs)
return subtotal + self.shipping_price
- def get_subtotal_without_voucher(self, **kwargs):
- subtotal = super(DeliveryGroup, self).get_total(**kwargs)
- return subtotal
-
def get_total_quantity(self):
return sum([item.get_quantity() for item in self])