You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
779 B
21 lines
779 B
from django.conf.urls import include, url
|
|
from rest_framework import routers
|
|
|
|
from .views import BuyableTypeViewSet, BuyableViewSet, OrderViewSet
|
|
from .views import TransactionTypeViewSet, TransactionViewSet, VirtualTransactionViewSet
|
|
|
|
router = routers.DefaultRouter()
|
|
router.register('buyabletypes', BuyableTypeViewSet)
|
|
router.register('buyables', BuyableViewSet)
|
|
router.register('orders', OrderViewSet, basename='order')
|
|
|
|
router.register('transactiontypes', TransactionTypeViewSet)
|
|
router.register('transactions', TransactionViewSet, 'transaction')
|
|
router.register('virtualtransactions', VirtualTransactionViewSet, 'virtualtransaction')
|
|
|
|
|
|
urlpatterns = [
|
|
url(r'^', include(router.urls)),
|
|
url(r'^api-auth/', include('rest_framework.urls', namespace='rest_framework'))
|
|
]
|