Skip to content

nixgram/ZCommerce

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Screenshot 2021-10-01 011322

This is an API solution & also template for support minimal e-commerce application using .NET5 following the principles of Clean Architecture inspire from Jason Taylor. Use this template button or by installing and running the associated NuGet package (see Getting Started for full details). It's easy to jump start from beginning you can try it the barebone project v0.0.1-beta

Recommend to learn Clean Architecture with ASP.NET Core 3.0 • Jason Taylor • GOTO 2019

Technologies

Getting Started

  1. Install the latest .NET 5 SDK
  2. Install Redis using docker & run docker run -d --rm -p 6379:6379 redis
  3. Go to ZCommerce.API & Run dotnet run to run this project template

Database Migrations

To use dotnet-ef for your migrations please add the following flags to your command (values assume you are executing from repository root)

  • --project ./src/Infrastructure (optional if in this folder)
  • --startup-project ./src/Api
  • --output-dir Data/Migrations

For example, to add a new migration from the root folder:

dotnet ef migrations add "SampleMigration" --project ./src/Infrastructure --startup-project ./src/Api --output-dir Data/Migrations

Update Database,

dotnet ef database update --project ./src/Infrastructure --startup-project ./src/Api

Overview

ZCommerce.Domain

This will contain all entities, enums, exceptions, interfaces, types and logic specific to the domain layer.

ZCommerce.Application

This layer contains all application logic. It is dependent on the domain layer, but has no dependencies on any other layer or project. This layer defines interfaces that are implemented by outside layers. For example, if the application need to access a notification service, a new interface would be added to application and an implementation would be created within infrastructure.

ZCommerce.Infrastructure

This layer contains classes for accessing external resources such as file systems, web services, smtp, and so on. These classes should be based on interfaces defined within the application layer.

ZCommerce.API

This layer contain all API end points and contract with ZCommerce.Application via MediatR.

Support

If you are having problems, please let us know by raising a new issue.

License

This project is licensed with the MIT license.

Connect with me

haasib25 bdshanto bdshanto hsibbd bdshanto