perf: Optimize file audit download prompt

pull/14259/head
feng 2 months ago committed by feng626
parent b882b12d04
commit 3881edd2ba

@ -112,7 +112,7 @@ class BaseType(TextChoices):
@classmethod @classmethod
def get_choices(cls): def get_choices(cls):
if not settings.XPACK_ENABLED: if not settings.XPACK_LICENSE_IS_VALID:
choices = [(tp.value, tp.label) for tp in cls.get_community_types()] choices = [(tp.value, tp.label) for tp in cls.get_community_types()]
else: else:
choices = cls.choices choices = cls.choices

@ -443,7 +443,9 @@
"Docs": "Docs", "Docs": "Docs",
"Download": "Download", "Download": "Download",
"DownloadCenter": "Download", "DownloadCenter": "Download",
"DownloadFTPFileTip": "The current action does not record files, or the file size exceeds the threshold (default 100m), or it has not yet been saved to the corresponding storage", "FTPStorageNotEnabled": "The file storage function is not enabled. Please modify the configuration file and add the following configuration: FTP_FILE_MAX_STORE=100 (supports saving files within 100M)",
"FTPFileNotStored": "The file has not been saved to storage yet, please check back later.",
"FTPUnknownStorageState": "Unknown file storage status, please contact your administrator.",
"DownloadImportTemplateMsg": "Download creation template", "DownloadImportTemplateMsg": "Download creation template",
"DownloadReplay": "Download recording", "DownloadReplay": "Download recording",
"DownloadUpdateTemplateMsg": "Download update template", "DownloadUpdateTemplateMsg": "Download update template",

@ -458,7 +458,6 @@
"Docs": "文書", "Docs": "文書",
"Download": "ダウンロード", "Download": "ダウンロード",
"DownloadCenter": "ダウンロードセンター", "DownloadCenter": "ダウンロードセンター",
"DownloadFTPFileTip": "現在のActionでは、ファイルは記録されず、またはファイルサイズが閾値デフォルトは100Mを超える、またはまだ対応するストレージに保存されていない",
"DownloadImportTemplateMsg": "テンプレートをダウンロードで作成", "DownloadImportTemplateMsg": "テンプレートをダウンロードで作成",
"DownloadReplay": "ビデオのダウンロード", "DownloadReplay": "ビデオのダウンロード",
"DownloadUpdateTemplateMsg": "更新テンプレートをダウンロード", "DownloadUpdateTemplateMsg": "更新テンプレートをダウンロード",

@ -444,6 +444,9 @@
"Download": "下载", "Download": "下载",
"DownloadCenter": "下载中心", "DownloadCenter": "下载中心",
"DownloadFTPFileTip": "当前动作不记录文件或者文件大小超过阈值默认100M或者还未保存到对应存储中", "DownloadFTPFileTip": "当前动作不记录文件或者文件大小超过阈值默认100M或者还未保存到对应存储中",
"FTPStorageNotEnabled": "文件存储功能未开启请修改配置文件并添加配置FTP_FILE_MAX_STORE=100支持保存100M以内的文件",
"FTPFileNotStored": "文件尚未保存到存储中,请稍后查看。",
"FTPUnknownStorageState": "未知的文件存储状态,请联系管理员。",
"DownloadImportTemplateMsg": "下载创建模板", "DownloadImportTemplateMsg": "下载创建模板",
"DownloadReplay": "下载录像", "DownloadReplay": "下载录像",
"DownloadUpdateTemplateMsg": "下载更新模板", "DownloadUpdateTemplateMsg": "下载更新模板",

@ -593,7 +593,6 @@
"DomainUpdate": "更新網域", "DomainUpdate": "更新網域",
"Download": "下載", "Download": "下載",
"DownloadCenter": "下載中心", "DownloadCenter": "下載中心",
"DownloadFTPFileTip": "當前動作不記錄文件或者檔案大小超過閾值默認100M或者還未保存到對應儲存中",
"DownloadImportTemplateMsg": "下載創建模板", "DownloadImportTemplateMsg": "下載創建模板",
"DownloadReplay": "下載錄影", "DownloadReplay": "下載錄影",
"DownloadUpdateTemplateMsg": "下載更新範本", "DownloadUpdateTemplateMsg": "下載更新範本",

@ -62,6 +62,7 @@ class PrivateSettingSerializer(PublicSettingSerializer):
CHAT_AI_ENABLED = serializers.BooleanField() CHAT_AI_ENABLED = serializers.BooleanField()
GPT_MODEL = serializers.CharField() GPT_MODEL = serializers.CharField()
FILE_UPLOAD_SIZE_LIMIT_MB = serializers.IntegerField() FILE_UPLOAD_SIZE_LIMIT_MB = serializers.IntegerField()
FTP_FILE_MAX_STORE = serializers.IntegerField()
LOKI_LOG_ENABLED = serializers.BooleanField() LOKI_LOG_ENABLED = serializers.BooleanField()
TOOL_USER_ENABLED = serializers.BooleanField() TOOL_USER_ENABLED = serializers.BooleanField()

Loading…
Cancel
Save