From d37d3c704395673ba707e07dc46bd075090b798d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D1=80=D1=82=D1=91=D0=BC=20=D0=90=D0=BB=D0=B5=D0=B9?= =?UTF-8?q?=D0=BA=D0=B8=D0=BD?= Date: Sun, 26 Mar 2023 19:25:49 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9A=D0=BE=D0=BD=D1=82=D1=80=D0=B0=D0=BA?= =?UTF-8?q?=D1=82=D1=8B=20->=20BindingModels,=20SearchModels;?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CaseAccounting/CaseAccounting.sln | 14 ++++++++++- .../BindingModels/CaseBindingModel.cs | 22 ++++++++++++++--- .../BindingModels/ContractBindingModel.cs | 20 ++++++++++++++++ .../BindingModels/DealBindingModel.cs | 20 ++++++++++++++++ .../BindingModels/HearingBindingModel.cs | 20 ++++++++++++++++ .../BindingModels/LawyerBindingModel.cs | 24 +++++++++++++++++++ .../BindingModels/RoleBindingModel.cs | 16 +++++++++++++ .../SpecializationBindingModel.cs | 16 +++++++++++++ .../BindingModels/UserBindingModel.cs | 20 ++++++++++++++++ .../CaseAccountingContracts.csproj | 4 ++++ .../SearchModels/CaseSearchModel.cs | 21 ++++++++++++++++ .../SearchModels/ContractSearchModel.cs | 15 ++++++++++++ .../SearchModels/DealSearchModel.cs | 15 ++++++++++++ .../SearchModels/HearingModel.cs | 17 +++++++++++++ .../SearchModels/LawyerSearchModel.cs | 15 ++++++++++++ .../SearchModels/RoleSearchModel.cs | 14 +++++++++++ .../SearchModels/SpecializationSearchModel.cs | 14 +++++++++++ .../SearchModels/UserSearchModel.cs | 13 ++++++++++ 18 files changed, 296 insertions(+), 4 deletions(-) create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/ContractBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/DealBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/HearingBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/LawyerBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/RoleBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/SpecializationBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/BindingModels/UserBindingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/CaseSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/ContractSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/DealSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/HearingModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/LawyerSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/RoleSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/SpecializationSearchModel.cs create mode 100644 CaseAccounting/CaseAccountingContracts/SearchModels/UserSearchModel.cs diff --git a/CaseAccounting/CaseAccounting.sln b/CaseAccounting/CaseAccounting.sln index a0e00aa..10e9108 100644 --- a/CaseAccounting/CaseAccounting.sln +++ b/CaseAccounting/CaseAccounting.sln @@ -3,7 +3,11 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 17 VisualStudioVersion = 17.5.33424.131 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CaseAccountingDataModels", "CaseAccountingDataModels\CaseAccountingDataModels.csproj", "{CAA81DB0-6CCA-4CBE-ABE2-94CDB190E05F}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CaseAccountingDataModels", "CaseAccountingDataModels\CaseAccountingDataModels.csproj", "{CAA81DB0-6CCA-4CBE-ABE2-94CDB190E05F}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CaseAccountingContracts", "CaseAccountingContracts\CaseAccountingContracts.csproj", "{5EB90E7D-3EBE-4E01-BBFE-CE15629BDBEF}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CaseAccountingDataBaseImplement", "CaseAccountingDataBaseImplement\CaseAccountingDataBaseImplement.csproj", "{025B8D7C-ACDD-4CA3-A2E1-BF833CA2D65D}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -15,6 +19,14 @@ Global {CAA81DB0-6CCA-4CBE-ABE2-94CDB190E05F}.Debug|Any CPU.Build.0 = Debug|Any CPU {CAA81DB0-6CCA-4CBE-ABE2-94CDB190E05F}.Release|Any CPU.ActiveCfg = Release|Any CPU {CAA81DB0-6CCA-4CBE-ABE2-94CDB190E05F}.Release|Any CPU.Build.0 = Release|Any CPU + {5EB90E7D-3EBE-4E01-BBFE-CE15629BDBEF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {5EB90E7D-3EBE-4E01-BBFE-CE15629BDBEF}.Debug|Any CPU.Build.0 = Debug|Any CPU + {5EB90E7D-3EBE-4E01-BBFE-CE15629BDBEF}.Release|Any CPU.ActiveCfg = Release|Any CPU + {5EB90E7D-3EBE-4E01-BBFE-CE15629BDBEF}.Release|Any CPU.Build.0 = Release|Any CPU + {025B8D7C-ACDD-4CA3-A2E1-BF833CA2D65D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {025B8D7C-ACDD-4CA3-A2E1-BF833CA2D65D}.Debug|Any CPU.Build.0 = Debug|Any CPU + {025B8D7C-ACDD-4CA3-A2E1-BF833CA2D65D}.Release|Any CPU.ActiveCfg = Release|Any CPU + {025B8D7C-ACDD-4CA3-A2E1-BF833CA2D65D}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/CaseBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/CaseBindingModel.cs index 49acb6d..614dfd3 100644 --- a/CaseAccounting/CaseAccountingContracts/BindingModels/CaseBindingModel.cs +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/CaseBindingModel.cs @@ -1,4 +1,5 @@ -using System; +using CaseAccountingDataModels.Models; +using System; using System.Collections.Generic; using System.Linq; using System.Text; @@ -6,7 +7,22 @@ using System.Threading.Tasks; namespace CaseAccountingContracts.BindingModels { - public class CaseBindingModel + public class CaseBindingModel : ICaseModel { - } + public int Id { get; set; } + + public string Name { get; set; } = string.Empty; + + public string Applicant { get; set; } = string.Empty; + + public string Defendant { get; set; } = string.Empty; + + public string Annotation { get; set; } = string.Empty; + + public DateTime Date { get; set; } = DateTime.SpecifyKind(DateTime.Now, DateTimeKind.Utc); + + public int SpecializationId { get; set; } + + public int UserId { get; set; } + } } diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/ContractBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/ContractBindingModel.cs new file mode 100644 index 0000000..8e49cbe --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/ContractBindingModel.cs @@ -0,0 +1,20 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class ContractBindingModel : IContractModel + { + public string Service { get; set; } = string.Empty; + + public decimal Coast { get; set; } + + public DateTime Date { get; set; } = DateTime.SpecifyKind(DateTime.Now, DateTimeKind.Utc); + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/DealBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/DealBindingModel.cs new file mode 100644 index 0000000..e085752 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/DealBindingModel.cs @@ -0,0 +1,20 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class DealBindingModel : IDealModel + { + public string Subject { get; set; } = string.Empty; + + public string Responsibilities { get; set; } = string.Empty; + + public DateTime Date { get; set; } = DateTime.SpecifyKind(DateTime.Now, DateTimeKind.Utc); + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/HearingBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/HearingBindingModel.cs new file mode 100644 index 0000000..0aeb6cd --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/HearingBindingModel.cs @@ -0,0 +1,20 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class HearingBindingModel : IHearingModel + { + public string Information { get; set; } = string.Empty; + + public DateTime Date { get; set; } = DateTime.SpecifyKind(DateTime.Now, DateTimeKind.Utc); + + public int CaseId { get; set; } + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/LawyerBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/LawyerBindingModel.cs new file mode 100644 index 0000000..512642d --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/LawyerBindingModel.cs @@ -0,0 +1,24 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class LawyerBindingModel : ILawyerModel + { + public string Name { get; set; } = string.Empty; + + public string Surname { get; set; } = string.Empty; + + public string Patronymic { get; set; } = string.Empty; + + public int Experience { get; set; } + + public int SpecializationId { get; set; } + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/RoleBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/RoleBindingModel.cs new file mode 100644 index 0000000..3c7b020 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/RoleBindingModel.cs @@ -0,0 +1,16 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class RoleBindingModel : IRoleModel + { + public string Name { get; set; } = string.Empty; + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/SpecializationBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/SpecializationBindingModel.cs new file mode 100644 index 0000000..3de52e3 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/SpecializationBindingModel.cs @@ -0,0 +1,16 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class SpecializationBindingModel : ISpecializationModel + { + public string Name { get; set; } = string.Empty; + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/BindingModels/UserBindingModel.cs b/CaseAccounting/CaseAccountingContracts/BindingModels/UserBindingModel.cs new file mode 100644 index 0000000..fef235a --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/BindingModels/UserBindingModel.cs @@ -0,0 +1,20 @@ +using CaseAccountingDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.BindingModels +{ + public class UserBindingModel : IUserModel + { + public string Login { get; set; } = string.Empty; + + public string Password { get; set; } = string.Empty; + + public int RoleId { get; set; } + + public int Id { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/CaseAccountingContracts.csproj b/CaseAccounting/CaseAccountingContracts/CaseAccountingContracts.csproj index 132c02c..428fc6f 100644 --- a/CaseAccounting/CaseAccountingContracts/CaseAccountingContracts.csproj +++ b/CaseAccounting/CaseAccountingContracts/CaseAccountingContracts.csproj @@ -6,4 +6,8 @@ enable + + + + diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/CaseSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/CaseSearchModel.cs new file mode 100644 index 0000000..2f22a7b --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/CaseSearchModel.cs @@ -0,0 +1,21 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class CaseSearchModel + { + public int? Id { get; set; } + + public string? Name { get; set; } + + public string? Applicant { get; set; } + + public string? Defendant { get; set; } + + public DateTime? Date { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/ContractSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/ContractSearchModel.cs new file mode 100644 index 0000000..9e79462 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/ContractSearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class ContractSearchModel + { + public int? Id { get; set; } + + public DateTime? Date { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/DealSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/DealSearchModel.cs new file mode 100644 index 0000000..7fe6230 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/DealSearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class DealSearchModel + { + public int? Id { get; set; } + + public DateTime? Date { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/HearingModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/HearingModel.cs new file mode 100644 index 0000000..74e416d --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/HearingModel.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class HearingModel + { + public int? Id { get; set; } + + public DateTime? Date { get; set; } + + public int? CaseId { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/LawyerSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/LawyerSearchModel.cs new file mode 100644 index 0000000..6276b85 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/LawyerSearchModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class LawyerSearchModel + { + public int? Id { get; set; } + + public int SpecializationId { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/RoleSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/RoleSearchModel.cs new file mode 100644 index 0000000..79ff0c3 --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/RoleSearchModel.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class RoleSearchModel + { + public int? Id { get; set; } + public string? Name { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/SpecializationSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/SpecializationSearchModel.cs new file mode 100644 index 0000000..d5e7fac --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/SpecializationSearchModel.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class SpecializationSearchModel + { + public int? Id { get; set; } + public string? Name { get; set; } + } +} diff --git a/CaseAccounting/CaseAccountingContracts/SearchModels/UserSearchModel.cs b/CaseAccounting/CaseAccountingContracts/SearchModels/UserSearchModel.cs new file mode 100644 index 0000000..7122c6d --- /dev/null +++ b/CaseAccounting/CaseAccountingContracts/SearchModels/UserSearchModel.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace CaseAccountingContracts.SearchModels +{ + public class UserSearchModel + { + public int? Id { get; set; } + } +}