diff --git a/ui/src/views/application-overview/component/DisplaySettingDialog.vue b/ui/src/views/application-overview/component/DisplaySettingDialog.vue index bacfd4a1e0a..6df5828f766 100644 --- a/ui/src/views/application-overview/component/DisplaySettingDialog.vue +++ b/ui/src/views/application-overview/component/DisplaySettingDialog.vue @@ -59,7 +59,8 @@ const emit = defineEmits(['refresh']) const displayFormRef = ref() const form = ref({ - show_source: false + show_source: false, + language: '', }) const detail = ref(null) @@ -70,18 +71,15 @@ const loading = ref(false) watch(dialogVisible, (bool) => { if (!bool) { form.value = { - show_source: false + show_source: false, + language: '', } } }) const open = (data: any, content: any) => { detail.value = content form.value.show_source = data.show_source - form.value.language = data.language - if (!form.value.language) { - form.value.language = getBrowserLang() - } - + form.value.language = data.language || getBrowserLang() dialogVisible.value = true } diff --git a/ui/src/views/application-overview/component/XPackDisplaySettingDialog.vue b/ui/src/views/application-overview/component/XPackDisplaySettingDialog.vue index 7e17b7128d2..a1aed023faa 100644 --- a/ui/src/views/application-overview/component/XPackDisplaySettingDialog.vue +++ b/ui/src/views/application-overview/component/XPackDisplaySettingDialog.vue @@ -146,16 +146,16 @@ - +
{{ $t('views.applicationOverview.appInfo.SettingDisplayDialog.customThemeColor') }}
- + {{ - !form.custom_theme.theme_color + !xpackForm.custom_theme.theme_color ? $t('views.applicationOverview.appInfo.SettingDisplayDialog.default') : '' }} @@ -167,14 +167,14 @@ $t('views.applicationOverview.appInfo.SettingDisplayDialog.headerTitleFontColor') }} - +
{{ $t('views.applicationOverview.appInfo.SettingDisplayDialog.languageLabel') }}
- +
- +
- + - + ({ - show_source: false -}) const xpackForm = ref({ show_source: false, @@ -468,7 +465,6 @@ const customStyle = computed(() => { }) function resetForm() { - form.value = cloneDeep(defaultSetting) xpackForm.value = cloneDeep(defaultSetting) imgUrl.value = { avatar: '', @@ -503,7 +499,6 @@ const open = (data: any, content: any) => { imgUrl.value.user_avatar = data.user_avatar xpackForm.value.disclaimer = data.disclaimer xpackForm.value.disclaimer_value = data.disclaimer_value - console.log(xpackForm.value.disclaimer_value) if ( xpackForm.value.disclaimer_value === t('views.applicationOverview.appInfo.SettingDisplayDialog.disclaimerValue') @@ -520,7 +515,6 @@ const open = (data: any, content: any) => { header_font_color: data.custom_theme?.header_font_color || '#1f2329' } xpackForm.value.float_location = data.float_location - form.value = xpackForm.value dialogVisible.value = true }