2019-11-08 07:48:01 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
#
|
|
|
|
|
|
|
|
from rest_framework.permissions import BasePermission
|
|
|
|
|
|
|
|
|
2020-07-06 03:14:20 +00:00
|
|
|
class IsAssignee(BasePermission):
|
|
|
|
def has_object_permission(self, request, view, obj):
|
|
|
|
return obj.is_assignee(request.user)
|