Made changes following the review from David Taylor

This commit is contained in:
Matthew Smith
2019-12-04 19:07:21 +00:00
parent d335ab3a80
commit bb44b0c88b
13 changed files with 177 additions and 340 deletions

View File

@@ -1,12 +1,8 @@
from django.urls import path, include
from rest_framework import routers
from assets import views, api
from assets import views
from PyRIGS.decorators import permission_required_with_403
router = routers.DefaultRouter()
router.register(r'api/assets', api.AssetViewSet)
urlpatterns = [
path('', views.AssetList.as_view(), name='asset_index'),
path('asset/list/', views.AssetList.as_view(), name='asset_list'),
@@ -23,6 +19,4 @@ urlpatterns = [
path('supplier/<int:pk>/edit', permission_required_with_403('assets.edit_supplier')(views.SupplierUpdate.as_view()), name='supplier_update'),
path('supplier/search/', views.SupplierSearch.as_view(), name='supplier_search_json'),
path('', include(router.urls)),
]