We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Admin: Product delete returns 404


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `shuup/admin/modules/products/views/delete.py`
Content:
```
1 # -*- coding: utf-8 -*-
2 # This file is part of Shuup.
3 #
4 # Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.
5 #
6 # This source code is licensed under the OSL-3.0 license found in the
7 # LICENSE file in the root directory of this source tree.
8 
9 from __future__ import unicode_literals
10 
11 from django.contrib import messages
12 from django.core.urlresolvers import reverse
13 from django.http.response import HttpResponseRedirect
14 from django.utils.translation import ugettext as _
15 from django.views.generic import DetailView
16 
17 from shuup.admin.utils.urls import get_model_url
18 from shuup.core.models import Product
19 
20 
21 class ProductDeleteView(DetailView):
22     model = Product
23     context_object_name = "product"
24 
25     def get(self, request, *args, **kwargs):
26         return HttpResponseRedirect(get_model_url(self.get_object(), shop=self.request.shop))
27 
28     def post(self, request, *args, **kwargs):
29         product = self.get_object()
30         product.soft_delete(user=request.user)
31         messages.success(request, _(u"%s has been marked deleted.") % product)
32         return HttpResponseRedirect(reverse("shuup_admin:shop_product.list"))
33
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/shuup/admin/modules/products/views/delete.py b/shuup/admin/modules/products/views/delete.py
--- a/shuup/admin/modules/products/views/delete.py
+++ b/shuup/admin/modules/products/views/delete.py
@@ -15,18 +15,19 @@
 from django.views.generic import DetailView
 
 from shuup.admin.utils.urls import get_model_url
-from shuup.core.models import Product
+from shuup.core.models import ShopProduct
 
 
 class ProductDeleteView(DetailView):
-    model = Product
+    model = ShopProduct
     context_object_name = "product"
 
     def get(self, request, *args, **kwargs):
-        return HttpResponseRedirect(get_model_url(self.get_object(), shop=self.request.shop))
+        product = self.get_object().product
+        return HttpResponseRedirect(get_model_url(product, shop=self.request.shop))
 
     def post(self, request, *args, **kwargs):
-        product = self.get_object()
+        product = self.get_object().product
         product.soft_delete(user=request.user)
         messages.success(request, _(u"%s has been marked deleted.") % product)
         return HttpResponseRedirect(reverse("shuup_admin:shop_product.list"))

{"golden_diff": "diff --git a/shuup/admin/modules/products/views/delete.py b/shuup/admin/modules/products/views/delete.py\n--- a/shuup/admin/modules/products/views/delete.py\n+++ b/shuup/admin/modules/products/views/delete.py\n@@ -15,18 +15,19 @@\n from django.views.generic import DetailView\n \n from shuup.admin.utils.urls import get_model_url\n-from shuup.core.models import Product\n+from shuup.core.models import ShopProduct\n \n \n class ProductDeleteView(DetailView):\n-    model = Product\n+    model = ShopProduct\n     context_object_name = \"product\"\n \n     def get(self, request, *args, **kwargs):\n-        return HttpResponseRedirect(get_model_url(self.get_object(), shop=self.request.shop))\n+        product = self.get_object().product\n+        return HttpResponseRedirect(get_model_url(product, shop=self.request.shop))\n \n     def post(self, request, *args, **kwargs):\n-        product = self.get_object()\n+        product = self.get_object().product\n         product.soft_delete(user=request.user)\n         messages.success(request, _(u\"%s has been marked deleted.\") % product)\n         return HttpResponseRedirect(reverse(\"shuup_admin:shop_product.list\"))\n", "issue": "Admin: Product delete returns 404\n\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\n# This file is part of Shuup.\n#\n# Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.\n#\n# This source code is licensed under the OSL-3.0 license found in the\n# LICENSE file in the root directory of this source tree.\n\nfrom __future__ import unicode_literals\n\nfrom django.contrib import messages\nfrom django.core.urlresolvers import reverse\nfrom django.http.response import HttpResponseRedirect\nfrom django.utils.translation import ugettext as _\nfrom django.views.generic import DetailView\n\nfrom shuup.admin.utils.urls import get_model_url\nfrom shuup.core.models import Product\n\n\nclass ProductDeleteView(DetailView):\n    model = Product\n    context_object_name = \"product\"\n\n    def get(self, request, *args, **kwargs):\n        return HttpResponseRedirect(get_model_url(self.get_object(), shop=self.request.shop))\n\n    def post(self, request, *args, **kwargs):\n        product = self.get_object()\n        product.soft_delete(user=request.user)\n        messages.success(request, _(u\"%s has been marked deleted.\") % product)\n        return HttpResponseRedirect(reverse(\"shuup_admin:shop_product.list\"))\n", "path": "shuup/admin/modules/products/views/delete.py"}], "after_files": [{"content": "# -*- coding: utf-8 -*-\n# This file is part of Shuup.\n#\n# Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.\n#\n# This source code is licensed under the OSL-3.0 license found in the\n# LICENSE file in the root directory of this source tree.\n\nfrom __future__ import unicode_literals\n\nfrom django.contrib import messages\nfrom django.core.urlresolvers import reverse\nfrom django.http.response import HttpResponseRedirect\nfrom django.utils.translation import ugettext as _\nfrom django.views.generic import DetailView\n\nfrom shuup.admin.utils.urls import get_model_url\nfrom shuup.core.models import ShopProduct\n\n\nclass ProductDeleteView(DetailView):\n    model = ShopProduct\n    context_object_name = \"product\"\n\n    def get(self, request, *args, **kwargs):\n        product = self.get_object().product\n        return HttpResponseRedirect(get_model_url(product, shop=self.request.shop))\n\n    def post(self, request, *args, **kwargs):\n        product = self.get_object().product\n        product.soft_delete(user=request.user)\n        messages.success(request, _(u\"%s has been marked deleted.\") % product)\n        return HttpResponseRedirect(reverse(\"shuup_admin:shop_product.list\"))\n", "path": "shuup/admin/modules/products/views/delete.py"}]}