| 
															
																@@ -8,6 +8,7 @@ using System.Windows.Controls; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 using System.Windows.Input; 
															 | 
															
															 | 
															
																 using System.Windows.Input; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 using Aitex.Core.RT.SCCore; 
															 | 
															
															 | 
															
																 using Aitex.Core.RT.SCCore; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 using Aitex.Core.UI.MVVM; 
															 | 
															
															 | 
															
																 using Aitex.Core.UI.MVVM; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+using Aitex.Sorter.Common; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																 namespace MECF.Framework.RT.Core.Backend 
															 | 
															
															 | 
															
																 namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 { 
															 | 
															
															 | 
															
																 { 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -59,7 +60,7 @@ namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																     public class BackendSCConfigViewModel : ViewModelBase 
															 | 
															
															 | 
															
																     public class BackendSCConfigViewModel : ViewModelBase 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     { 
															 | 
															
															 | 
															
																     { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-        private List<SCConfigItem> _scItems; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        public List<SCConfigItem> _scItems; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																         public ObservableCollection<NotifiableSCConfigItem> ScItemList { get; set; } 
															 | 
															
															 | 
															
																         public ObservableCollection<NotifiableSCConfigItem> ScItemList { get; set; } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -71,6 +72,11 @@ namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             Init(); 
															 | 
															
															 | 
															
																             Init(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             SetScCommand = new DelegateCommand<string>(SetSc); 
															 | 
															
															 | 
															
																             SetScCommand = new DelegateCommand<string>(SetSc); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             ReloadCommand = new DelegateCommand<string>(Reload); 
															 | 
															
															 | 
															
																             ReloadCommand = new DelegateCommand<string>(Reload); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            _scItems = SC.GetItemList(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            ScItemList = new ObservableCollection<NotifiableSCConfigItem>(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //partLoad("System"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         } 
															 | 
															
															 | 
															
																         } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																         private void SetSc(string obj) 
															 | 
															
															 | 
															
																         private void SetSc(string obj) 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -91,26 +97,33 @@ namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																         public void Reload(string obj) 
															 | 
															
															 | 
															
																         public void Reload(string obj) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         { 
															 | 
															
															 | 
															
																         { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            foreach (var item in ScItemList) 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                item.BoolValue = SC.GetConfigItem(item.PathName).BoolValue; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                item.IntValue = SC.GetConfigItem(item.PathName).IntValue; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                item.StringValue = SC.GetConfigItem(item.PathName).StringValue; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                item.DoubleValue = SC.GetConfigItem(item.PathName).DoubleValue; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                item.InvokePropertyChanged(nameof(item.Value)); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //foreach (var item in ScItemList) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //{ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //    item.BoolValue = SC.GetConfigItem(item.PathName).BoolValue; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //    item.IntValue = SC.GetConfigItem(item.PathName).IntValue; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //    item.StringValue = SC.GetConfigItem(item.PathName).StringValue; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //    item.DoubleValue = SC.GetConfigItem(item.PathName).DoubleValue; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //    item.InvokePropertyChanged(nameof(item.Value)); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            //} 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         } 
															 | 
															
															 | 
															
																         } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																         void Init() 
															 | 
															
															 | 
															
																         void Init() 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         { 
															 | 
															
															 | 
															
																         { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-            if (_scItems != null) return; 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        public void partLoad(string module) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            if (_scItems == null) return; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             { 
															 | 
															
															 | 
															
																             { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                _scItems = SC.GetItemList(); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-                ScItemList = new ObservableCollection<NotifiableSCConfigItem>(); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                ScItemList.Clear();  
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 int i = 0; 
															 | 
															
															 | 
															
																                 int i = 0; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 foreach (var scItem in _scItems) 
															 | 
															
															 | 
															
																                 foreach (var scItem in _scItems) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 { 
															 | 
															
															 | 
															
																                 { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     i++; 
															 | 
															
															 | 
															
																                     i++; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                    if (scItem.Path.Split('.')[0] != module) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                    { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                        continue; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                    } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     ScItemList.Add(new NotifiableSCConfigItem() 
															 | 
															
															 | 
															
																                     ScItemList.Add(new NotifiableSCConfigItem() 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                     { 
															 | 
															
															 | 
															
																                     { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                         BoolValue = scItem.BoolValue, 
															 | 
															
															 | 
															
																                         BoolValue = scItem.BoolValue, 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -147,6 +160,7 @@ namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             this.Loaded += SCConfigView_Loaded; 
															 | 
															
															 | 
															
																             this.Loaded += SCConfigView_Loaded; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																             this.IsVisibleChanged += BackendSCConfigView_IsVisibleChanged; 
															 | 
															
															 | 
															
																             this.IsVisibleChanged += BackendSCConfigView_IsVisibleChanged; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+             
															 | 
														
													
												
													
														
															| 
															 | 
															
																         } 
															 | 
															
															 | 
															
																         } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																  
															 | 
															
															 | 
															
																  
															 | 
														
													
												
													
														
															| 
															 | 
															
																         private void BackendSCConfigView_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e) 
															 | 
															
															 | 
															
																         private void BackendSCConfigView_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e) 
															 | 
														
													
												
											
												
													
														
															 | 
															
																@@ -164,7 +178,35 @@ namespace MECF.Framework.RT.Core.Backend 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             { 
															 | 
															
															 | 
															
																             { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                 DataContext = new BackendSCConfigViewModel(); 
															 | 
															
															 | 
															
																                 DataContext = new BackendSCConfigViewModel(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																             } 
															 | 
															
															 | 
															
																             } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            List<string> modules = new List<string>(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            foreach (var item in (this.DataContext as BackendSCConfigViewModel)._scItems) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                modules.Add(item.Path.Split('.')[0]); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            modules=modules.Distinct().ToList(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            int i = 0; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            modules.ForEach(module =>  
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                RadioButton radioButton = new RadioButton(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                sp1.Children.Add( 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                   radioButton=new RadioButton() { Content = module ,Margin=new Thickness(10,0,0,0),FontSize=15} 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                   ); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                radioButton.Checked += RadioButton_Checked; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                if (i == 0) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                    radioButton.IsChecked = true; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                    i++; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+                } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            }); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        private void RadioButton_Checked(object sender, RoutedEventArgs e) 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+        { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+            (this.DataContext as BackendSCConfigViewModel).partLoad(((sender as RadioButton).Content.ToString())); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																+ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																         } 
															 | 
															
															 | 
															
																         } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																-  
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																     } 
															 | 
															
															 | 
															
																     } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 } 
															 | 
															
															 | 
															
																 } 
															 |