-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CHORE: Reorganize source files structure (#36)
Closes #28 Because of the new structure, the previous template shortcuts need to be renamed, so this breaking change will be reflected in the version number going to v2.0. Also, as a consequence, the Nuget package is also intended to be renamed, so the old one will be deprecated to give place to the new -more generic- one.
- Loading branch information
Showing
249 changed files
with
3,782 additions
and
3,788 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 8 additions & 7 deletions
15
...ontent/Monaco.Template.Api/Auth/Scopes.cs → ...onaco.Template.Backend.Api/Auth/Scopes.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
src/Content/Backend/Solution/Monaco.Template.Backend.Api/Controllers/CountriesController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
using MediatR; | ||
using Microsoft.AspNetCore.Mvc; | ||
using Monaco.Template.Backend.Application.DTOs; | ||
using Monaco.Template.Backend.Application.Features.Country.Queries; | ||
using Monaco.Template.Backend.Common.Api.Application; | ||
|
||
namespace Monaco.Template.Backend.Api.Controllers; | ||
|
||
[Route("api/v{apiVersion:apiVersion}/[controller]")] | ||
[ApiController] | ||
public class CountriesController : ControllerBase | ||
{ | ||
private readonly IMediator _mediator; | ||
|
||
public CountriesController(IMediator mediator) | ||
{ | ||
_mediator = mediator; | ||
} | ||
|
||
/// <summary> | ||
/// Gets a list of countries | ||
/// </summary> | ||
/// <returns></returns> | ||
[HttpGet] | ||
public Task<ActionResult<List<CountryDto>>> Get() => | ||
_mediator.ExecuteQueryAsync(new GetCountryListQuery(Request.Query)); | ||
|
||
/// <summary> | ||
/// Gets a country by Id | ||
/// </summary> | ||
/// <param name="id"></param> | ||
/// <returns></returns> | ||
[HttpGet("{id:guid}")] | ||
public Task<ActionResult<CountryDto?>> Get(Guid id) => | ||
_mediator.ExecuteQueryAsync(new GetCountryByIdQuery(id)); | ||
} |
12 changes: 6 additions & 6 deletions
12
...mplate.Api/Controllers/FilesController.cs → ...ackend.Api/Controllers/FilesController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 6 additions & 6 deletions
12
...plate.Api/Controllers/ImagesController.cs → ...ckend.Api/Controllers/ImagesController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
src/Content/Backend/Solution/Monaco.Template.Backend.Api/DTOs/CompanyCreateEditDto.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
namespace Monaco.Template.Backend.Api.DTOs; | ||
|
||
public class CompanyCreateEditDto | ||
{ | ||
public string? Name { get; set; } | ||
public string? Email { get; set; } | ||
public string? WebSiteUrl { get; set; } | ||
public string? Street { get; set; } | ||
public string? City { get; set; } | ||
public string? County { get; set; } | ||
public string? PostCode { get; set; } | ||
|
||
public Guid? CountryId { get; set; } | ||
} |
4 changes: 2 additions & 2 deletions
4
....Api/DTOs/Extensions/CompanyExtensions.cs → ....Api/DTOs/Extensions/CompanyExtensions.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.