From 19444b3b1c3d80b860d9d749942b7d2558950bcb Mon Sep 17 00:00:00 2001 From: Filipp Lepalaan Date: Wed, 11 Nov 2015 15:43:55 +0200 Subject: Refactored searches into separate module --- servo/urls/products.py | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) (limited to 'servo/urls/products.py') diff --git a/servo/urls/products.py b/servo/urls/products.py index 9de2575..9c60baa 100644 --- a/servo/urls/products.py +++ b/servo/urls/products.py @@ -12,20 +12,18 @@ urlpatterns = patterns( url(r'^upload/parts/$', "upload_gsx_parts", name="products-upload_gsx_parts"), url(r'^update_price/(\d+)/$', "update_price", name="products-update_price"), - url(r'^all/(?P\d+)/$', "view_product", {'group': 'all'}, name="products-view_product"), + url(r'^all/(?P\d+)/$', "view_product", {'group': 'all'}, + name="products-view_product"), url(r'^(?P[\w\-/]*)/(?P\d+)/view/$', "view_product", name="products-view_product"), # Editing product categories url(r'^categories/create/$', "edit_category", name="products-create_category"), - url(r'^categories/(?P[\w\-]+)/edit/$', - "edit_category", + url(r'^categories/(?P[\w\-]+)/edit/$', "edit_category", name="products-edit_category"), - url(r'^categories/(?P[\w\-]+)/delete/$', - "delete_category", + url(r'^categories/(?P[\w\-]+)/delete/$', "delete_category", name="products-delete_category"), - url(r'^categories/(?P[\w\-]+)/create/$', - "edit_category", + url(r'^categories/(?P[\w\-]+)/create/$', "edit_category", name="products-create_category"), # Editing products @@ -37,15 +35,14 @@ urlpatterns = patterns( name="products-delete_product"), # Choosing a product for an order - url(r'^choose/order/(?P\d+)/$', "choose_product", name="products-choose"), + url(r'^choose/order/(?P\d+)/$', "choose_product", + name="products-choose"), url(r'^(?P[\w\-]+)/(?P[\w\-/]+)/create/$', "edit_product", name="products-create"), - url(r'^all/(?P[\w\-/]+)/view/$', - "view_product", {'group': 'all'}, + url(r'^all/(?P[\w\-/]+)/view/$', "view_product", {'group': 'all'}, name="products-view_product"), - url(r'^(?P[\w\-/]+)/new/$', - "edit_product", {'group': None}, + url(r'^(?P[\w\-/]+)/new/$', "edit_product", {'group': None}, name="products-create"), url(r'^code/(?P[\w\-/]+)/location/(?P\d+)/get_info/$', -- cgit v1.2.3