Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Use get_subclass method from InheritanceManager
Marcin Gębalae4a02dfd9cae
diff --git a/saleor/dashboard/order/forms.py b/saleor/dashboard/order/forms.pyindex 6a1bf7f0ee..40e2850950 100644--- a/saleor/dashboard/order/forms.py+++ b/saleor/dashboard/order/forms.py@@ -85,7 +85,7 @@ class ChangeQuantityForm(forms.ModelForm):self.fields['quantity'].initial = self.instance.quantitydef get_variant(self):- p = Product.objects.select_subclasses().get(pk=self.instance.product.pk)+ p = Product.objects.get_subclass(pk=self.instance.product.pk)return p.variants.get(sku=self.instance.product_sku)def clean_quantity(self):