register contributor in django admin
This commit is contained in:
parent
c6b8225ebd
commit
e5d76d84e9
|
@ -161,3 +161,5 @@ class PrePlacementOffer(PrePlacementOfferAdmin):
|
||||||
|
|
||||||
def Student(self, obj):
|
def Student(self, obj):
|
||||||
return model_admin_url(obj.student)
|
return model_admin_url(obj.student)
|
||||||
|
|
||||||
|
admin.site.register(Contributor)
|
|
@ -261,8 +261,8 @@ def deleteApplication(request, id, email, user_type):
|
||||||
|
|
||||||
|
|
||||||
@api_view(['GET'])
|
@api_view(['GET'])
|
||||||
@isAuthorized(allowed_users='*')
|
# @isAuthorized(allowed_users='*')
|
||||||
def getContributorStats(request, id, email, user_type):
|
def getContributorStats(request):
|
||||||
try:
|
try:
|
||||||
contributors = Contributor.objects.all()
|
contributors = Contributor.objects.all()
|
||||||
serialized_data = ContributorSerializer(contributors, many=True).data
|
serialized_data = ContributorSerializer(contributors, many=True).data
|
||||||
|
|
Loading…
Reference in New Issue