From c01e95377d93781e156ea265c2a7ba38fd4902ba Mon Sep 17 00:00:00 2001 From: "boxu.zheng" Date: Wed, 14 Jun 2023 17:52:00 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E9=94=AE=E5=80=BC=E5=AF=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DictCityAdress/DictCityAdress.cs | 11 --------- .../AppBusiness/TestSchool/TestSchool.cs | 24 ------------------- .../TestSchool/TestStudentDetail.cs | 16 ------------- 3 files changed, 51 deletions(-) delete mode 100644 Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/DictCityAdress/DictCityAdress.cs diff --git a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/DictCityAdress/DictCityAdress.cs b/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/DictCityAdress/DictCityAdress.cs deleted file mode 100644 index dcc8257..0000000 --- a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/DictCityAdress/DictCityAdress.cs +++ /dev/null @@ -1,11 +0,0 @@ -using Microsoft.EntityFrameworkCore; - -namespace Faster.Zheng.Winin.AppBusiness.DictCityAdress -{ - [Owned] //值对象特性 - public class DictCityAdress - { - public string City { get; set; } - public string Street { get; set; } - } -} diff --git a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestSchool.cs b/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestSchool.cs index a12e2f6..920d1c3 100644 --- a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestSchool.cs +++ b/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestSchool.cs @@ -15,29 +15,5 @@ public class TestSchool : AuditedAggregateRoot public SchoolType OrderType { get; set; } - /// - /// 键值对的属性 需要添加非空 否则会有警告 但不影响使用 - /// - [Required] - public DictCityAdress.DictCityAdress CityAdress { get; set; } - public List Details { get; set; } = new(); - - protected TestSchool() - { - } - - public TestSchool( - Guid id, - string schoolName, - SchoolType orderType, - DictCityAdress.DictCityAdress cityAdress, - List details - ) : base(id) - { - SchoolName = schoolName; - OrderType = orderType; - CityAdress = cityAdress; - Details = details; - } } diff --git a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestStudentDetail.cs b/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestStudentDetail.cs index 2691a6a..ff575c8 100644 --- a/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestStudentDetail.cs +++ b/Code/Be/Faster.Zheng.Winin/src/Faster.Zheng.Winin.Domain/AppBusiness/TestSchool/TestStudentDetail.cs @@ -14,20 +14,4 @@ public class TestStudentDetail : AuditedAggregateRoot public string StudentName { get; set; } public StudentType OrderType { get; set; } - - protected TestStudentDetail() - { - } - - public TestStudentDetail( - Guid id, - Guid masterId, - string studentName, - StudentType orderType - ) : base(id) - { - MasterId = masterId; - StudentName = studentName; - OrderType = orderType; - } }