Explorar o código

增加翻译,界面更新

KWD hai 5 meses
pai
achega
fbb7e713b3

+ 1 - 1
ResXManager.config.xml

@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="utf-8"?>
 <?xml version="1.0" encoding="utf-8"?>
 <Values xmlns="urn:tom-englert.de/Configuration/1/0">
 <Values xmlns="urn:tom-englert.de/Configuration/1/0">
   <Value Key="NeutralResourcesLanguage">zh-CN</Value>
   <Value Key="NeutralResourcesLanguage">zh-CN</Value>
-</Values>
+<Value Key="PrefixTranslations">False</Value></Values>

+ 22 - 22
TeamAAS-VM/App.xaml

@@ -1,35 +1,37 @@
-<prism:PrismApplication x:Class="TeamAAS_VP.App"
-                        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-                        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-                        xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
-                        xmlns:c="clr-namespace:TeamAAS_VP.ValueConverter"
-                        xmlns:wpf="clr-namespace:MaterialDesignThemes.Wpf;assembly=MaterialDesignThemes.Wpf"
-                        xmlns:local="clr-namespace:TeamAAS_VP"
-                        xmlns:prism="http://prismlibrary.com/">
+<prism:PrismApplication
+    x:Class="TeamAAS_VP.App"
+    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:c="clr-namespace:TeamAAS_VP.ValueConverter"
+    xmlns:local="clr-namespace:TeamAAS_VP"
+    xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
+    xmlns:prism="http://prismlibrary.com/"
+    xmlns:wpf="clr-namespace:MaterialDesignThemes.Wpf;assembly=MaterialDesignThemes.Wpf">
     <Application.Resources>
     <Application.Resources>
         <ResourceDictionary>
         <ResourceDictionary>
             <ResourceDictionary.MergedDictionaries>
             <ResourceDictionary.MergedDictionaries>
-                
+
                 <!--<ResourceDictionary Source="Resources/Languages1/Chinese.xaml" />-->
                 <!--<ResourceDictionary Source="Resources/Languages1/Chinese.xaml" />-->
                 <ResourceDictionary Source="Resources\Styles\DefaultColors.xaml" />
                 <ResourceDictionary Source="Resources\Styles\DefaultColors.xaml" />
 
 
                 <ResourceDictionary Source="Resources/FontSize/DefaultFontSize.xaml" />
                 <ResourceDictionary Source="Resources/FontSize/DefaultFontSize.xaml" />
 
 
-                <materialDesign:BundledTheme BaseTheme="Inherit"
-                                             PrimaryColor="DeepPurple"
-                                             SecondaryColor="Purple" />
-                <!-- MahApps.Metro resource dictionaries. Make sure that all file names are Case Sensitive! -->
+                <materialDesign:BundledTheme
+                    BaseTheme="Inherit"
+                    PrimaryColor="DeepPurple"
+                    SecondaryColor="Purple" />
+                <!--  MahApps.Metro resource dictionaries. Make sure that all file names are Case Sensitive!  -->
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
-                <!-- Theme setting -->
+                <!--  Theme setting  -->
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Themes/Light.Blue.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Themes/Light.Blue.xaml" />
-                
-                <!--MaterialDesign-->
+
+                <!--  MaterialDesign  -->
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign3.Defaults.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesign3.Defaults.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.DeepPurple.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.DeepPurple.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Secondary/MaterialDesignColor.Lime.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Secondary/MaterialDesignColor.Lime.xaml" />
-                <!--MaterialDesign-->
+                <!--  MaterialDesign  -->
 
 
                 <ResourceDictionary Source="pack://application:,,,/ICSharpCode.AvalonEdit;component/themes/generic.xaml" />
                 <ResourceDictionary Source="pack://application:,,,/ICSharpCode.AvalonEdit;component/themes/generic.xaml" />
             </ResourceDictionary.MergedDictionaries>
             </ResourceDictionary.MergedDictionaries>
@@ -38,12 +40,10 @@
             <c:StringFormatConverter x:Key="StringFormatConverter" />
             <c:StringFormatConverter x:Key="StringFormatConverter" />
             <c:InvertBooleanConverter x:Key="InvertBooleanConverter" />
             <c:InvertBooleanConverter x:Key="InvertBooleanConverter" />
             <c:ObjectToVisibilityConverter x:Key="ObjectToVisibilityConverter" />
             <c:ObjectToVisibilityConverter x:Key="ObjectToVisibilityConverter" />
-            <c:ObjectToVisibilityConverter x:Key="ObjectToCollapsedConverter"
-                                           Invert="True" />
+            <c:ObjectToVisibilityConverter x:Key="ObjectToCollapsedConverter" Invert="True" />
             <c:BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
             <c:BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
-            <c:BooleanToVisibilityConverter x:Key="BooleanToCollapsedConverter"
-                                            Invert="True" />
+            <c:BooleanToVisibilityConverter x:Key="BooleanToCollapsedConverter" Invert="True" />
         </ResourceDictionary>
         </ResourceDictionary>
-        
+
     </Application.Resources>
     </Application.Resources>
 </prism:PrismApplication>
 </prism:PrismApplication>

+ 15 - 45
TeamAAS-VM/Core/Management.cs

@@ -94,38 +94,6 @@ namespace TeamAAS_VP.Core
 
 
         #region 属性
         #region 属性
 
 
-        private System.Windows.Media.Brush _StatusBackground;
-
-        public System.Windows.Media.Brush StatusBackground
-        {
-            get { return _StatusBackground; }
-            set { SetProperty(ref _StatusBackground, value); }
-        }
-
-        private System.Windows.Media.Brush _RunModelBackground;
-
-        public System.Windows.Media.Brush RunModelBackground
-        {
-            get { return _RunModelBackground; }
-            set { SetProperty(ref _RunModelBackground, value); }
-        }
-
-        private System.Windows.Media.Brush _ManualModeBackground;
-
-        public System.Windows.Media.Brush ManualModeBackground
-        {
-            get { return _ManualModeBackground; }
-            set { SetProperty(ref _ManualModeBackground, value); }
-        }
-
-        private System.Windows.Media.Brush _ClearModeBackground;
-
-        public System.Windows.Media.Brush ClearModeBackground
-        {
-            get { return _ClearModeBackground; }
-            set { SetProperty(ref _ClearModeBackground, value); }
-        }
-
         private ObservableCollection<ShowRender> _Renders;
         private ObservableCollection<ShowRender> _Renders;
 
 
         /// <summary>
         /// <summary>
@@ -263,6 +231,17 @@ namespace TeamAAS_VP.Core
 
 
         public static int uphhour = 0;
         public static int uphhour = 0;
         public static int uphnumber = 0;
         public static int uphnumber = 0;
+
+
+        /// <summary>
+        /// 设备状态
+        /// </summary>
+        private RunDisplayMode _CurrentDisplayMode;
+        public RunDisplayMode CurrentDisplayMode
+        {
+            get { return _CurrentDisplayMode; }
+            set { SetProperty(ref _CurrentDisplayMode, value); }
+        }
         #endregion
         #endregion
 
 
         #region 命令
         #region 命令
@@ -1381,7 +1360,6 @@ namespace TeamAAS_VP.Core
                 //    _productService.CurrentProductCode = DateTime.Now.ToString("yyyyMMddHHmmssfff");
                 //    _productService.CurrentProductCode = DateTime.Now.ToString("yyyyMMddHHmmssfff");
                 //}
                 //}
 
 
-
                 bool isDryMode = plc.ReadNode<bool>(addressConfig.In_DryMode.Address);
                 bool isDryMode = plc.ReadNode<bool>(addressConfig.In_DryMode.Address);
 
 
                 // 触发下相机拍照--下相机拍屏幕,预定位
                 // 触发下相机拍照--下相机拍屏幕,预定位
@@ -2726,9 +2704,7 @@ namespace TeamAAS_VP.Core
                         }
                         }
                         if (state)
                         if (state)
                         {
                         {
-                            ClearModeBackground = System.Windows.Media.Brushes.White;
-                            RunModelBackground = System.Windows.Media.Brushes.White;
-                            ManualModeBackground = System.Windows.Media.Brushes.Orange;
+                            CurrentDisplayMode = RunDisplayMode.Manual;
                             SendTaskMessage("收到切换成维修模式", MessageLevel.Info);
                             SendTaskMessage("收到切换成维修模式", MessageLevel.Info);
                         }
                         }
                     }
                     }
@@ -2748,9 +2724,7 @@ namespace TeamAAS_VP.Core
                         }
                         }
                         if (state)
                         if (state)
                         {
                         {
-                            ClearModeBackground = System.Windows.Media.Brushes.Yellow;
-                            RunModelBackground = System.Windows.Media.Brushes.White;
-                            ManualModeBackground = System.Windows.Media.Brushes.White;
+                            CurrentDisplayMode = RunDisplayMode.Clear;
                             SendTaskMessage("收到切换成流线模式", MessageLevel.Info);
                             SendTaskMessage("收到切换成流线模式", MessageLevel.Info);
                         }
                         }
                     }
                     }
@@ -3692,16 +3666,12 @@ namespace TeamAAS_VP.Core
             var user = _systemDatabaseService.GetCurrentUser();
             var user = _systemDatabaseService.GetCurrentUser();
             if (connectStaus && mesStatus && _LastAutoRunning && user.userPart == UserPart.Operator)
             if (connectStaus && mesStatus && _LastAutoRunning && user.userPart == UserPart.Operator)
             {
             {
-                RunModelBackground = System.Windows.Media.Brushes.Green;
-                ClearModeBackground = System.Windows.Media.Brushes.White;
-                ManualModeBackground = System.Windows.Media.Brushes.White;
+                CurrentDisplayMode = RunDisplayMode.Auto;
                 SendTaskMessage("当前为生产模式", MessageLevel.Info);
                 SendTaskMessage("当前为生产模式", MessageLevel.Info);
             }
             }
             else
             else
             {
             {
-                RunModelBackground = System.Windows.Media.Brushes.White;
-                ClearModeBackground = System.Windows.Media.Brushes.White;
-                ManualModeBackground = System.Windows.Media.Brushes.Orange;
+                CurrentDisplayMode = RunDisplayMode.Manual;
                 SendTaskMessage("当前为调机模式", MessageLevel.Info);
                 SendTaskMessage("当前为调机模式", MessageLevel.Info);
             }
             }
             concurrenty = true;
             concurrenty = true;

+ 13 - 0
TeamAAS-VM/Enums/RunDisplayMode.cs

@@ -0,0 +1,13 @@
+namespace TeamAAS_VP.Enums
+{
+    /// <summary>
+    /// 顶部运行模式显示枚举
+    /// </summary>
+    public enum RunDisplayMode
+    {
+        Unknown = 0,
+        Auto = 1,    // 生产
+        Manual = 2,  // 调机
+        Clear = 3    // 流线
+    }
+}

+ 7 - 6
TeamAAS-VM/Resources/FontSize/DefaultFontSize.xaml

@@ -1,17 +1,18 @@
-<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-                    xmlns:sys="clr-namespace:System;assembly=mscorlib">
-    <!--标题-->
+<ResourceDictionary
+    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:sys="clr-namespace:System;assembly=mscorlib">
+    <!--  标题  -->
     <sys:Double x:Key="Font.Size.Title1">34</sys:Double>
     <sys:Double x:Key="Font.Size.Title1">34</sys:Double>
     <sys:Double x:Key="Font.Size.Title2">20</sys:Double>
     <sys:Double x:Key="Font.Size.Title2">20</sys:Double>
     <sys:Double x:Key="Font.Size.Title3">18</sys:Double>
     <sys:Double x:Key="Font.Size.Title3">18</sys:Double>
     <sys:Double x:Key="Font.Size.Title4">16</sys:Double>
     <sys:Double x:Key="Font.Size.Title4">16</sys:Double>
-    <!--正文-->
+    <!--  正文  -->
     <sys:Double x:Key="Font.Size.Body1">18</sys:Double>
     <sys:Double x:Key="Font.Size.Body1">18</sys:Double>
     <sys:Double x:Key="Font.Size.Body2">16</sys:Double>
     <sys:Double x:Key="Font.Size.Body2">16</sys:Double>
     <sys:Double x:Key="Font.Size.Body3">14</sys:Double>
     <sys:Double x:Key="Font.Size.Body3">14</sys:Double>
     <sys:Double x:Key="Font.Size.Body4">12</sys:Double>
     <sys:Double x:Key="Font.Size.Body4">12</sys:Double>
-    <!--标注-->
+    <!--  标注  -->
     <sys:Double x:Key="Font.Size.Captions1">16</sys:Double>
     <sys:Double x:Key="Font.Size.Captions1">16</sys:Double>
     <sys:Double x:Key="Font.Size.Captions2">14</sys:Double>
     <sys:Double x:Key="Font.Size.Captions2">14</sys:Double>
     <sys:Double x:Key="Font.Size.Captions3">12</sys:Double>
     <sys:Double x:Key="Font.Size.Captions3">12</sys:Double>

+ 157 - 4
TeamAAS-VM/Resources/Languages/Lang.Designer.cs

@@ -519,6 +519,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 NG数量: 的本地化字符串。
+        /// </summary>
+        public static string NG数量 {
+            get {
+                return ResourceManager.GetString("NG数量", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 一次输出所有点位 的本地化字符串。
         ///   查找类似 一次输出所有点位 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -1518,6 +1527,24 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 产品与mes参数绑定设置 的本地化字符串。
+        /// </summary>
+        public static string 产品与mes参数绑定设置 {
+            get {
+                return ResourceManager.GetString("产品与mes参数绑定设置", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 产品信息 的本地化字符串。
+        /// </summary>
+        public static string 产品信息 {
+            get {
+                return ResourceManager.GetString("产品信息", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 产品列表 的本地化字符串。
         ///   查找类似 产品列表 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -1564,7 +1591,7 @@ namespace TeamAAS_VP.Resources.Languages {
         }
         }
         
         
         /// <summary>
         /// <summary>
-        ///   查找类似 产品名称 的本地化字符串。
+        ///   查找类似 产品名称: 的本地化字符串。
         /// </summary>
         /// </summary>
         public static string 产品名称 {
         public static string 产品名称 {
             get {
             get {
@@ -1618,7 +1645,16 @@ namespace TeamAAS_VP.Resources.Languages {
         }
         }
         
         
         /// <summary>
         /// <summary>
-        ///   查找类似 产品编号 的本地化字符串。
+        ///   查找类似 产品类型: 的本地化字符串。
+        /// </summary>
+        public static string 产品类型 {
+            get {
+                return ResourceManager.GetString("产品类型", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 产品编号: 的本地化字符串。
         /// </summary>
         /// </summary>
         public static string 产品编号 {
         public static string 产品编号 {
             get {
             get {
@@ -1627,7 +1663,7 @@ namespace TeamAAS_VP.Resources.Languages {
         }
         }
         
         
         /// <summary>
         /// <summary>
-        ///   查找类似 产品编码 的本地化字符串。
+        ///   查找类似 产品编码: 的本地化字符串。
         /// </summary>
         /// </summary>
         public static string 产品编码 {
         public static string 产品编码 {
             get {
             get {
@@ -1644,6 +1680,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 产品颜色: 的本地化字符串。
+        /// </summary>
+        public static string 产品颜色 {
+            get {
+                return ResourceManager.GetString("产品颜色", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 产能统计 的本地化字符串。
         ///   查找类似 产能统计 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -1851,6 +1896,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 保存的CSV文件路径: 的本地化字符串。
+        /// </summary>
+        public static string 保存的CSV文件路径 {
+            get {
+                return ResourceManager.GetString("保存的CSV文件路径", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 保存系统参数 的本地化字符串。
         ///   查找类似 保存系统参数 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -2805,6 +2859,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 启用 MES 的本地化字符串。
+        /// </summary>
+        public static string 启用_MES {
+            get {
+                return ResourceManager.GetString("启用 MES", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 启用二次定位相机 的本地化字符串。
         ///   查找类似 启用二次定位相机 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -4335,6 +4398,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 抛料数: 的本地化字符串。
+        /// </summary>
+        public static string 抛料数 {
+            get {
+                return ResourceManager.GetString("抛料数", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 报告已导出 的本地化字符串。
         ///   查找类似 报告已导出 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -4830,6 +4902,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 是否保存CSV文件 的本地化字符串。
+        /// </summary>
+        public static string 是否保存CSV文件 {
+            get {
+                return ResourceManager.GetString("是否保存CSV文件", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 是否保存Feeder? 的本地化字符串。
         ///   查找类似 是否保存Feeder? 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -4848,6 +4929,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 是否保存ppid 的本地化字符串。
+        /// </summary>
+        public static string 是否保存ppid {
+            get {
+                return ResourceManager.GetString("是否保存ppid", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 是否保存产品[{0}]? 的本地化字符串。
         ///   查找类似 是否保存产品[{0}]? 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -4992,6 +5082,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 是否启用两次产品编号 的本地化字符串。
+        /// </summary>
+        public static string 是否启用两次产品编号 {
+            get {
+                return ResourceManager.GetString("是否启用两次产品编号", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 是否启用低量报警: 的本地化字符串。
         ///   查找类似 是否启用低量报警: 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -7773,6 +7872,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 良率: 的本地化字符串。
+        /// </summary>
+        public static string 良率 {
+            get {
+                return ResourceManager.GetString("良率", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 节点头 的本地化字符串。
         ///   查找类似 节点头 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -7782,6 +7890,15 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 获取 的本地化字符串。
+        /// </summary>
+        public static string 获取 {
+            get {
+                return ResourceManager.GetString("获取", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 获取P0点: 的本地化字符串。
         ///   查找类似 获取P0点: 的本地化字符串。
         /// </summary>
         /// </summary>
@@ -8215,7 +8332,25 @@ namespace TeamAAS_VP.Resources.Languages {
         }
         }
         
         
         /// <summary>
         /// <summary>
-        ///   查找类似 设备名称 的本地化字符串。
+        ///   查找类似 设备列表 的本地化字符串。
+        /// </summary>
+        public static string 设备列表 {
+            get {
+                return ResourceManager.GetString("设备列表", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 设备名称: 的本地化字符串。
+        /// </summary>
+        public static string 设备名 {
+            get {
+                return ResourceManager.GetString("设备名", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 设备名称: 的本地化字符串。
         /// </summary>
         /// </summary>
         public static string 设备名称 {
         public static string 设备名称 {
             get {
             get {
@@ -8223,6 +8358,24 @@ namespace TeamAAS_VP.Resources.Languages {
             }
             }
         }
         }
         
         
+        /// <summary>
+        ///   查找类似 设备描述: 的本地化字符串。
+        /// </summary>
+        public static string 设备描述 {
+            get {
+                return ResourceManager.GetString("设备描述", resourceCulture);
+            }
+        }
+        
+        /// <summary>
+        ///   查找类似 设备编号: 的本地化字符串。
+        /// </summary>
+        public static string 设备编号 {
+            get {
+                return ResourceManager.GetString("设备编号", resourceCulture);
+            }
+        }
+        
         /// <summary>
         /// <summary>
         ///   查找类似 设定参数 的本地化字符串。
         ///   查找类似 设定参数 的本地化字符串。
         /// </summary>
         /// </summary>

+ 52 - 1
TeamAAS-VM/Resources/Languages/Lang.en.resx

@@ -3184,6 +3184,57 @@
     <value>streamline</value>
     <value>streamline</value>
   </data>
   </data>
   <data name="屏幕中心基准点位" xml:space="preserve">
   <data name="屏幕中心基准点位" xml:space="preserve">
-    <value>屏幕中心基准点位</value>
+    <value>Screen Center Reference Point</value>
+  </data>
+  <data name="抛料数" xml:space="preserve">
+    <value>Rejection Count:</value>
+  </data>
+  <data name="NG数量" xml:space="preserve">
+    <value>NG Quantity:</value>
+  </data>
+  <data name="良率" xml:space="preserve">
+    <value>Yield Rate:</value>
+  </data>
+  <data name="设备列表" xml:space="preserve">
+    <value>Equipment List</value>
+  </data>
+  <data name="设备编号" xml:space="preserve">
+    <value>Equipment No.:</value>
+  </data>
+  <data name="设备名" xml:space="preserve">
+    <value>Equipment Name:</value>
+  </data>
+  <data name="设备描述" xml:space="preserve">
+    <value>Equipment Description:</value>
+  </data>
+  <data name="启用 MES" xml:space="preserve">
+    <value>Enable MES:</value>
+  </data>
+  <data name="是否启用两次产品编号" xml:space="preserve">
+    <value>Dual Product No. Enable?</value>
+  </data>
+  <data name="是否保存CSV文件" xml:space="preserve">
+    <value>Save CSV File?</value>
+  </data>
+  <data name="是否保存ppid" xml:space="preserve">
+    <value>Save PPID?</value>
+  </data>
+  <data name="保存的CSV文件路径" xml:space="preserve">
+    <value>Saved CSV Path:</value>
+  </data>
+  <data name="产品信息" xml:space="preserve">
+    <value>Product Information</value>
+  </data>
+  <data name="产品与mes参数绑定设置" xml:space="preserve">
+    <value>Product-MES Parameter Binding</value>
+  </data>
+  <data name="产品颜色" xml:space="preserve">
+    <value>Product Color</value>
+  </data>
+  <data name="产品类型" xml:space="preserve">
+    <value>Product Type</value>
+  </data>
+  <data name="获取" xml:space="preserve">
+    <value>Get</value>
   </data>
   </data>
 </root>
 </root>

+ 52 - 1
TeamAAS-VM/Resources/Languages/Lang.ja-JP.resx

@@ -3184,6 +3184,57 @@
     <value>流線</value>
     <value>流線</value>
   </data>
   </data>
   <data name="屏幕中心基准点位" xml:space="preserve">
   <data name="屏幕中心基准点位" xml:space="preserve">
-    <value>屏幕中心基准点位</value>
+    <value>画面中心基準点</value>
+  </data>
+  <data name="抛料数" xml:space="preserve">
+    <value>不良排出数:</value>
+  </data>
+  <data name="NG数量" xml:space="preserve">
+    <value>NG数量:</value>
+  </data>
+  <data name="良率" xml:space="preserve">
+    <value>歩留まり:</value>
+  </data>
+  <data name="设备列表" xml:space="preserve">
+    <value>設備リスト</value>
+  </data>
+  <data name="设备编号" xml:space="preserve">
+    <value>設備番号:</value>
+  </data>
+  <data name="设备名" xml:space="preserve">
+    <value>設備名:</value>
+  </data>
+  <data name="设备描述" xml:space="preserve">
+    <value>設備説明:</value>
+  </data>
+  <data name="启用 MES" xml:space="preserve">
+    <value>MES有効化:</value>
+  </data>
+  <data name="是否启用两次产品编号" xml:space="preserve">
+    <value>製品番号二重設定有効化?</value>
+  </data>
+  <data name="是否保存CSV文件" xml:space="preserve">
+    <value>CSVファイル保存?</value>
+  </data>
+  <data name="是否保存ppid" xml:space="preserve">
+    <value>PPID保存?</value>
+  </data>
+  <data name="保存的CSV文件路径" xml:space="preserve">
+    <value>CSV保存パス:</value>
+  </data>
+  <data name="产品信息" xml:space="preserve">
+    <value>製品情報</value>
+  </data>
+  <data name="产品与mes参数绑定设置" xml:space="preserve">
+    <value>製品-MESパラメータ連携設定</value>
+  </data>
+  <data name="产品颜色" xml:space="preserve">
+    <value>製品色</value>
+  </data>
+  <data name="产品类型" xml:space="preserve">
+    <value>製品タイプ</value>
+  </data>
+  <data name="获取" xml:space="preserve">
+    <value>取得</value>
   </data>
   </data>
 </root>
 </root>

+ 55 - 4
TeamAAS-VM/Resources/Languages/Lang.resx

@@ -558,7 +558,7 @@
     <value>当前产品</value>
     <value>当前产品</value>
   </data>
   </data>
   <data name="产品编号" xml:space="preserve">
   <data name="产品编号" xml:space="preserve">
-    <value>产品编号</value>
+    <value>产品编号:</value>
   </data>
   </data>
   <data name="当前产品总产量" xml:space="preserve">
   <data name="当前产品总产量" xml:space="preserve">
     <value>当前产品总产量</value>
     <value>当前产品总产量</value>
@@ -1458,7 +1458,7 @@
     <value>产品管理</value>
     <value>产品管理</value>
   </data>
   </data>
   <data name="产品名称" xml:space="preserve">
   <data name="产品名称" xml:space="preserve">
-    <value>产品名称</value>
+    <value>产品名称:</value>
   </data>
   </data>
   <data name="流程名称" xml:space="preserve">
   <data name="流程名称" xml:space="preserve">
     <value>流程名称</value>
     <value>流程名称</value>
@@ -2680,7 +2680,7 @@
     <value>放置运动坐标4</value>
     <value>放置运动坐标4</value>
   </data>
   </data>
   <data name="设备名称" xml:space="preserve">
   <data name="设备名称" xml:space="preserve">
-    <value>设备名称</value>
+    <value>设备名称:</value>
   </data>
   </data>
   <data name="操作员" xml:space="preserve">
   <data name="操作员" xml:space="preserve">
     <value>操作员</value>
     <value>操作员</value>
@@ -2740,7 +2740,7 @@
     <value>类别</value>
     <value>类别</value>
   </data>
   </data>
   <data name="产品编码" xml:space="preserve">
   <data name="产品编码" xml:space="preserve">
-    <value>产品编码</value>
+    <value>产品编码:</value>
   </data>
   </data>
   <data name="设备Id" xml:space="preserve">
   <data name="设备Id" xml:space="preserve">
     <value>设备Id</value>
     <value>设备Id</value>
@@ -3281,4 +3281,55 @@
   <data name="屏幕中心基准点位" xml:space="preserve">
   <data name="屏幕中心基准点位" xml:space="preserve">
     <value>屏幕中心基准点位</value>
     <value>屏幕中心基准点位</value>
   </data>
   </data>
+  <data name="抛料数" xml:space="preserve">
+    <value>抛料数:</value>
+  </data>
+  <data name="NG数量" xml:space="preserve">
+    <value>NG数量:</value>
+  </data>
+  <data name="良率" xml:space="preserve">
+    <value>良率:</value>
+  </data>
+  <data name="设备列表" xml:space="preserve">
+    <value>设备列表</value>
+  </data>
+  <data name="设备编号" xml:space="preserve">
+    <value>设备编号:</value>
+  </data>
+  <data name="设备名" xml:space="preserve">
+    <value>设备名称:</value>
+  </data>
+  <data name="设备描述" xml:space="preserve">
+    <value>设备描述:</value>
+  </data>
+  <data name="启用 MES" xml:space="preserve">
+    <value>启用 MES</value>
+  </data>
+  <data name="是否启用两次产品编号" xml:space="preserve">
+    <value>是否启用两次产品编号</value>
+  </data>
+  <data name="是否保存CSV文件" xml:space="preserve">
+    <value>是否保存CSV文件</value>
+  </data>
+  <data name="是否保存ppid" xml:space="preserve">
+    <value>是否保存ppid</value>
+  </data>
+  <data name="保存的CSV文件路径" xml:space="preserve">
+    <value>保存的CSV文件路径:</value>
+  </data>
+  <data name="产品信息" xml:space="preserve">
+    <value>产品信息</value>
+  </data>
+  <data name="产品与mes参数绑定设置" xml:space="preserve">
+    <value>产品与mes参数绑定设置</value>
+  </data>
+  <data name="产品颜色" xml:space="preserve">
+    <value>产品颜色:</value>
+  </data>
+  <data name="产品类型" xml:space="preserve">
+    <value>产品类型:</value>
+  </data>
+  <data name="获取" xml:space="preserve">
+    <value>获取</value>
+  </data>
 </root>
 </root>

+ 52 - 1
TeamAAS-VM/Resources/Languages/Lang.vi.resx

@@ -3184,6 +3184,57 @@
     <value>đường dòng</value>
     <value>đường dòng</value>
   </data>
   </data>
   <data name="屏幕中心基准点位" xml:space="preserve">
   <data name="屏幕中心基准点位" xml:space="preserve">
-    <value>屏幕中心基准点位</value>
+    <value>Điểm chuẩn trung tâm màn hình</value>
+  </data>
+  <data name="抛料数" xml:space="preserve">
+    <value>Số lượng từ bỏ:</value>
+  </data>
+  <data name="NG数量" xml:space="preserve">
+    <value>Số lượng NG:</value>
+  </data>
+  <data name="良率" xml:space="preserve">
+    <value>Tỷ lệ đạt:</value>
+  </data>
+  <data name="设备列表" xml:space="preserve">
+    <value>Danh sách thiết bị</value>
+  </data>
+  <data name="设备编号" xml:space="preserve">
+    <value>Mã thiết bị:</value>
+  </data>
+  <data name="设备名" xml:space="preserve">
+    <value>Tên thiết bị:</value>
+  </data>
+  <data name="设备描述" xml:space="preserve">
+    <value>Mô tả thiết bị:</value>
+  </data>
+  <data name="启用 MES" xml:space="preserve">
+    <value>Kích hoạt MES:</value>
+  </data>
+  <data name="是否启用两次产品编号" xml:space="preserve">
+    <value>Bật mã sản phẩm kép?</value>
+  </data>
+  <data name="是否保存CSV文件" xml:space="preserve">
+    <value>Lưu tệp CSV?</value>
+  </data>
+  <data name="是否保存ppid" xml:space="preserve">
+    <value>Lưu PPID?</value>
+  </data>
+  <data name="保存的CSV文件路径" xml:space="preserve">
+    <value>Đường dẫn CSV lưu:</value>
+  </data>
+  <data name="产品信息" xml:space="preserve">
+    <value>Thông tin sản phẩm</value>
+  </data>
+  <data name="产品与mes参数绑定设置" xml:space="preserve">
+    <value>Ràng buộc tham số Sản phẩm-MES</value>
+  </data>
+  <data name="产品颜色" xml:space="preserve">
+    <value>Màu sản phẩm</value>
+  </data>
+  <data name="产品类型" xml:space="preserve">
+    <value>Loại sản phẩm</value>
+  </data>
+  <data name="获取" xml:space="preserve">
+    <value>Lấy</value>
   </data>
   </data>
 </root>
 </root>

+ 52 - 1
TeamAAS-VM/Resources/Languages/Lang.zh-TW.resx

@@ -139,7 +139,7 @@
     <value>移除相機</value>
     <value>移除相機</value>
   </data>
   </data>
   <data name="保存" xml:space="preserve">
   <data name="保存" xml:space="preserve">
-    <value>保存</value>
+    <value>儲存</value>
   </data>
   </data>
   <data name="SettingView_Camera_CameraList" xml:space="preserve">
   <data name="SettingView_Camera_CameraList" xml:space="preserve">
     <value>相機列表</value>
     <value>相機列表</value>
@@ -3186,4 +3186,55 @@
   <data name="屏幕中心基准点位" xml:space="preserve">
   <data name="屏幕中心基准点位" xml:space="preserve">
     <value>屏幕中心基准点位</value>
     <value>屏幕中心基准点位</value>
   </data>
   </data>
+  <data name="抛料数" xml:space="preserve">
+    <value>拋料數:</value>
+  </data>
+  <data name="NG数量" xml:space="preserve">
+    <value>NG數量:</value>
+  </data>
+  <data name="良率" xml:space="preserve">
+    <value>良率:</value>
+  </data>
+  <data name="设备列表" xml:space="preserve">
+    <value>設備列表</value>
+  </data>
+  <data name="设备编号" xml:space="preserve">
+    <value>設備編號:</value>
+  </data>
+  <data name="设备名" xml:space="preserve">
+    <value>設備名稱:</value>
+  </data>
+  <data name="设备描述" xml:space="preserve">
+    <value>設備描述:</value>
+  </data>
+  <data name="启用 MES" xml:space="preserve">
+    <value>啟用 MES:</value>
+  </data>
+  <data name="是否启用两次产品编号" xml:space="preserve">
+    <value>是否啟用兩次產品編號</value>
+  </data>
+  <data name="是否保存CSV文件" xml:space="preserve">
+    <value>是否儲存CSV檔案</value>
+  </data>
+  <data name="是否保存ppid" xml:space="preserve">
+    <value>是否儲存ppid</value>
+  </data>
+  <data name="保存的CSV文件路径" xml:space="preserve">
+    <value>儲存的CSV檔案路徑:</value>
+  </data>
+  <data name="产品信息" xml:space="preserve">
+    <value>產品資訊</value>
+  </data>
+  <data name="产品与mes参数绑定设置" xml:space="preserve">
+    <value>產品與mes參數綁定設定</value>
+  </data>
+  <data name="产品颜色" xml:space="preserve">
+    <value>產品顏色</value>
+  </data>
+  <data name="产品类型" xml:space="preserve">
+    <value>產品類型</value>
+  </data>
+  <data name="获取" xml:space="preserve">
+    <value>取得</value>
+  </data>
 </root>
 </root>

+ 7 - 14
TeamAAS-VM/Resources/Styles/DefaultColors.xaml

@@ -1,15 +1,8 @@
-<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
-    <SolidColorBrush x:Key="DefaultBackground"
-                     Color="#424242" />
-    <SolidColorBrush x:Key="DefaultFore"
-                     Color="#F0F0F0" />
-    <SolidColorBrush x:Key="DefaultNavigationCheckedBackground"
-                     Color="Transparent" />
-    <SolidColorBrush x:Key="DefaultNavigationCheckedFore"
-                     Color="#50ac52" />
-    <SolidColorBrush x:Key="DefaultNavigationUnCheckedBackground"
-                     Color="Transparent" />
-    <SolidColorBrush x:Key="DefaultNavigationUnCheckedFore"
-                     Color="#424242" />
+<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
+    <SolidColorBrush x:Key="DefaultBackground" Color="#424242" />
+    <SolidColorBrush x:Key="DefaultFore" Color="#F0F0F0" />
+    <SolidColorBrush x:Key="DefaultNavigationCheckedBackground" Color="Transparent" />
+    <SolidColorBrush x:Key="DefaultNavigationCheckedFore" Color="#50ac52" />
+    <SolidColorBrush x:Key="DefaultNavigationUnCheckedBackground" Color="Transparent" />
+    <SolidColorBrush x:Key="DefaultNavigationUnCheckedFore" Color="#424242" />
 </ResourceDictionary>
 </ResourceDictionary>

+ 1 - 0
TeamAAS-VM/TeamAAS-VP.csproj

@@ -538,6 +538,7 @@
     <Compile Include="Core\RectangleCenterCalculator.cs" />
     <Compile Include="Core\RectangleCenterCalculator.cs" />
     <Compile Include="Core\StabilityAnalyzer.cs" />
     <Compile Include="Core\StabilityAnalyzer.cs" />
     <Compile Include="Core\VisionProFileHelper.cs" />
     <Compile Include="Core\VisionProFileHelper.cs" />
+    <Compile Include="Enums\RunDisplayMode.cs" />
     <Compile Include="Events\CurrentStatusNotification.cs" />
     <Compile Include="Events\CurrentStatusNotification.cs" />
     <Compile Include="Events\DelaySaveImageNotification.cs" />
     <Compile Include="Events\DelaySaveImageNotification.cs" />
     <Compile Include="Events\MainTabSwitchNotification.cs" />
     <Compile Include="Events\MainTabSwitchNotification.cs" />

+ 17 - 0
TeamAAS-VM/ViewModels/MainWindowViewModel.cs

@@ -131,6 +131,18 @@ namespace TeamAAS_VP.ViewModels
             set { SetProperty(ref _MyTitle, value); }
             set { SetProperty(ref _MyTitle, value); }
         }
         }
 
 
+        private Language _CurrentLanguage;
+        public Language CurrentLanguage
+        {
+            get { return _CurrentLanguage; }
+            set
+            {
+                if (SetProperty(ref _CurrentLanguage, value))
+                {
+                    _configService?.SetCurrentLanguage(value);
+                }
+            }
+        }
         #endregion
         #endregion
 
 
         #region 命令
         #region 命令
@@ -245,6 +257,11 @@ namespace TeamAAS_VP.ViewModels
             systemconfig.SoftwareVersion = AppVersion;
             systemconfig.SoftwareVersion = AppVersion;
             _configService.SaveSystemConfiguration(systemconfig);
             _configService.SaveSystemConfiguration(systemconfig);
 
 
+            // 设置语言
+            CurrentLanguage = systemconfig.CurrentLanguage;
+            _configService.SetCurrentLanguage(CurrentLanguage);
+
+
             SendTaskMessage(Lang.软件启动, MessageLevel.Info);
             SendTaskMessage(Lang.软件启动, MessageLevel.Info);
             StartTime = DateTime.Now;
             StartTime = DateTime.Now;
             _regionManager.RequestNavigate("MainRegionContext", "HomeView");
             _regionManager.RequestNavigate("MainRegionContext", "HomeView");

+ 3 - 3
TeamAAS-VM/Views/HomeView.xaml

@@ -407,7 +407,7 @@ VerticalAlignment="Center">
               Value="CharacterEllipsis" />
               Value="CharacterEllipsis" />
                                 </Style>
                                 </Style>
                             </Grid.Resources>
                             </Grid.Resources>
-                            <TextBlock Text="抛料数:"
+                            <TextBlock Text="{lex:Loc 抛料数}"
          HorizontalAlignment="Right"
          HorizontalAlignment="Right"
          TextAlignment="Right" />
          TextAlignment="Right" />
                             <Border Grid.Row="0"
                             <Border Grid.Row="0"
@@ -420,7 +420,7 @@ VerticalAlignment="Center">
          Text="{Binding management.ThrowNumber}" />
          Text="{Binding management.ThrowNumber}" />
                             <TextBlock Grid.Row="1"
                             <TextBlock Grid.Row="1"
          Grid.Column="0"
          Grid.Column="0"
-         Text="NG数量:"
+         Text="{lex:Loc NG数量}"
          HorizontalAlignment="Right"
          HorizontalAlignment="Right"
          TextAlignment="Right" />
          TextAlignment="Right" />
                             <Border Grid.Row="1"
                             <Border Grid.Row="1"
@@ -433,7 +433,7 @@ VerticalAlignment="Center">
          Text="{Binding management.NgNumber}" />
          Text="{Binding management.NgNumber}" />
                             <TextBlock Grid.Row="2"
                             <TextBlock Grid.Row="2"
          Grid.Column="0"
          Grid.Column="0"
-         Text="良率:"
+         Text="{lex:Loc 良率}"
          HorizontalAlignment="Right"
          HorizontalAlignment="Right"
          TextAlignment="Right" />
          TextAlignment="Right" />
                             <Border Grid.Row="2"
                             <Border Grid.Row="2"

+ 370 - 155
TeamAAS-VM/Views/MainWindowView.xaml

@@ -1,26 +1,28 @@
-<Window x:Class="TeamAAS_VP.Views.MainWindowView"
-        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
-        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
-        xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
-        xmlns:prism="http://prismlibrary.com/"
-        xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
-        xmlns:vm="clr-namespace:TeamAAS_VP.ViewModels"
-        xmlns:local="clr-namespace:TeamAAS_VP"
-        xmlns:converter="clr-namespace:TeamAAS_VP.ValueConverter"
-        xmlns:lex="http://wpflocalizeextension.codeplex.com"
-        lex:LocalizeDictionary.DesignCulture="zh-CN"
-        lex:ResxLocalizationProvider.DefaultAssembly="TeamAAS-VP"
-        lex:ResxLocalizationProvider.DefaultDictionary="Lang"
-        mc:Ignorable="d"
-        d:DataContext="{d:DesignInstance Type=vm:MainWindowViewModel}"
-        d:Height="768"
-        d:Width="1024"
-        WindowState="Maximized"
-        WindowStartupLocation="CenterScreen"
-        Closing="Window_Closing"
-        FontFamily="{DynamicResource DefaultFont}">
+<Window
+    x:Class="TeamAAS_VP.Views.MainWindowView"
+    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
+    xmlns:converter="clr-namespace:TeamAAS_VP.ValueConverter"
+    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+    xmlns:enums="clr-namespace:TeamAAS_VP.Enums"
+    xmlns:lex="http://wpflocalizeextension.codeplex.com"
+    xmlns:local="clr-namespace:TeamAAS_VP"
+    xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
+    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+    xmlns:prism="http://prismlibrary.com/"
+    xmlns:vm="clr-namespace:TeamAAS_VP.ViewModels"
+    d:DataContext="{d:DesignInstance Type=vm:MainWindowViewModel}"
+    d:Height="768"
+    d:Width="1024"
+    lex:LocalizeDictionary.DesignCulture="zh-CN"
+    lex:ResxLocalizationProvider.DefaultAssembly="TeamAAS-VP"
+    lex:ResxLocalizationProvider.DefaultDictionary="Lang"
+    Closing="Window_Closing"
+    FontFamily="{DynamicResource DefaultFont}"
+    WindowStartupLocation="CenterScreen"
+    WindowState="Maximized"
+    mc:Ignorable="d">
     <Window.Title>
     <Window.Title>
         <MultiBinding StringFormat=" {0} {1}">
         <MultiBinding StringFormat=" {0} {1}">
             <Binding Path="CompanyTitle" />
             <Binding Path="CompanyTitle" />
@@ -30,6 +32,56 @@
     <Window.Resources>
     <Window.Resources>
         <converter:NavigationStateConverter x:Key="_NavigationState" />
         <converter:NavigationStateConverter x:Key="_NavigationState" />
         <converter:NavigationStateConverter1 x:Key="_NavigationState1" />
         <converter:NavigationStateConverter1 x:Key="_NavigationState1" />
+        <!--  普通状态背景  -->
+        <SolidColorBrush x:Key="ModeNormalBrush" Color="White" />
+        <!--  生产模式背景  -->
+        <SolidColorBrush x:Key="ModeAutoBrush" Color="Green" />
+        <!--  调机模式背景  -->
+        <SolidColorBrush x:Key="ModeManualBrush" Color="Orange" />
+        <!--  流线模式背景  -->
+        <SolidColorBrush x:Key="ModeClearBrush" Color="Yellow" />
+        <!--  生产卡片样式  -->
+        <Style x:Key="AutoModeCardStyle" TargetType="materialDesign:Card">
+            <Setter Property="Background" Value="{StaticResource ModeNormalBrush}" />
+            <Setter Property="Margin" Value="6,0" />
+            <Setter Property="MinWidth" Value="64" />
+            <Setter Property="HorizontalAlignment" Value="Center" />
+            <Setter Property="VerticalAlignment" Value="Center" />
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding management.CurrentDisplayMode}" Value="{x:Static enums:RunDisplayMode.Auto}">
+                    <Setter Property="Background" Value="{StaticResource ModeAutoBrush}" />
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+
+        <!--  调机卡片样式  -->
+        <Style x:Key="ManualModeCardStyle" TargetType="materialDesign:Card">
+            <Setter Property="Background" Value="{StaticResource ModeNormalBrush}" />
+            <Setter Property="Margin" Value="6,0" />
+            <Setter Property="MinWidth" Value="64" />
+            <Setter Property="HorizontalAlignment" Value="Center" />
+            <Setter Property="VerticalAlignment" Value="Center" />
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding management.CurrentDisplayMode}" Value="{x:Static enums:RunDisplayMode.Manual}">
+                    <Setter Property="Background" Value="{StaticResource ModeManualBrush}" />
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+
+        <!--  流线卡片样式  -->
+        <Style x:Key="ClearModeCardStyle" TargetType="materialDesign:Card">
+            <Setter Property="Background" Value="{StaticResource ModeNormalBrush}" />
+            <Setter Property="Margin" Value="6,0" />
+            <Setter Property="MinWidth" Value="64" />
+            <Setter Property="HorizontalAlignment" Value="Center" />
+            <Setter Property="VerticalAlignment" Value="Center" />
+            <Style.Triggers>
+                <DataTrigger Binding="{Binding management.CurrentDisplayMode}" Value="{x:Static enums:RunDisplayMode.Clear}">
+                    <Setter Property="Background" Value="{StaticResource ModeClearBrush}" />
+                </DataTrigger>
+            </Style.Triggers>
+        </Style>
+
     </Window.Resources>
     </Window.Resources>
     <b:Interaction.Triggers>
     <b:Interaction.Triggers>
         <b:EventTrigger EventName="Loaded">
         <b:EventTrigger EventName="Loaded">
@@ -39,8 +91,7 @@
             <b:InvokeCommandAction Command="{Binding ClosedCommand}" />
             <b:InvokeCommandAction Command="{Binding ClosedCommand}" />
         </b:EventTrigger>
         </b:EventTrigger>
     </b:Interaction.Triggers>
     </b:Interaction.Triggers>
-    <materialDesign:DialogHost DialogTheme="Inherit"
-                               Identifier="RootDialog">
+    <materialDesign:DialogHost DialogTheme="Inherit" Identifier="RootDialog">
         <Grid>
         <Grid>
             <Grid.RowDefinitions>
             <Grid.RowDefinitions>
                 <RowDefinition Height="100" />
                 <RowDefinition Height="100" />
@@ -59,130 +110,292 @@
                     <ColumnDefinition Width="100" />
                     <ColumnDefinition Width="100" />
                     <ColumnDefinition Width="100" />
                     <ColumnDefinition Width="100" />
                 </Grid.ColumnDefinitions>
                 </Grid.ColumnDefinitions>
-                <Grid.Resources>
-
-                </Grid.Resources>
-                <Button Grid.Column="0"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 运行窗口}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=0}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Home">
-                    <materialDesign:PackIcon Kind="HomeOutline"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=0}" />
-                </Button>
-                <Button Grid.Column="1"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 产品管理}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=1}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Products">
-                    <materialDesign:PackIcon Kind="FileTableBoxOutline"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=1}" />
+                <Grid.Resources />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="0"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=0}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Home"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 运行窗口}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=0}"
+                            Kind="HomeOutline" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 运行窗口}" />
+                    </StackPanel>
                 </Button>
                 </Button>
-                <Button Grid.Column="2"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 调试}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=2}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Debug">
-                    <materialDesign:PackIcon Kind="WrenchOutline"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=2}" />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="1"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=1}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Products"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 产品管理}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=1}"
+                            Kind="FileTableBoxOutline" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 产品管理}" />
+                    </StackPanel>
                 </Button>
                 </Button>
-                <Button Grid.Column="3"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 设置}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=3}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Setting">
-                    <materialDesign:PackIcon Kind="Cog"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=3}" />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="2"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=2}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Debug"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 调试}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=2}"
+                            Kind="WrenchOutline" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 调试}" />
+                    </StackPanel>
                 </Button>
                 </Button>
-                <materialDesign:Card Grid.Column="4"
-                                     Margin="10"
-                                     Background="{Binding management.StatusBackground}"
-                                     UniformCornerRadius="15">
-                    <StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
-                        <TextBlock Text="{Binding MyTitle}"
-                                FontSize="{DynamicResource Font.Size.Title1}"
-                                HorizontalAlignment="Center"
-                                   Margin="280,0,0,0"
-                                VerticalAlignment="Center"
-                                FontWeight="Bold"/>
-                        <materialDesign:Card HorizontalAlignment="Center" VerticalAlignment="Center" Margin="50,10" Background="{Binding management.RunModelBackground}" >
-                            <TextBlock Text="{lex:Loc 生产}" FontSize="22" Margin="8" />
-                        </materialDesign:Card >
-                        <materialDesign:Card HorizontalAlignment="Center" VerticalAlignment="Center" Margin="20,10" Background="{Binding management.ManualModeBackground}" >
-                            <TextBlock Text="{lex:Loc 调机}" FontSize="22" Margin="8"/>
-                        </materialDesign:Card>
-                        <materialDesign:Card HorizontalAlignment="Center" VerticalAlignment="Center" Margin="50,10" Background="{Binding management.ClearModeBackground}" >
-                            <TextBlock Text="{lex:Loc 流线}" FontSize="22" Margin="8" />
-                        </materialDesign:Card>
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="3"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=3}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Setting"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 设置}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=3}"
+                            Kind="Cog" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 设置}" />
                     </StackPanel>
                     </StackPanel>
+                </Button>
+                <materialDesign:Card
+                    Grid.Row="1"
+                    Grid.Column="4"
+                    Margin="10"
+                    Background="White"
+                    UniformCornerRadius="15">
+                    <Grid Margin="12,8">
+                        <Grid.ColumnDefinitions>
+                            <ColumnDefinition Width="150" />
+                            <ColumnDefinition Width="*" />
+                            <ColumnDefinition Width="Auto" />
+                        </Grid.ColumnDefinitions>
+
+                        <Border
+                            Grid.Column="0"
+                            MinWidth="100"
+                            Padding="10,6"
+                            VerticalAlignment="Center"
+                            BorderBrush="#D6DDE8"
+                            BorderThickness="1"
+                            CornerRadius="8">
+                            <StackPanel Orientation="Vertical">
+                                <TextBlock
+                                    Margin="0,0,0,4"
+                                    FontSize="{DynamicResource Font.Size.Body3}"
+                                    FontWeight="SemiBold"
+                                    Text="{lex:Loc SettingView_Language_Text}" />
+                                <ComboBox
+                                    MinWidth="160"
+                                    FontSize="12"
+                                    SelectedValue="{Binding CurrentLanguage, Mode=TwoWay}"
+                                    SelectedValuePath="Tag">
+                                    <ComboBoxItem Content="{lex:Loc SettingView_Language_ChineseSimplified}" Tag="{x:Static enums:Language.ChineseSimplified}" />
+                                    <ComboBoxItem Content="{lex:Loc SettingView_Language_ChineseTraditional}" Tag="{x:Static enums:Language.ChineseTraditional}" />
+                                    <ComboBoxItem Content="{lex:Loc SettingView_Language_English}" Tag="{x:Static enums:Language.English}" />
+                                    <ComboBoxItem Content="{lex:Loc SettingView_Language_Japanese}" Tag="{x:Static enums:Language.Japanese}" />
+                                    <ComboBoxItem Content="{lex:Loc SettingView_Language_Vietnamese}" Tag="{x:Static enums:Language.Vietnamese}" />
+                                </ComboBox>
+                            </StackPanel>
+                        </Border>
+
+                        <TextBlock
+                            Grid.Column="1"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="{DynamicResource Font.Size.Title1}"
+                            FontWeight="Bold"
+                            Text="{Binding MyTitle}"
+                            TextAlignment="Center" />
+
+                        <StackPanel
+                            Grid.Column="2"
+                            HorizontalAlignment="Right"
+                            Orientation="Horizontal">
+                            <materialDesign:Card Margin="40,0" Style="{StaticResource AutoModeCardStyle}">
+                                <TextBlock
+                                    Margin="8"
+                                    FontSize="22"
+                                    Text="{lex:Loc 生产}" />
+                            </materialDesign:Card>
+
+                            <materialDesign:Card Margin="40,0" Style="{StaticResource ManualModeCardStyle}">
+                                <TextBlock
+                                    Margin="8"
+                                    FontSize="22"
+                                    Text="{lex:Loc 调试}" />
+                            </materialDesign:Card>
+
+                            <materialDesign:Card Margin="40,0" Style="{StaticResource ClearModeCardStyle}">
+                                <TextBlock
+                                    Margin="8"
+                                    FontSize="22"
+                                    Text="{lex:Loc 流线}" />
+                            </materialDesign:Card>
+                        </StackPanel>
+                    </Grid>
+
                 </materialDesign:Card>
                 </materialDesign:Card>
-                <Button Grid.Column="5"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 校准}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=5}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Calib">
-                    <materialDesign:PackIcon Kind="CrosshairsGps"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=5}" />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="5"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=5}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Calib"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 校准}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=5}"
+                            Kind="CrosshairsGps" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 校准}" />
+                    </StackPanel>
                 </Button>
                 </Button>
-                <Button Grid.Column="6"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 统计}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=6}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="Statistics">
-                    <materialDesign:PackIcon Kind="ChartBellCurveCumulative"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=6}" />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="6"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=6}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="Statistics"
+                    Cursor="Hand"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 统计}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=6}"
+                            Kind="ChartBellCurveCumulative" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 统计}" />
+                    </StackPanel>
                 </Button>
                 </Button>
-                <Button Grid.Column="7"
-                        Style="{StaticResource MaterialDesignIconButton}"
-                        ToolTip="{lex:Loc 用户}"
-                        Width="90"
-                        Height="90"
-                        Background="{Binding NavigationIndex,Converter={StaticResource _NavigationState},ConverterParameter=7}"
-                        Command="{Binding NavigationCommand}"
-                        CommandParameter="User">
-                    <materialDesign:PackIcon Kind="AccountMultipleOutline"
-                                             Width="70"
-                                             Height="70"
-                                             Foreground="{Binding NavigationIndex,Converter={StaticResource _NavigationState1},ConverterParameter=7}" />
+                <Button
+                    Grid.Row="1"
+                    Grid.Column="7"
+                    Width="90"
+                    Height="90"
+                    Background="{Binding NavigationIndex, Converter={StaticResource _NavigationState}, ConverterParameter=7}"
+                    Command="{Binding NavigationCommand}"
+                    CommandParameter="User"
+                    Style="{StaticResource MaterialDesignIconButton}"
+                    ToolTip="{lex:Loc 用户}">
+                    <StackPanel
+                        HorizontalAlignment="Center"
+                        VerticalAlignment="Center"
+                        Orientation="Vertical">
+                        <materialDesign:PackIcon
+                            Width="50"
+                            Height="50"
+                            Foreground="{Binding NavigationIndex, Converter={StaticResource _NavigationState1}, ConverterParameter=7}"
+                            Kind="AccountMultipleOutline" />
+                        <TextBlock
+                            Margin="0,0,0,5"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="12"
+                            Foreground="Black"
+                            Text="{lex:Loc 用户}" />
+                    </StackPanel>
+
                 </Button>
                 </Button>
             </Grid>
             </Grid>
 
 
-            <ContentControl Grid.Row="1"
-                            prism:RegionManager.RegionName="MainRegionContext" />
-            <!--状态栏-->
-            <StatusBar x:Name="status"
-                       Grid.Row="2">
-                <ItemsControl ItemsSource="{Binding Status}" HorizontalAlignment="Left" VerticalAlignment="Center">
+            <ContentControl Grid.Row="1" prism:RegionManager.RegionName="MainRegionContext" />
+            <!--  状态栏  -->
+            <StatusBar x:Name="status" Grid.Row="2">
+                <ItemsControl
+                    HorizontalAlignment="Left"
+                    VerticalAlignment="Center"
+                    ItemsSource="{Binding Status}">
                     <ItemsControl.ItemsPanel>
                     <ItemsControl.ItemsPanel>
                         <ItemsPanelTemplate>
                         <ItemsPanelTemplate>
                             <VirtualizingStackPanel Orientation="Horizontal" />
                             <VirtualizingStackPanel Orientation="Horizontal" />
@@ -190,26 +403,28 @@
                     </ItemsControl.ItemsPanel>
                     </ItemsControl.ItemsPanel>
                     <ItemsControl.ItemTemplate>
                     <ItemsControl.ItemTemplate>
                         <DataTemplate>
                         <DataTemplate>
-                            <TextBlock Text="{Binding Message,Mode=TwoWay}"
-                                       MinWidth="40"
-                                       Foreground="Black"
-                                       Background="{Binding Background,Mode=TwoWay}"
-                                       Margin="4,0"
-                                       VerticalAlignment="Center"
-                                       FontSize="{DynamicResource Font.Size. Font.Size.Captions4}"
-                                       Opacity="0.7"/>
-                            
+                            <TextBlock
+                                MinWidth="40"
+                                Margin="4,0"
+                                VerticalAlignment="Center"
+                                Background="{Binding Background, Mode=TwoWay}"
+                                FontSize="{DynamicResource Font.Size. Font.Size.Captions4}"
+                                Foreground="Black"
+                                Opacity="0.7"
+                                Text="{Binding Message, Mode=TwoWay}" />
+
                         </DataTemplate>
                         </DataTemplate>
                     </ItemsControl.ItemTemplate>
                     </ItemsControl.ItemTemplate>
                 </ItemsControl>
                 </ItemsControl>
             </StatusBar>
             </StatusBar>
-            <materialDesign:Snackbar Grid.Row="1"
-                                     x:Name="SnackbarSeven"
-                                     Opacity="0.8"
-                                     HorizontalContentAlignment="Center"
-                                     FontSize="{DynamicResource Font.Size.Body1}"
-                                     MessageQueue="{materialDesign:MessageQueue}"
-                                     VerticalAlignment="Bottom" />
+            <materialDesign:Snackbar
+                x:Name="SnackbarSeven"
+                Grid.Row="1"
+                VerticalAlignment="Bottom"
+                HorizontalContentAlignment="Center"
+                FontSize="{DynamicResource Font.Size.Body1}"
+                MessageQueue="{materialDesign:MessageQueue}"
+                Opacity="0.8" />
         </Grid>
         </Grid>
     </materialDesign:DialogHost>
     </materialDesign:DialogHost>
 
 

+ 17 - 17
TeamAAS-VM/Views/SettingView.xaml

@@ -264,7 +264,7 @@
                     <TreeView Grid.Row="1"
                     <TreeView Grid.Row="1"
                               Grid.Column="0"
                               Grid.Column="0"
                               SelectedItemChanged="TreeView_SelectedItemChanged">
                               SelectedItemChanged="TreeView_SelectedItemChanged">
-                        <TreeViewItem Header="设备列表"
+                        <TreeViewItem Header="{lex:Loc 设备列表}"
                                       FontSize="{DynamicResource Font.Size.Title4}"
                                       FontSize="{DynamicResource Font.Size.Title4}"
                                       FontWeight="Bold"
                                       FontWeight="Bold"
                                       IsExpanded="True"
                                       IsExpanded="True"
@@ -365,7 +365,7 @@
 
 
                                 <TextBlock Grid.Row="0"
                                 <TextBlock Grid.Row="0"
                                            Grid.Column="0"
                                            Grid.Column="0"
-                                           Text="设备编号:"
+                                           Text="{lex:Loc 设备编号}"
                                            HorizontalAlignment="Right"
                                            HorizontalAlignment="Right"
                                            VerticalAlignment="Center" />
                                            VerticalAlignment="Center" />
                                 <TextBlock Grid.Row="0"
                                 <TextBlock Grid.Row="0"
@@ -376,7 +376,7 @@
 
 
                                 <TextBlock Grid.Row="1"
                                 <TextBlock Grid.Row="1"
                                            Grid.Column="0"
                                            Grid.Column="0"
-                                           Text="设备名称:"
+                                           Text="{lex:Loc 设备名称}"
                                            HorizontalAlignment="Right"
                                            HorizontalAlignment="Right"
                                            VerticalAlignment="Center" />
                                            VerticalAlignment="Center" />
                                 <TextBox Grid.Row="1"
                                 <TextBox Grid.Row="1"
@@ -386,7 +386,7 @@
 
 
                                 <TextBlock Grid.Row="2"
                                 <TextBlock Grid.Row="2"
                                            Grid.Column="0"
                                            Grid.Column="0"
-                                           Text="设备描述:"
+                                           Text="{lex:Loc 设备描述}"
                                            HorizontalAlignment="Right"
                                            HorizontalAlignment="Right"
                                            VerticalAlignment="Center" />
                                            VerticalAlignment="Center" />
                                 <TextBox Grid.Row="2"
                                 <TextBox Grid.Row="2"
@@ -476,7 +476,7 @@
 
 
                                 <TextBlock Grid.Row="11"
                                 <TextBlock Grid.Row="11"
                                            Grid.Column="0"
                                            Grid.Column="0"
-                                           Text="启用 MES:"
+                                           Text="{lex:Loc 启用 MES}"
                                            HorizontalAlignment="Right"
                                            HorizontalAlignment="Right"
                                            VerticalAlignment="Center" />
                                            VerticalAlignment="Center" />
                                 <CheckBox Grid.Row="11"
                                 <CheckBox Grid.Row="11"
@@ -486,14 +486,14 @@
                                           Margin="6,2" />
                                           Margin="6,2" />
                                 <CheckBox Grid.Row="12"
                                 <CheckBox Grid.Row="12"
                                           Grid.Column="1"
                                           Grid.Column="1"
-                                          Content="是否启用两次产品编号"
+                                          Content="{lex:Loc 是否启用两次产品编号}"
                                           IsChecked="{Binding SelectDeviceInfo.EnableDoubleMes, Mode=TwoWay}"
                                           IsChecked="{Binding SelectDeviceInfo.EnableDoubleMes, Mode=TwoWay}"
                                           Command="{Binding CheckStatusCommand}"
                                           Command="{Binding CheckStatusCommand}"
                                           Margin="6,2" />
                                           Margin="6,2" />
                                 <StackPanel Grid.Row="13"
                                 <StackPanel Grid.Row="13"
                                             Grid.Column="1"
                                             Grid.Column="1"
                                             Orientation="Horizontal">
                                             Orientation="Horizontal">
-                                    <CheckBox Content="是否保存CSV文件"
+                                    <CheckBox Content="{lex:Loc 是否保存CSV文件}"
                                               IsChecked="{Binding SelectDeviceInfo.SaveCsv, Mode=TwoWay}"
                                               IsChecked="{Binding SelectDeviceInfo.SaveCsv, Mode=TwoWay}"
                                               Command="{Binding CheckStatusCommand}"
                                               Command="{Binding CheckStatusCommand}"
                                               Margin="6,2" />
                                               Margin="6,2" />
@@ -504,7 +504,7 @@
                                 
                                 
                                 <TextBlock Grid.Row="14"
                                 <TextBlock Grid.Row="14"
                                            Grid.Column="0"
                                            Grid.Column="0"
-                                           Text="保存的CSV文件路径:"
+                                           Text="{lex:Loc 保存的CSV文件路径}"
                                            HorizontalAlignment="Right"
                                            HorizontalAlignment="Right"
                                            VerticalAlignment="Center" />
                                            VerticalAlignment="Center" />
                                 <DockPanel HorizontalAlignment="Stretch"
                                 <DockPanel HorizontalAlignment="Stretch"
@@ -2903,7 +2903,7 @@
                                                  Kind="BallotOutline" />
                                                  Kind="BallotOutline" />
                         <TextBlock Style="{StaticResource TabHeaderTextBlockStyle}"
                         <TextBlock Style="{StaticResource TabHeaderTextBlockStyle}"
                                    FontSize="{DynamicResource Font.Size.Body2}"
                                    FontSize="{DynamicResource Font.Size.Body2}"
-                                   Text="产品信息"
+                                   Text="{lex:Loc 产品信息}"
                                    HorizontalAlignment="Stretch" />
                                    HorizontalAlignment="Stretch" />
                     </StackPanel>
                     </StackPanel>
                 </TabItem.Header>
                 </TabItem.Header>
@@ -2912,7 +2912,7 @@
 
 
                     <GroupBox HorizontalAlignment="Left"
                     <GroupBox HorizontalAlignment="Left"
                               Margin="10,5"
                               Margin="10,5"
-                              Header="产品与mes参数绑定设置"
+                              Header="{lex:Loc 产品与mes参数绑定设置}"
                               Width="400"
                               Width="400"
                               FontSize="{DynamicResource Font.Size.Title4}">
                               FontSize="{DynamicResource Font.Size.Title4}">
                         <Grid Margin="20">
                         <Grid Margin="20">
@@ -2929,7 +2929,7 @@
                             </Grid.RowDefinitions>
                             </Grid.RowDefinitions>
 
 
                             <TextBlock Margin="0,0,0,8"
                             <TextBlock Margin="0,0,0,8"
-                                       Text="产品名称:"
+                                       Text="{lex:Loc 产品名称}"
                                        VerticalAlignment="Center"
                                        VerticalAlignment="Center"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        HorizontalAlignment="Right" />
                                        HorizontalAlignment="Right" />
@@ -2962,7 +2962,7 @@
                             </ComboBox>
                             </ComboBox>
                             <TextBlock Margin="0,0,0,8"
                             <TextBlock Margin="0,0,0,8"
                                        Grid.Row="1"
                                        Grid.Row="1"
-                                       Text="产品编码(model):"
+                                       Text="{lex:Loc 产品编码}"
                                        VerticalAlignment="Center"
                                        VerticalAlignment="Center"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        HorizontalAlignment="Right" />
                                        HorizontalAlignment="Right" />
@@ -2984,7 +2984,7 @@
                             <TextBlock Margin="0,0,0,8"
                             <TextBlock Margin="0,0,0,8"
                                        Grid.Row="2"
                                        Grid.Row="2"
                                        VerticalAlignment="Center"
                                        VerticalAlignment="Center"
-                                       Text="产品颜色:"
+                                       Text="{lex:Loc 产品颜色}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        HorizontalAlignment="Right" />
                                        HorizontalAlignment="Right" />
                             <TextBox Grid.Row="2"
                             <TextBox Grid.Row="2"
@@ -3005,7 +3005,7 @@
                             <TextBlock Margin="0,0,0,8"
                             <TextBlock Margin="0,0,0,8"
                                        Grid.Row="3"
                                        Grid.Row="3"
                                        VerticalAlignment="Center"
                                        VerticalAlignment="Center"
-                                       Text="产品类型:"
+                                       Text="{lex:Loc 产品类型}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        FontSize="{DynamicResource Font.Size.Body3}"
                                        HorizontalAlignment="Right" />
                                        HorizontalAlignment="Right" />
                             <TextBox Grid.Row="3"
                             <TextBox Grid.Row="3"
@@ -3038,7 +3038,7 @@
                                         <materialDesign:PackIcon Kind="PuzzleEditOutline"
                                         <materialDesign:PackIcon Kind="PuzzleEditOutline"
                                                                  Margin="0,0,6,0" />
                                                                  Margin="0,0,6,0" />
                                         <TextBlock VerticalAlignment="Center"
                                         <TextBlock VerticalAlignment="Center"
-                                                   Text="获取" />
+                                                   Text="{lex:Loc 获取}" />
                                     </StackPanel>
                                     </StackPanel>
                                 </Button>
                                 </Button>
                                 <Button Margin="5"
                                 <Button Margin="5"
@@ -3051,7 +3051,7 @@
                                         <materialDesign:PackIcon Kind="DeleteForeverOutline"
                                         <materialDesign:PackIcon Kind="DeleteForeverOutline"
                                                                  Margin="0,0,6,0" />
                                                                  Margin="0,0,6,0" />
                                         <TextBlock VerticalAlignment="Center"
                                         <TextBlock VerticalAlignment="Center"
-                                                   Text="删除" />
+                                                   Text="{lex:Loc 删除}" />
                                     </StackPanel>
                                     </StackPanel>
                                 </Button>
                                 </Button>
                                 <Button Margin="5"
                                 <Button Margin="5"
@@ -3064,7 +3064,7 @@
                                         <materialDesign:PackIcon Kind="ContentSaveCheck"
                                         <materialDesign:PackIcon Kind="ContentSaveCheck"
                                                                  Margin="0,0,6,0" />
                                                                  Margin="0,0,6,0" />
                                         <TextBlock VerticalAlignment="Center"
                                         <TextBlock VerticalAlignment="Center"
-                                                   Text="保存" />
+                                                   Text="{lex:Loc 保存}" />
                                     </StackPanel>
                                     </StackPanel>
                                 </Button>
                                 </Button>
                             </StackPanel>
                             </StackPanel>