diff --git a/Directory.Packages.props b/Directory.Packages.props
index fe2cec9..05f7d21 100644
--- a/Directory.Packages.props
+++ b/Directory.Packages.props
@@ -1,70 +1,70 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
-
- all
- runtime; build; native; contentfiles; analyzers; buildtransitive
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
+
+ all
+ runtime; build; native; contentfiles; analyzers; buildtransitive
+
+
\ No newline at end of file
diff --git a/src/Pandatech.CleanArchitecture.Api/Endpoints/Users/UserEndpoints.cs b/src/Pandatech.CleanArchitecture.Api/Endpoints/Users/UserEndpoints.cs
index a57447a..004d713 100644
--- a/src/Pandatech.CleanArchitecture.Api/Endpoints/Users/UserEndpoints.cs
+++ b/src/Pandatech.CleanArchitecture.Api/Endpoints/Users/UserEndpoints.cs
@@ -1,4 +1,5 @@
using BaseConverter.Attributes;
+using BaseConverter.Extensions;
using FluentMinimalApiMapper;
using GridifyExtensions.Extensions;
using MediatR;
@@ -40,17 +41,18 @@ public void AddRoutes(IEndpointRouteBuilder app)
.Authorize()
.ProducesErrorResponse(400);
- groupApp.MapGet("/{id}", async (ISender sender, [PandaParameterBaseConverter] long id, CancellationToken token) =>
+ groupApp.MapGet("/{id}", async (ISender sender, long id, CancellationToken token) =>
{
var user = await sender.Send(new GetUserQuery(id), token);
return TypedResults.Ok(user);
})
.Authorize()
+ .RouteBaseConverter()
.ProducesErrorResponse(404);
groupApp.MapPut("/{id}",
- async (ISender sender, [PandaParameterBaseConverter] long id, [FromBody] UpdateUserCommand command,
+ async (ISender sender, long id, [FromBody] UpdateUserCommand command,
CancellationToken token) =>
{
command.Id = id;
@@ -58,12 +60,13 @@ public void AddRoutes(IEndpointRouteBuilder app)
return TypedResults.Ok();
})
.Authorize()
+ .RouteBaseConverter()
.ProducesErrorResponse(400)
.ProducesErrorResponse(409);
groupApp.MapPatch("/{id}/password",
- async (ISender sender, [PandaParameterBaseConverter] long id,
+ async (ISender sender, long id,
[FromBody] UpdateUserPasswordCommand command, CancellationToken token) =>
{
command.Id = id;
@@ -71,18 +74,19 @@ public void AddRoutes(IEndpointRouteBuilder app)
return TypedResults.Ok();
})
.Authorize()
+ .RouteBaseConverter()
.ProducesErrorResponse(400)
.ProducesErrorResponse(404);
groupApp.MapPatch("/{id}/status",
- async (ISender sender, [PandaParameterBaseConverter] long id,
- [FromBody] UpdateUserStatusCommand command, CancellationToken token) =>
+ async (ISender sender, long id, [FromBody] UpdateUserStatusCommand command, CancellationToken token) =>
{
command.Id = id;
await sender.Send(command, token);
return TypedResults.Ok();
})
.Authorize()
+ .RouteBaseConverter()
.ProducesErrorResponse(400)
.ProducesErrorResponse(404);
diff --git a/src/Pandatech.CleanArchitecture.Api/Extensions/SwaggerExtension.cs b/src/Pandatech.CleanArchitecture.Api/Extensions/SwaggerExtension.cs
index a90df16..09796b7 100644
--- a/src/Pandatech.CleanArchitecture.Api/Extensions/SwaggerExtension.cs
+++ b/src/Pandatech.CleanArchitecture.Api/Extensions/SwaggerExtension.cs
@@ -1,4 +1,5 @@
using BaseConverter.Attributes;
+using BaseConverter.Extensions;
using BaseConverter.Filters;
using Microsoft.OpenApi.Models;
using Pandatech.CleanArchitecture.Api.Configurations.Options;
@@ -39,8 +40,7 @@ public static WebApplicationBuilder AddSwagger(this WebApplicationBuilder builde
}
// Add string input support into int64 field
- options.ParameterFilter();
- options.SchemaFilter();
+ options.AddBaseConverterFilters();
options.SchemaFilter();
// Add the custom token authentication option
diff --git a/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/css/panda-style.css b/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/css/panda-style.css
index 8f14df6..155141c 100644
--- a/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/css/panda-style.css
+++ b/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/css/panda-style.css
@@ -1,10 +1,12 @@
-.swagger-ui .auth-container .btn.modal-btn.auth{
+.swagger-ui .auth-container .btn.modal-btn.auth {
display: flex;
justify-content: center;
}
-.topbar-wrapper > a > svg{
+
+.topbar-wrapper > a > svg {
opacity: 0;
}
+
.swagger-ui .topbar .download-url-wrapper {
display: flex;
}
diff --git a/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/images/favicon.svg b/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/images/favicon.svg
index d71a75f..6ed89bd 100644
--- a/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/images/favicon.svg
+++ b/src/Pandatech.CleanArchitecture.Api/wwwroot/assets/images/favicon.svg
@@ -1,26 +1,13 @@
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/IdentityState/IdentityStateCommandResponse.cs b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/IdentityState/IdentityStateCommandResponse.cs
index ac66831..7d1daed 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/IdentityState/IdentityStateCommandResponse.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/IdentityState/IdentityStateCommandResponse.cs
@@ -10,7 +10,7 @@ public class IdentityStateCommandResponse(
string fullName,
UserRole userRole)
{
- [PandaPropertyBaseConverter] public long UserId { get; set; } = userId;
+ [PropertyBaseConverter] public long UserId { get; set; } = userId;
public UserStatus Status { get; set; } = status;
public string FullName { get; set; } = fullName;
public UserRole UserRole { get; set; } = userRole;
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/Login/LoginCommandResponse.cs b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/Login/LoginCommandResponse.cs
index a6bf5c4..59dcef0 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/Login/LoginCommandResponse.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/Login/LoginCommandResponse.cs
@@ -6,7 +6,7 @@ namespace Pandatech.CleanArchitecture.Application.Features.Auth.Contracts.Login;
public class LoginCommandResponse
{
- [PandaPropertyBaseConverter] public long UserId { get; set; }
+ [PropertyBaseConverter] public long UserId { get; set; }
public bool ForcePasswordChange { get; set; }
public UserRole UserRole { get; set; }
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/RefreshToken/RefreshTokenCommandResponse.cs b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/RefreshToken/RefreshTokenCommandResponse.cs
index de69df1..0cceed9 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/RefreshToken/RefreshTokenCommandResponse.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/Auth/Contracts/RefreshToken/RefreshTokenCommandResponse.cs
@@ -6,7 +6,7 @@ namespace Pandatech.CleanArchitecture.Application.Features.Auth.Contracts.Refres
public class RefreshTokenCommandResponse
{
- [PandaPropertyBaseConverter] public long UserId { get; set; }
+ [PropertyBaseConverter] public long UserId { get; set; }
public bool ForcePasswordChange { get; set; }
public UserRole UserRole { get; set; }
public string AccessTokenSignature { get; set; } = null!;
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommand.cs b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommand.cs
index 8a77361..e194d67 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommand.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommand.cs
@@ -1,8 +1,9 @@
+using BaseConverter.Attributes;
using Pandatech.CleanArchitecture.Core.Interfaces;
namespace Pandatech.CleanArchitecture.Application.Features.User.Application.Delete;
public class DeleteUsersCommand : ICommand
{
- public List Ids { get; set; } = null!;
+ [PropertyBaseConverter] public List Ids { get; set; } = null!;
}
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommandHandler.cs b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommandHandler.cs
index e560af6..04c0bd2 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommandHandler.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/Delete/DeleteUsersCommandHandler.cs
@@ -9,12 +9,10 @@ public class DeleteUsersCommandHandler(IUnitOfWork unitOfWork, IRequestContext r
{
public async Task Handle(DeleteUsersCommand request, CancellationToken cancellationToken)
{
- List ids = [];
- ids.AddRange(request.Ids.Select(PandaBaseConverter.Base36ToBase10NotNull));
var users = await unitOfWork
.Users
- .GetByIdsExceptSuperAsync(ids, cancellationToken);
+ .GetByIdsExceptSuperAsync(request.Ids, cancellationToken);
if (users.Count == 0)
{
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/UpdateStatus/UpdateUserStatusCommand.cs b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/UpdateStatus/UpdateUserStatusCommand.cs
index a5feae8..6be8409 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/User/Application/UpdateStatus/UpdateUserStatusCommand.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/User/Application/UpdateStatus/UpdateUserStatusCommand.cs
@@ -7,7 +7,7 @@ namespace Pandatech.CleanArchitecture.Application.Features.User.Application.Upda
public class UpdateUserStatusCommand : ICommand
{
- [PandaPropertyBaseConverter]
+ [PropertyBaseConverter]
[JsonIgnore]
public long Id { get; set; }
diff --git a/src/Pandatech.CleanArchitecture.Application/Features/User/Contracts/GetById/GetUserQueryResponse.cs b/src/Pandatech.CleanArchitecture.Application/Features/User/Contracts/GetById/GetUserQueryResponse.cs
index 43f0b0c..802bf4d 100644
--- a/src/Pandatech.CleanArchitecture.Application/Features/User/Contracts/GetById/GetUserQueryResponse.cs
+++ b/src/Pandatech.CleanArchitecture.Application/Features/User/Contracts/GetById/GetUserQueryResponse.cs
@@ -5,7 +5,7 @@ namespace Pandatech.CleanArchitecture.Application.Features.User.Contracts.GetByI
public class GetUserQueryResponse
{
- [PandaPropertyBaseConverter] public long Id { get; set; }
+ [PropertyBaseConverter] public long Id { get; set; }
public string Username { get; set; } = null!;
public string FullName { get; set; } = null!;
public UserRole Role { get; set; }
diff --git a/src/Pandatech.CleanArchitecture.Infrastructure/Extensions/CryptoExtensions.cs b/src/Pandatech.CleanArchitecture.Infrastructure/Extensions/CryptoExtensions.cs
index 38c2c22..93af37f 100644
--- a/src/Pandatech.CleanArchitecture.Infrastructure/Extensions/CryptoExtensions.cs
+++ b/src/Pandatech.CleanArchitecture.Infrastructure/Extensions/CryptoExtensions.cs
@@ -1,4 +1,5 @@
using BaseConverter;
+using BaseConverter.Extensions;
using Microsoft.AspNetCore.Builder;
using Pandatech.CleanArchitecture.Infrastructure.Helpers;
using Pandatech.Crypto;