mirror of https://github.com/jumpserver/jumpserver
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
447 B
21 lines
447 B
4 years ago
|
# coding: utf-8
|
||
|
#
|
||
|
|
||
|
from orgs.mixins.api import OrgBulkModelViewSet
|
||
|
|
||
|
from .. import models
|
||
|
from .. import serializers
|
||
|
from ..hands import IsOrgAdminOrAppUser
|
||
|
|
||
|
__all__ = [
|
||
|
'ApplicationViewSet',
|
||
|
]
|
||
|
|
||
|
|
||
|
class ApplicationViewSet(OrgBulkModelViewSet):
|
||
|
model = models.Application
|
||
|
filter_fields = ('name',)
|
||
|
search_fields = filter_fields
|
||
|
permission_classes = (IsOrgAdminOrAppUser,)
|
||
|
serializer_class = serializers.ApplicationSerializer
|