| | 1 | | using System; |
| | 2 | | using System.Collections.Generic; |
| | 3 | | using System.ComponentModel.DataAnnotations; |
| | 4 | | using System.ComponentModel.DataAnnotations.Schema; |
| | 5 | | using System.Linq; |
| | 6 | | using System.Runtime.Serialization; |
| | 7 | | using System.Text.Json.Serialization; |
| | 8 | | using System.Threading.Tasks; |
| | 9 | |
|
| | 10 | | namespace MUNity.Database.Models.Conference; |
| | 11 | |
|
| | 12 | | /// <summary> |
| | 13 | | /// The authorizations of a role inside a conference. |
| | 14 | | /// </summary> |
| | 15 | | public class ConferenceRoleAuth |
| | 16 | | { |
| | 17 | | [Key] |
| 0 | 18 | | public int ConferenceRoleAuthId { get; set; } |
| | 19 | |
|
| | 20 | | [MaxLength(150)] |
| 9 | 21 | | public string RoleAuthName { get; set; } |
| | 22 | |
|
| | 23 | | /// <summary> |
| | 24 | | /// The Pwer Level gives a basic idea of what power the |
| | 25 | | /// user should have. This can also be used when working |
| | 26 | | /// with the API outside of this context. For example |
| | 27 | | /// another application that wants to use this framework/API |
| | 28 | | /// </summary> |
| 9 | 29 | | public int PowerLevel { get; set; } |
| | 30 | |
|
| | 31 | | /// <summary> |
| | 32 | | /// Every Role auth is linked to a conference, to protect other Conferences |
| | 33 | | /// from changing them but also be able to reuse the same role inside of |
| | 34 | | /// the some conference again. This will create a lot of duplicate data |
| | 35 | | /// because a lot of conferences will share the same structure but that's |
| | 36 | | /// not a problem |
| | 37 | | /// </summary> |
| 9 | 38 | | public Conference Conference { get; set; } |
| | 39 | |
|
| | 40 | | /// <summary> |
| | 41 | | /// Can change the Settings of the conference for example the date, name etc. |
| | 42 | | /// It also allows to change the structure of the conference like Committees, |
| | 43 | | /// delegations, roles etc. |
| | 44 | | /// </summary> |
| 9 | 45 | | public bool CanEditConferenceSettings { get; set; } |
| | 46 | |
|
| | 47 | | /// <summary> |
| | 48 | | /// The user can see all applications for roles |
| | 49 | | /// </summary> |
| 9 | 50 | | public bool CanSeeApplications { get; set; } |
| | 51 | |
|
| | 52 | | /// <summary> |
| | 53 | | /// The user can change participations for example accept or deny |
| | 54 | | /// an application for a role, or set someone into the team etc. |
| | 55 | | /// </summary> |
| 9 | 56 | | public bool CanEditParticipations { get; set; } |
| | 57 | |
|
| | 58 | |
|
| | 59 | | } |