17 lines
546 B
Python
17 lines
546 B
Python
|
from django.conf.urls import include, url
|
||
|
from rest_framework import routers
|
||
|
|
||
|
from .views import TagViewSet, ProductViewSet, ReceiptViewSet, ProductOnBillViewSet, ShopTagViewSet, ShopViewSet
|
||
|
|
||
|
router = routers.DefaultRouter()
|
||
|
router.register('tags', TagViewSet)
|
||
|
router.register('shop_tags', ShopTagViewSet)
|
||
|
router.register('shops', ShopViewSet)
|
||
|
router.register('products', ProductViewSet)
|
||
|
router.register('products_on_bills', ProductOnBillViewSet)
|
||
|
router.register('receipts', ReceiptViewSet)
|
||
|
|
||
|
urlpatterns = [
|
||
|
url("^", include(router.urls)),
|
||
|
]
|