alielie
2026-06-04 771a0e7b6b1276087515bbe94de28358cb92963b
HMI.Core/Setting/SystemSetting.cs
@@ -25,11 +25,14 @@
        }
        public string LogoPath { get; private set; } = ".\\JingCeLogo.png";
        public string LogoPath { get; private set; } = ".\\Logo.png";
        public string LoginLogoPath { get; private set; } = ".\\LoginLogo.png";
        public string WindowTitle { get; private set; } = "产品测试平台";
        public string PlcIp { get; private set; }
        public string PlcIp { get; private set; } = "127.0.0.1";
        public int PlcPort { get; private set; } = 102;
        public bool PlcEnabled { get; private set; }
        public string CurrentLanguage { get; private set; } = "zh-CN";
        public int LogExpiredDays { get; private set; } = 7;
        private static void LoadFromXml()
        {
@@ -45,6 +48,11 @@
                BeanUtil.Copy(model, setting);
                Instance = setting;
            }
        }
        public static SystemSettingModel GetModel()
        {
            return XmlHelper.DeserializeFromXml<SystemSettingModel>(FilePath);
        }
        public static void ReLoad()
@@ -74,6 +82,13 @@
            set { Set(ref logoPath, value); }
        }
        private string loginLogoPath;
        public string LoginLogoPath
        {
            get => loginLogoPath;
            set { Set(ref loginLogoPath, value); }
        }
        private string windowTitle;
        public string WindowTitle
        {
@@ -88,6 +103,13 @@
            set { Set(ref plcIp, value); }
        }
        private int plcPort;
        public int PlcPort
        {
            get => plcPort;
            set { Set(ref plcPort, value); }
        }
        private bool plcEnabled;
        public bool PlcEnabled
        {
@@ -101,5 +123,12 @@
            get => currentLanguage;
            set { Set(ref currentLanguage, value); }
        }
        private int logExpiredDays;
        public int LogExpiredDays
        {
            get => logExpiredDays;
            set { Set(ref logExpiredDays, value); }
        }
    }
}