mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-08-13 03:46:43 +00:00
* perf: 添加应用树api * perf: perms tree * perf: 统一应用树 * perf: 修改icon * perf: stash it * perf: 优化应用账号 * perf: 基本完成应用账号重构 * perf: 修改翻译 Co-authored-by: ibuler <ibuler@qq.com>
43 lines
1.1 KiB
Python
43 lines
1.1 KiB
Python
from rest_framework.viewsets import GenericViewSet, ModelViewSet, ReadOnlyModelViewSet, ViewSet
|
|
from rest_framework_bulk import BulkModelViewSet
|
|
|
|
from ..mixins.api import (
|
|
SerializerMixin, QuerySetMixin, ExtraFilterFieldsMixin, PaginatedResponseMixin,
|
|
RelationMixin, AllowBulkDestroyMixin, RenderToJsonMixin,
|
|
)
|
|
|
|
|
|
class CommonMixin(SerializerMixin,
|
|
QuerySetMixin,
|
|
ExtraFilterFieldsMixin,
|
|
PaginatedResponseMixin,
|
|
RenderToJsonMixin):
|
|
pass
|
|
|
|
|
|
class JMSGenericViewSet(CommonMixin, GenericViewSet):
|
|
pass
|
|
|
|
|
|
class JMSViewSet(CommonMixin, ViewSet):
|
|
pass
|
|
|
|
|
|
class JMSModelViewSet(CommonMixin, ModelViewSet):
|
|
pass
|
|
|
|
|
|
class JMSReadOnlyModelViewSet(CommonMixin, ReadOnlyModelViewSet):
|
|
pass
|
|
|
|
|
|
class JMSBulkModelViewSet(CommonMixin, AllowBulkDestroyMixin, BulkModelViewSet):
|
|
pass
|
|
|
|
|
|
class JMSBulkRelationModelViewSet(CommonMixin,
|
|
RelationMixin,
|
|
AllowBulkDestroyMixin,
|
|
BulkModelViewSet):
|
|
pass
|