Change id types (#114)

* Change id types

* Updated more models

* Saving changes

* Should be it
This commit was merged in pull request #114.
This commit is contained in:
KD
2025-04-03 21:13:05 -04:00
committed by GitHub
parent 12c4f56a22
commit 8abb196e1d
29 changed files with 147 additions and 37 deletions
+8
View File
@@ -23,6 +23,14 @@ public class UserContext : DbContext
{
modelBuilder.Entity<User>()
.ToTable("User");
modelBuilder.Entity<User>(entity =>
{
entity.HasKey(e => e.Id);
entity.Property(e => e.Id)
.HasColumnType("binary(16)"); // **** Map Guid to BINARY(16) ****
});
modelBuilder.Entity<User>()
.Property(u => u.LastLogin).IsRequired(false);
modelBuilder.Entity<User>()