using System.ComponentModel.DataAnnotations;
using Microsoft.AspNet.Http;
namespace tamam.Models
{
public class User
{
[Required]
[MinLength(4)]
public string Name { get; set; }
public string Address { get; set; }
public int Age { get; set; }
[Required]
[FileExtensions(Extensions = "jpg,jpeg")]
public IFormFile File { get; set; }
}
}
when i create a controller, the following error appear
error:
there was an error running the selected code generator:
the property 'file' on entity type 'xxx' has not been added to the model or ignored