From 9a81ae41f91ee58395bb1fcfde3b22b6ce998441 Mon Sep 17 00:00:00 2001 From: Eddie Date: Wed, 20 Nov 2024 13:30:27 +0330 Subject: [PATCH] Set ModifiedOnUtc property to be required --- EWallet.Api/Data/WalletDbContext.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/EWallet.Api/Data/WalletDbContext.cs b/EWallet.Api/Data/WalletDbContext.cs index b72dea2..fc3f866 100644 --- a/EWallet.Api/Data/WalletDbContext.cs +++ b/EWallet.Api/Data/WalletDbContext.cs @@ -22,8 +22,7 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) builder.Property(x => x.CreatedOnUtc) .IsRequired(); - builder.Property(x => x.ModifiedOnUtc) - .IsRequired(false); + builder.Property(x => x.ModifiedOnUtc); builder.Property(x => x.Code) .HasMaxLength(10) //BASEDGODS,HOTDOGE @@ -54,8 +53,7 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(w => w.CreatedOnUtc) .IsRequired(); - entity.Property(w => w.ModifiedOnUtc) - .IsRequired(false); + entity.Property(w => w.ModifiedOnUtc); entity.HasOne(w => w.Currency) .WithMany()