From b85e7f80e403f1919b318be695315c2a6f0c7217 Mon Sep 17 00:00:00 2001 From: Mukesh Murugan Date: Thu, 18 Jun 2020 00:06:50 +0530 Subject: [PATCH] Added Product and Base Entity --- Domain/Common/BaseEntity.cs | 11 +++++++++++ Domain/Entities/Product.cs | 15 +++++++++++++++ WebApi/Properties/launchSettings.json | 4 ++-- 3 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 Domain/Common/BaseEntity.cs create mode 100644 Domain/Entities/Product.cs diff --git a/Domain/Common/BaseEntity.cs b/Domain/Common/BaseEntity.cs new file mode 100644 index 0000000..0eaa152 --- /dev/null +++ b/Domain/Common/BaseEntity.cs @@ -0,0 +1,11 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Domain.Common +{ + public abstract class BaseEntity + { + public int Id { get; set; } + } +} diff --git a/Domain/Entities/Product.cs b/Domain/Entities/Product.cs new file mode 100644 index 0000000..ea1a61d --- /dev/null +++ b/Domain/Entities/Product.cs @@ -0,0 +1,15 @@ +using Domain.Common; +using System; +using System.Collections.Generic; +using System.Text; + +namespace Domain.Entities +{ + public class Product : BaseEntity + { + public string Name { get; set; } + public string Barcode { get; set; } + public string Description { get; set; } + public decimal Rate { get; set; } + } +} diff --git a/WebApi/Properties/launchSettings.json b/WebApi/Properties/launchSettings.json index f15632d..7f92ac2 100644 --- a/WebApi/Properties/launchSettings.json +++ b/WebApi/Properties/launchSettings.json @@ -12,7 +12,7 @@ "IIS Express": { "commandName": "IISExpress", "launchBrowser": true, - "launchUrl": "weatherforecast", + "launchUrl": "swagger", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development" } @@ -20,7 +20,7 @@ "WebApi": { "commandName": "Project", "launchBrowser": true, - "launchUrl": "weatherforecast", + "launchUrl": "swagger", "applicationUrl": "https://localhost:5001;http://localhost:5000", "environmentVariables": { "ASPNETCORE_ENVIRONMENT": "Development"