You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.1 KiB
47 lines
1.1 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Entity
|
|
{
|
|
public class Question
|
|
{
|
|
[Key]
|
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
|
public int Id { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(200)]
|
|
public string Text { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(50)]
|
|
public string AnswerA { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(50)]
|
|
public string AnswerB { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(50)]
|
|
public string AnswerC { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(50)]
|
|
public string AnswerD { get; set; }
|
|
|
|
[Required]
|
|
[StringLength(1)]
|
|
public string CorrectAnswer { get; set; }
|
|
|
|
[Required]
|
|
public bool IsValid { get; set; }
|
|
|
|
public ICollection<Quiz> Quizs { get; set; } = new List<Quiz>();
|
|
}
|
|
}
|