
Priyanka Rudra
3,137 Pointsmake the Name and DescriptionOfProblem properties required by adding [Required] data annotations to those properties
I added [Required] data annotation to both the properties. I am not sure what's wrong with the code.
using System.ComponentModel.DataAnnotations;
namespace IssueReporter.Models
{
public class Issue
{
public enum SeverityLevel
{
Minor,
Major,
Critical
}
public int Id { get; set; }
public string Name { get; set; }
public string Email { get; set; }
public int DepartmentId { get; set; }
[Required]
[Display(Name = "Department")]
public Department Department { get; set; }
public SeverityLevel Severity { get; set; }
public bool Reproducible { get; set; }
[Required]
[Display(Name = "Description of Problem")]
public string DescriptionOfProblem { get; set; }
}
}
Priyanka Rudra
3,137 PointsPriyanka Rudra
3,137 PointsThe error says "Bummer! Did you remove or change the Issue class?"