From 7981c8b76ea5708bfb75b59fcd65252e72ed72f3 Mon Sep 17 00:00:00 2001
From: liu <2021943741@qq.com>
Date: 星期二, 20 十月 2026 14:09:55 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/dev_江苏商贸供销社' into dev_江苏商贸供销社
---
src/main.ts | 17 ++++++++++++++++-
1 files changed, 16 insertions(+), 1 deletions(-)
diff --git a/src/main.ts b/src/main.ts
index e208cd2..b078d0b 100644
--- a/src/main.ts
+++ b/src/main.ts
@@ -1,10 +1,11 @@
import { initPreferences, preferencesManager } from './packages/preferences/src';
import { unmountGlobalLoading } from './packages/utils/src';
-import { overridesPreferences, preferencesExtension } from './preferences';
+import { overridesPreferences, portalAppearancePreferences, preferencesExtension } from './preferences';
declare const __APP_LOGO__: string;
declare const __APP_FAVICON__: string;
+declare const __APP_NAME__: string;
/**
* 搴旂敤鍒濆鍖栧畬鎴愪箣鍚庡啀杩涜椤甸潰鍔犺浇娓叉煋
@@ -23,10 +24,24 @@
overrides: overridesPreferences,
});
+ // 涓�娆℃�ц縼绉诲瑙傦紝閬垮厤宸叉湁鍋忓ソ缂撳瓨璁╂柊鐗堣彍鍗曞竷灞�涓嶇敓鏁堛��
+ const appearanceKey = `${namespace}-portal-appearance-v2`;
+ if (!localStorage.getItem(appearanceKey)) {
+ preferencesManager.updatePreferences(portalAppearancePreferences);
+ localStorage.setItem(appearanceKey, '1');
+ }
+
// 寮哄埗瑕嗙洊鍏徃 logo 鍜� favicon锛岀粫杩� localStorage 缂撳瓨
if (__APP_LOGO__) {
preferencesManager.updatePreferences({ logo: { source: __APP_LOGO__ } });
}
+ // 寮哄埗瑕嗙洊鍏徃鍚嶇О锛岀粫杩� localStorage 缂撳瓨
+ if (__APP_NAME__) {
+ preferencesManager.updatePreferences({
+ app: { name: __APP_NAME__ },
+ copyright: { companyName: __APP_NAME__ },
+ });
+ }
if (__APP_FAVICON__) {
const link = document.querySelector('link[rel="icon"]');
if (link) {
--
Gitblit v1.9.3