diff --git a/apps/locale/zh/LC_MESSAGES/django.mo b/apps/locale/zh/LC_MESSAGES/django.mo index 59384abe0..eada29942 100644 --- a/apps/locale/zh/LC_MESSAGES/django.mo +++ b/apps/locale/zh/LC_MESSAGES/django.mo @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d945fc6151d6f6354052a0a09706a52e7a2fa2f9e02254965cf26b134d78c3a -size 103377 +oid sha256:97b2aa050b5846dd3399d45286d34f282acb55dca3e2b18a79c16b9d34ec938f +size 103818 diff --git a/apps/locale/zh/LC_MESSAGES/django.po b/apps/locale/zh/LC_MESSAGES/django.po index 06af10e1f..aeda480a1 100644 --- a/apps/locale/zh/LC_MESSAGES/django.po +++ b/apps/locale/zh/LC_MESSAGES/django.po @@ -658,8 +658,6 @@ msgid "Script" msgstr "" #: assets/models/asset/web.py:13 -#, fuzzy -#| msgid "Auto fill" msgid "Autofill" msgstr "自动填充" @@ -1990,10 +1988,8 @@ msgid "Asset display" msgstr "资产名称" #: authentication/models.py:85 -#, fuzzy -#| msgid "Action display" msgid "Account display" -msgstr "动作名称" +msgstr "账号显示" #: authentication/models.py:89 msgid "Connection token" @@ -4698,52 +4694,38 @@ msgid "Storage is invalid" msgstr "存储无效" #: terminal/models/applet/applet.py:21 -#, fuzzy -#| msgid "Manually input" msgid "Manual" -msgstr "手动输入" +msgstr "手动" #: terminal/models/applet/applet.py:22 msgid "Git" msgstr "" #: terminal/models/applet/applet.py:23 -#, fuzzy -#| msgid "Remote app" msgid "Remote gzip" msgstr "远程应用" #: terminal/models/applet/applet.py:28 -#, fuzzy -#| msgid "Auth url" msgid "Author" -msgstr "认证地址" +msgstr "作者" #: terminal/models/applet/applet.py:32 msgid "Tags" -msgstr "" +msgstr "标签" #: terminal/models/applet/applet.py:59 terminal/models/applet/host.py:17 -#, fuzzy -#| msgid "Apply assets" msgid "Applet" -msgstr "申请资产" +msgstr "远程应用" #: terminal/models/applet/host.py:13 -#, fuzzy -#| msgid "Verify account automation" msgid "Account automation" -msgstr "账号校验自动化" +msgstr "账号自动化" #: terminal/models/applet/host.py:14 -#, fuzzy -#| msgid "Date sync" msgid "Date synced" -msgstr "同步日期" +msgstr "最后同步日期" #: terminal/models/applet/host.py:26 -#, fuzzy -#| msgid "Host" msgid "Hosting" msgstr "主机" diff --git a/apps/terminal/models/applet/applet.py b/apps/terminal/models/applet/applet.py index 25e3a2784..0969204b7 100644 --- a/apps/terminal/models/applet/applet.py +++ b/apps/terminal/models/applet/applet.py @@ -17,11 +17,6 @@ class Applet(JMSBaseModel): general = 'general', _('General') web = 'web', _('Web') - class VCSType(models.TextChoices): - manual = 'manual', _('Manual') - git = 'git', _('Git') - archive = 'archive', _('Remote gzip') - name = models.CharField(max_length=128, verbose_name=_('Name'), unique=True) display_name = models.CharField(max_length=128, verbose_name=_('Display name')) version = models.CharField(max_length=16, verbose_name=_('Version')) diff --git a/apps/terminal/serializers/applet.py b/apps/terminal/serializers/applet.py index 5ad2416b8..97f8fae64 100644 --- a/apps/terminal/serializers/applet.py +++ b/apps/terminal/serializers/applet.py @@ -60,13 +60,13 @@ class AppletHostSerializer(HostSerializer): } def __init__(self, *args, data=None, **kwargs): - self.set_initial_data(data) - super().__init__(*args, data=data, **kwargs) + if data: + self.set_initial_data(data) + kwargs['data'] = data + super().__init__(*args, **kwargs) @staticmethod def set_initial_data(data): - if not data: - return platform = Platform.objects.get(name='RemoteAppHost') data.update({ 'platform': platform.id,