My model has a property that is an enumeration:
Sql server column "user_status" is a int NOT NULL.
[Column("User_Status")]
public UserStatus UserStatus { get; set; }
public enum UserStatus
{
Pending = 1,
Member = 2,
Banned = 3
}
Currently I am getting an error when I save the entity because it says the column user_status cannot be null.
How can I get entity framework to convert this property to an Int when it saves/updates, and when it loads the entity it converts it to the enum.