From 93f8b040ca274ac66b1f8335f70811e6360ab32d Mon Sep 17 00:00:00 2001 From: Ismailov_Rovshan Date: Wed, 6 Sep 2023 20:40:13 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9C=D0=BE=D0=B4=D0=B5=D0=BB=D0=B8=20=D0=B4?= =?UTF-8?q?=D0=BF=D0=BD=D0=BD=D1=8B=D1=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BlogDataModels/BlogDataModels/ICategoryModel.cs | 13 +++++++++++++ BlogDataModels/BlogDataModels/IId.cs | 13 +++++++++++++ BlogDataModels/BlogDataModels/IMessageModel.cs | 14 ++++++++++++++ BlogDataModels/BlogDataModels/IRoleModel.cs | 13 +++++++++++++ BlogDataModels/BlogDataModels/ITopicModel.cs | 15 +++++++++++++++ BlogDataModels/BlogDataModels/IUserModel.cs | 17 +++++++++++++++++ BlogDataModels/BlogViewModel/Program.cs | 2 +- 7 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 BlogDataModels/BlogDataModels/ICategoryModel.cs create mode 100644 BlogDataModels/BlogDataModels/IId.cs create mode 100644 BlogDataModels/BlogDataModels/IMessageModel.cs create mode 100644 BlogDataModels/BlogDataModels/IRoleModel.cs create mode 100644 BlogDataModels/BlogDataModels/ITopicModel.cs create mode 100644 BlogDataModels/BlogDataModels/IUserModel.cs diff --git a/BlogDataModels/BlogDataModels/ICategoryModel.cs b/BlogDataModels/BlogDataModels/ICategoryModel.cs new file mode 100644 index 0000000..64a9363 --- /dev/null +++ b/BlogDataModels/BlogDataModels/ICategoryModel.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface ICategoryModel : IId + { + string Name { get; } + } +} diff --git a/BlogDataModels/BlogDataModels/IId.cs b/BlogDataModels/BlogDataModels/IId.cs new file mode 100644 index 0000000..34c0a00 --- /dev/null +++ b/BlogDataModels/BlogDataModels/IId.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface IId + { + int Id { get; } + } +} diff --git a/BlogDataModels/BlogDataModels/IMessageModel.cs b/BlogDataModels/BlogDataModels/IMessageModel.cs new file mode 100644 index 0000000..5c4046e --- /dev/null +++ b/BlogDataModels/BlogDataModels/IMessageModel.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface IMessageModel : IId + { + string Text { get; } + DateTime Date { get; } + } +} diff --git a/BlogDataModels/BlogDataModels/IRoleModel.cs b/BlogDataModels/BlogDataModels/IRoleModel.cs new file mode 100644 index 0000000..43ea585 --- /dev/null +++ b/BlogDataModels/BlogDataModels/IRoleModel.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface IRoleModel : IId + { + string Name { get; } + } +} diff --git a/BlogDataModels/BlogDataModels/ITopicModel.cs b/BlogDataModels/BlogDataModels/ITopicModel.cs new file mode 100644 index 0000000..4f8f2a2 --- /dev/null +++ b/BlogDataModels/BlogDataModels/ITopicModel.cs @@ -0,0 +1,15 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface ITopicModel : IId + { + string Name { get; } + + int CategoryId { get; } + } +} diff --git a/BlogDataModels/BlogDataModels/IUserModel.cs b/BlogDataModels/BlogDataModels/IUserModel.cs new file mode 100644 index 0000000..063e21b --- /dev/null +++ b/BlogDataModels/BlogDataModels/IUserModel.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace ForumDataModels +{ + public interface IUserModel : IId + { + string Username { get; } + string Email { get; } + string Password { get; } + DateTime RegistrationDate { get; } + int RoleId { get; } + } +} diff --git a/BlogDataModels/BlogViewModel/Program.cs b/BlogDataModels/BlogViewModel/Program.cs index 3361c95..7a0530d 100644 --- a/BlogDataModels/BlogViewModel/Program.cs +++ b/BlogDataModels/BlogViewModel/Program.cs @@ -1,4 +1,4 @@ - +using BlogContracts using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Logging; using NLog.Extensions.Logging;