2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-08-17 17:11:09 +00:00

Added PartDetailFromIPN view (subclass of PartDetail) and url pattern

This commit is contained in:
eeintech
2020-09-04 17:20:17 -05:00
parent 11b751323e
commit 2fa284d37b
2 changed files with 38 additions and 1 deletions

View File

@@ -99,8 +99,10 @@ part_urls = [
# Export data for multiple parts
url(r'^export/', views.PartExport.as_view(), name='part-export'),
# Individual part
# Individual part using pk
url(r'^(?P<pk>\d+)/', include(part_detail_urls)),
# Individual part using IPN as slug
url(r'^(?P<slug>[-\w]+)/', views.PartDetailFromIPN.as_view(), name='part-detail-from-ipn'),
# Part category
url(r'^category/(?P<pk>\d+)/', include(part_category_urls)),