Created
March 5, 2020 08:46
-
-
Save chrysmur/bd3aa97c905dafafa92dc7a6f4d4579f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.contrib import admin | |
from django.urls import path, include | |
from rest_framework import routers | |
from employee_app import views | |
router = routers.DefaultRouter() | |
router.register('employees', views.EmployeeAPI) | |
router.register('departments', views.DepartmentsAPI) | |
router.register('deptemp', views.DeptEmpAPI) | |
router.register('deptmanager', views.DeptManagerAPI) | |
router.register('salaries', views.SalariesAPI) | |
router.register('titles', views.TitlesAPI) | |
urlpatterns = [ | |
path('admin/', admin.site.urls), | |
path('api/', include(router.urls)) | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment