moduel setgins fixed
This commit is contained in:
@@ -289,17 +289,16 @@ class ModuleSettingsViewSet(AccountModelViewSet):
|
||||
@extend_schema_view(
|
||||
list=extend_schema(tags=['System']),
|
||||
retrieve=extend_schema(tags=['System']),
|
||||
update=extend_schema(tags=['System']),
|
||||
partial_update=extend_schema(tags=['System']),
|
||||
)
|
||||
class ModuleEnableSettingsViewSet(viewsets.ViewSet):
|
||||
"""
|
||||
ViewSet for GLOBAL module enable/disable settings (read-only).
|
||||
ViewSet for GLOBAL module enable/disable settings (read-only, public).
|
||||
Returns platform-wide module availability from GlobalModuleSettings singleton.
|
||||
No authentication required - these are public platform-wide settings.
|
||||
Only superadmin can modify via Django Admin at /admin/system/globalmodulesettings/.
|
||||
"""
|
||||
authentication_classes = [JWTAuthentication]
|
||||
permission_classes = [IsAuthenticatedAndActive, HasTenantAccess]
|
||||
authentication_classes = []
|
||||
permission_classes = []
|
||||
throttle_scope = 'system'
|
||||
throttle_classes = [DebugScopedRateThrottle]
|
||||
|
||||
|
||||
@@ -52,11 +52,9 @@ integration_image_gen_settings_viewset = IntegrationSettingsViewSet.as_view({
|
||||
|
||||
# Custom view for module enable settings to avoid URL routing conflict with ModuleSettingsViewSet
|
||||
# This must be defined as a custom path BEFORE router.urls to ensure it matches first
|
||||
# The update method handles pk=None correctly, so we can use as_view
|
||||
# Read-only viewset - only GET is supported (modification via Django Admin only)
|
||||
module_enable_viewset = ModuleEnableSettingsViewSet.as_view({
|
||||
'get': 'list',
|
||||
'put': 'update',
|
||||
'patch': 'partial_update',
|
||||
})
|
||||
|
||||
urlpatterns = [
|
||||
|
||||
Reference in New Issue
Block a user