-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remodeling the project to avoid complexity, leaving only the API that…
… will be responsible for creating usernames, authenticating, generating tokens, in the future if necessary we can divide it into more projects
- Loading branch information
1 parent
005fa16
commit d05afe6
Showing
34 changed files
with
1,037 additions
and
458 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
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
2 changes: 1 addition & 1 deletion
2
...Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Configuration/IdentityConfig.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
6 changes: 2 additions & 4 deletions
6
...s/Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Controllers/AuthController.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
1 change: 0 additions & 1 deletion
1
...s/Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Controllers/MainController.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
25 changes: 0 additions & 25 deletions
25
...wl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Controllers/UserRolesController.cs
This file was deleted.
Oops, something went wrong.
86 changes: 0 additions & 86 deletions
86
.../Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Controllers/UsersController.cs
This file was deleted.
Oops, something went wrong.
39 changes: 4 additions & 35 deletions
39
...wl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Data/BrowlAuthSecurityDbContext.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 |
---|---|---|
@@ -1,46 +1,15 @@ | ||
using Browl.Service.AuthSecurity.Domain.Entities; | ||
|
||
using Microsoft.AspNetCore.Identity; | ||
using Microsoft.AspNetCore.Identity.EntityFrameworkCore; | ||
using Microsoft.EntityFrameworkCore; | ||
|
||
namespace Browl.Service.AuthSecurity.API.Data; | ||
|
||
public class BrowlAuthSecurityDbContext : IdentityDbContext<User> | ||
{ | ||
public BrowlAuthSecurityDbContext(DbContextOptions<BrowlAuthSecurityDbContext> options) : base(options) { } | ||
|
||
protected override void OnModelCreating(ModelBuilder builder) | ||
{ | ||
public BrowlAuthSecurityDbContext(DbContextOptions<BrowlAuthSecurityDbContext> options) : base(options) | ||
{ | ||
base.OnModelCreating(builder); | ||
builder.HasDefaultSchema("Identity"); | ||
builder.Entity<IdentityUser>(entity => | ||
{ | ||
entity.ToTable(name: "User"); | ||
}); | ||
builder.Entity<IdentityRole>(entity => | ||
{ | ||
entity.ToTable(name: "Role"); | ||
}); | ||
builder.Entity<IdentityUserRole<string>>(entity => | ||
{ | ||
entity.ToTable("UserRoles"); | ||
}); | ||
builder.Entity<IdentityUserClaim<string>>(entity => | ||
{ | ||
entity.ToTable("UserClaims"); | ||
}); | ||
builder.Entity<IdentityUserLogin<string>>(entity => | ||
{ | ||
entity.ToTable("UserLogins"); | ||
}); | ||
builder.Entity<IdentityRoleClaim<string>>(entity => | ||
{ | ||
entity.ToTable("RoleClaims"); | ||
}); | ||
builder.Entity<IdentityUserToken<string>>(entity => | ||
{ | ||
entity.ToTable("UserTokens"); | ||
}); | ||
} | ||
} | ||
|
||
|
44 changes: 0 additions & 44 deletions
44
...vices/Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Data/Seeds/ContextSeed.cs
This file was deleted.
Oops, something went wrong.
17 changes: 0 additions & 17 deletions
17
...ices/Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Data/Seeds/DefaultRoles.cs
This file was deleted.
Oops, something went wrong.
75 changes: 0 additions & 75 deletions
75
...ices/Browl.Service.AuthSecurity/Browl.Service.AuthSecurity.API/Data/Seeds/DefaultUsers.cs
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.