Re-fabrication
This commit is contained in:
parent
f155a47073
commit
cb6309abdb
499 changed files with 7574 additions and 12530 deletions
15
Yavsc.Server/Models/Cratie/AName/NameSubmission.cs
Normal file
15
Yavsc.Server/Models/Cratie/AName/NameSubmission.cs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Yavsc.Models.Cratie.AName
|
||||
{
|
||||
public class NameSubmission : Submission
|
||||
{
|
||||
[RegularExpression(@"[a-zA-Z]+", ErrorMessage = "Nom invalide (seules les lettres de l'alphabet sont autorisées).", ErrorMessageResourceName = "EInvalidName")]
|
||||
|
||||
public string FirstChoice {get; set;}
|
||||
[RegularExpression(@"[a-zA-Z]+", ErrorMessage = "Nom invalide (seules les lettres de l'alphabet sont autorisées).", ErrorMessageResourceName = "EInvalidName")]
|
||||
public string SecondChoice {get; set;}
|
||||
[RegularExpression(@"[a-zA-Z]+", ErrorMessage = "Nom invalide (seules les lettres de l'alphabet sont autorisées).", ErrorMessageResourceName = "EInvalidName")]
|
||||
public string ThirdChoice {get; set;}
|
||||
}
|
||||
}
|
||||
15
Yavsc.Server/Models/Cratie/Option.cs
Normal file
15
Yavsc.Server/Models/Cratie/Option.cs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
using System;
|
||||
|
||||
namespace Yavsc.Models.Cratie
|
||||
{
|
||||
public class Option: IBaseTrackedEntity
|
||||
{
|
||||
public string CodeScrutin { get; set; }
|
||||
public string Code { get; set ; }
|
||||
public string Description { get; set; }
|
||||
public DateTime DateCreated { get ; set ; }
|
||||
public string UserCreated { get ; set ; }
|
||||
public DateTime DateModified { get ; set ; }
|
||||
public string UserModified { get ; set ; }
|
||||
}
|
||||
}
|
||||
16
Yavsc.Server/Models/Cratie/Scrutin.cs
Normal file
16
Yavsc.Server/Models/Cratie/Scrutin.cs
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
using System;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Yavsc.Models.Cratie
|
||||
{
|
||||
public class Scrutin : IBaseTrackedEntity
|
||||
{
|
||||
[Key]
|
||||
public string Code { get; set ; }
|
||||
public string Description { get ; set ; }
|
||||
public DateTime DateCreated { get; set; }
|
||||
public string UserCreated { get; set; }
|
||||
public DateTime DateModified { get; set; }
|
||||
public string UserModified { get; set; }
|
||||
}
|
||||
}
|
||||
19
Yavsc.Server/Models/Cratie/Submission.cs
Normal file
19
Yavsc.Server/Models/Cratie/Submission.cs
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace Yavsc.Models.Cratie
|
||||
{
|
||||
public class Submission
|
||||
{
|
||||
[ForeignKey("CodeScrutin")]
|
||||
public virtual Scrutin Context { get; set; }
|
||||
public string CodeScrutin { get; set ; }
|
||||
|
||||
[ForeignKey("CodeOption")]
|
||||
public virtual Option Choice { get; set; }
|
||||
public string CodeOption { get; set; }
|
||||
|
||||
[ForeignKey("AuthorId")]
|
||||
public virtual ApplicationUser Author { get; set; }
|
||||
public string AuthorId { get ; set ;}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue