source: iknow-api/Models/User.cs@ 1b20b22

Last change on this file since 1b20b22 was 1b20b22, checked in by Stefan-Saveski <stefansaveski19@…>, 9 days ago
  • ready for presentation
  • Property mode set to 100644
File size: 1.3 KB
RevLine 
[5eb7847]1namespace iknow_api.Models
[618be76]2{
3 public enum UserRole
4 {
5 Admin,
6 Professor,
[f0fc386]7 Student
[618be76]8 }
9
[1b20b22]10 // Attributes follow the Users entity in the ER model exactly.
[9694de9]11 public class User
[618be76]12 {
13 public int Id { get; set; }
14 public string? Name { get; set; }
[1b20b22]15 public string? EMBG { get; set; }
[618be76]16 public string? Surname { get; set; }
17 public string? Index { get; set; }
18 public string? Email { get; set; }
[fc7b4b4]19 public string? PasswordHash { get; set; }
[1b20b22]20 public DateTime? Bday { get; set; }
[618be76]21 public DateTime CreatedAt { get; set; }
22 public UserRole Role { get; set; }
[1b20b22]23 public Quota? Quota { get; set; }
24 public int? EnrollmentYear { get; set; }
25
[c0256f3]26 public HighSchool? HighSchool { get; set; }
27 public ContactInfo? ContactInfo { get; set; }
[5e22720]28 public ICollection<UserDocuments>? Documents { get; set; }
29
[1b20b22]30 // Named for the relationship it carries: Users 1 --pays-- N Payment.
31 public ICollection<Payment>? Payments { get; set; }
32
33 // Users 1 --submits-- N EnrolledSemesters
34 public ICollection<EnrolledSemesters>? Enrolments { get; set; }
[c0256f3]35
[1b20b22]36 // Users 1 --teaches-- N SemestersSubjects
37 public ICollection<SemesterSubject>? TeachingSubjects { get; set; }
[618be76]38 }
[1b20b22]39}
Note: See TracBrowser for help on using the repository browser.