From c6a86ccf5e4b5beb982c72ff86f84ddb50515603 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=AD=E6=98=8E=E9=94=8B?= Date: Thu, 15 Apr 2021 12:28:12 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=B1=9E=E6=80=A7=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E7=9A=84=E5=88=97=E5=AE=BD=E5=BA=A6=E5=8F=AF=E5=8F=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/Entities/EntityListViewModel.cs | 3 ++ .../Views/Modules/ModuleListView.xaml | 4 +- .../Views/Modules/ModuleListViewModel.cs | 3 ++ .../Projects/ProjectTemplateListViewModel.cs | 3 ++ .../Views/Projects/ProjectViewModel.cs | 3 ++ .../Views/Properties/PropertyListView.xaml | 40 +++++++++---------- .../Views/Properties/PropertyListViewModel.cs | 3 ++ 7 files changed, 37 insertions(+), 22 deletions(-) diff --git a/src/OSharp.CodeGenerator/Views/Entities/EntityListViewModel.cs b/src/OSharp.CodeGenerator/Views/Entities/EntityListViewModel.cs index 6b57e6a..87aa3a1 100644 --- a/src/OSharp.CodeGenerator/Views/Entities/EntityListViewModel.cs +++ b/src/OSharp.CodeGenerator/Views/Entities/EntityListViewModel.cs @@ -26,6 +26,8 @@ using OSharp.Exceptions; using OSharp.Mapping; using OSharp.Wpf.Stylet; +using PropertyChanged; + using Stylet; @@ -120,6 +122,7 @@ namespace OSharp.CodeGenerator.Views.Entities /// Called whenever the error state of any properties changes. Calls NotifyOfPropertyChange("HasErrors") by default /// /// List of property names which have changed validation state + [SuppressPropertyChangedWarnings] protected override void OnValidationStateChanged(IEnumerable changedProperties) { base.OnValidationStateChanged(changedProperties); diff --git a/src/OSharp.CodeGenerator/Views/Modules/ModuleListView.xaml b/src/OSharp.CodeGenerator/Views/Modules/ModuleListView.xaml index 7a92fba..cc703fd 100644 --- a/src/OSharp.CodeGenerator/Views/Modules/ModuleListView.xaml +++ b/src/OSharp.CodeGenerator/Views/Modules/ModuleListView.xaml @@ -50,9 +50,9 @@ - - + + diff --git a/src/OSharp.CodeGenerator/Views/Modules/ModuleListViewModel.cs b/src/OSharp.CodeGenerator/Views/Modules/ModuleListViewModel.cs index 685e106..8ebea0e 100644 --- a/src/OSharp.CodeGenerator/Views/Modules/ModuleListViewModel.cs +++ b/src/OSharp.CodeGenerator/Views/Modules/ModuleListViewModel.cs @@ -25,6 +25,8 @@ using OSharp.Data; using OSharp.Mapping; using OSharp.Wpf.Stylet; +using PropertyChanged; + using Stylet; @@ -119,6 +121,7 @@ namespace OSharp.CodeGenerator.Views.Modules /// Called whenever the error state of any properties changes. Calls NotifyOfPropertyChange("HasErrors") by default /// /// List of property names which have changed validation state + [SuppressPropertyChangedWarnings] protected override void OnValidationStateChanged(IEnumerable changedProperties) { base.OnValidationStateChanged(changedProperties); diff --git a/src/OSharp.CodeGenerator/Views/Projects/ProjectTemplateListViewModel.cs b/src/OSharp.CodeGenerator/Views/Projects/ProjectTemplateListViewModel.cs index 85795cb..1021c5b 100644 --- a/src/OSharp.CodeGenerator/Views/Projects/ProjectTemplateListViewModel.cs +++ b/src/OSharp.CodeGenerator/Views/Projects/ProjectTemplateListViewModel.cs @@ -25,6 +25,8 @@ using OSharp.Data; using OSharp.Mapping; using OSharp.Wpf.Stylet; +using PropertyChanged; + using Stylet; @@ -134,6 +136,7 @@ namespace OSharp.CodeGenerator.Views.Projects /// Called whenever the error state of any properties changes. Calls NotifyOfPropertyChange("HasErrors") by default /// /// List of property names which have changed validation state + [SuppressPropertyChangedWarnings] protected override void OnValidationStateChanged(IEnumerable changedProperties) { base.OnValidationStateChanged(changedProperties); diff --git a/src/OSharp.CodeGenerator/Views/Projects/ProjectViewModel.cs b/src/OSharp.CodeGenerator/Views/Projects/ProjectViewModel.cs index 608dac0..0ebc226 100644 --- a/src/OSharp.CodeGenerator/Views/Projects/ProjectViewModel.cs +++ b/src/OSharp.CodeGenerator/Views/Projects/ProjectViewModel.cs @@ -28,6 +28,8 @@ using OSharp.Extensions; using OSharp.Mapping; using OSharp.Wpf.Stylet; +using PropertyChanged; + using Stylet; using MessageBox = System.Windows.MessageBox; @@ -168,6 +170,7 @@ namespace OSharp.CodeGenerator.Views.Projects /// Called whenever the error state of any properties changes. Calls NotifyOfPropertyChange("HasErrors") by default /// /// List of property names which have changed validation state + [SuppressPropertyChangedWarnings] protected override void OnValidationStateChanged(IEnumerable changedProperties) { base.OnValidationStateChanged(changedProperties); diff --git a/src/OSharp.CodeGenerator/Views/Properties/PropertyListView.xaml b/src/OSharp.CodeGenerator/Views/Properties/PropertyListView.xaml index cfea483..2e5b5b0 100644 --- a/src/OSharp.CodeGenerator/Views/Properties/PropertyListView.xaml +++ b/src/OSharp.CodeGenerator/Views/Properties/PropertyListView.xaml @@ -46,12 +46,12 @@ - - + @@ -63,12 +63,12 @@ - - - - - - + + + + + + @@ -80,7 +80,7 @@ - + @@ -92,10 +92,10 @@ - - - - + + + + @@ -107,7 +107,7 @@ - + @@ -119,12 +119,12 @@ - - - - - - + + + + + + diff --git a/src/OSharp.CodeGenerator/Views/Properties/PropertyListViewModel.cs b/src/OSharp.CodeGenerator/Views/Properties/PropertyListViewModel.cs index 7de8bc5..102c66c 100644 --- a/src/OSharp.CodeGenerator/Views/Properties/PropertyListViewModel.cs +++ b/src/OSharp.CodeGenerator/Views/Properties/PropertyListViewModel.cs @@ -26,6 +26,8 @@ using OSharp.Exceptions; using OSharp.Mapping; using OSharp.Wpf.Stylet; +using PropertyChanged; + using Stylet; @@ -121,6 +123,7 @@ namespace OSharp.CodeGenerator.Views.Properties /// Called whenever the error state of any properties changes. Calls NotifyOfPropertyChange("HasErrors") by default /// /// List of property names which have changed validation state + [SuppressPropertyChangedWarnings] protected override void OnValidationStateChanged(IEnumerable changedProperties) { base.OnValidationStateChanged(changedProperties); -- Gitee From d5e255ca9b9b7fcd3e1c09ee3cfc7c016667056b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=AD=E6=98=8E=E9=94=8B?= Date: Thu, 15 Apr 2021 12:43:59 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=8F=9C=E5=8D=95?= =?UTF-8?q?=E6=A0=91=E6=8E=92=E5=BA=8F=E4=B8=8D=E6=AD=A3=E7=A1=AE=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Services/DataService.CodeProject.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/OSharp.CodeGeneration/Services/DataService.CodeProject.cs b/src/OSharp.CodeGeneration/Services/DataService.CodeProject.cs index f48942b..1ac3e59 100644 --- a/src/OSharp.CodeGeneration/Services/DataService.CodeProject.cs +++ b/src/OSharp.CodeGeneration/Services/DataService.CodeProject.cs @@ -45,11 +45,14 @@ namespace OSharp.CodeGeneration.Services projects = json.FromJsonString(); foreach (CodeProject project in projects) { - foreach (CodeModule module in project.Modules.OrderBy(m => m.Order)) + project.Modules = project.Modules.OrderBy(m => m.Order).ToList(); + foreach (CodeModule module in project.Modules) { - foreach (CodeEntity entity in module.Entities.OrderBy(m => m.Order)) + module.Entities = module.Entities.OrderBy(m => m.Order).ToList(); + foreach (CodeEntity entity in module.Entities) { - foreach (CodeProperty property in entity.Properties.OrderBy(m => m.Order)) + entity.Properties = entity.Properties.OrderBy(m => m.Order).ToList(); + foreach (CodeProperty property in entity.Properties) { property.Entity = entity; } -- Gitee From 96d19764ece6548eea5b7f96430cbb2c781224f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=AD=E6=98=8E=E9=94=8B?= Date: Thu, 15 Apr 2021 16:41:02 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=8F=91=E5=B8=83=E6=96=B0=E7=89=88?= =?UTF-8?q?=E6=9C=ACv5.0.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build/version.props | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/build/version.props b/build/version.props index 3bb7a5d..e787876 100644 --- a/build/version.props +++ b/build/version.props @@ -3,9 +3,9 @@ 5.0 5 -preview. - 414 - $(VersionMain).$(VersionPrefix)$(VersionSuffix)$(VersionSuffixVersion) - + 415 + + $(VersionMain).$(VersionPrefix) $(VersionMain).$(VersionPrefix) $(VersionMain).$(VersionPrefix).$(VersionSuffixVersion) -- Gitee