User-2133486755 posted
I have the following class.
public class User
{
public int Id { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public byte[] RowVersion { get; set; }
public bool IsDeleted { get; set; }
}
How can I set default value for property IsDeleted
using Fluent API. Method HasDefaultValue
is not available. I have tried to set via constructor, the same
result. In constructor I have tried false value, field still doesn't have default value.
The solution presented below, also didn't succeed.
public bool IsDeleted { get; set; } = false;