diff --git a/Manager.Interfaces/DTO/SubSection/AgendaDTO.cs b/Manager.Interfaces/DTO/SubSection/AgendaDTO.cs new file mode 100644 index 0000000..1e16765 --- /dev/null +++ b/Manager.Interfaces/DTO/SubSection/AgendaDTO.cs @@ -0,0 +1,12 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Manager.Interfaces.DTO +{ + public class AgendaDTO + { + //public string Title { get; set; } // Dictionary with all languages + public string source { get; set; } // url to resource id (local) or on internet => JSON file + } +} diff --git a/Manager.Interfaces/DTO/SubSection/PdfDTO.cs b/Manager.Interfaces/DTO/SubSection/PdfDTO.cs new file mode 100644 index 0000000..f25356a --- /dev/null +++ b/Manager.Interfaces/DTO/SubSection/PdfDTO.cs @@ -0,0 +1,12 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Manager.Interfaces.DTO +{ + public class PdfDTO + { + //public string Title { get; set; } // Dictionary with all languages + public string source { get; set; } // url to resource id (local) or on internet + } +} diff --git a/Manager.Interfaces/DTO/SubSection/PuzzleDTO.cs b/Manager.Interfaces/DTO/SubSection/PuzzleDTO.cs new file mode 100644 index 0000000..28ec239 --- /dev/null +++ b/Manager.Interfaces/DTO/SubSection/PuzzleDTO.cs @@ -0,0 +1,14 @@ +using Manager.Interfaces.Models; +using System; +using System.Collections.Generic; +using System.Text; + +namespace Manager.Interfaces.DTO +{ + public class PuzzleDTO + { + public List messageDebut { get; set; } + public List messageFin { get; set; } + public ImageDTO image { get; set; } + } +} diff --git a/Manager.Interfaces/Models/Resource.cs b/Manager.Interfaces/Models/Resource.cs index 57ca86f..727859c 100644 --- a/Manager.Interfaces/Models/Resource.cs +++ b/Manager.Interfaces/Models/Resource.cs @@ -51,6 +51,8 @@ namespace Manager.Interfaces.Models Video, ImageUrl, VideoUrl, - Audio + Audio, + PDF, + JSON } } diff --git a/Manager.Interfaces/Models/Section.cs b/Manager.Interfaces/Models/Section.cs index 8ab4283..3cf768f 100644 --- a/Manager.Interfaces/Models/Section.cs +++ b/Manager.Interfaces/Models/Section.cs @@ -115,6 +115,9 @@ namespace Manager.Interfaces.Models Web, Menu, Quizz, - Article + Article, + PDF, + Puzzle, + Agenda } } diff --git a/ManagerService/Controllers/SectionController.cs b/ManagerService/Controllers/SectionController.cs index 7354206..8f3857a 100644 --- a/ManagerService/Controllers/SectionController.cs +++ b/ManagerService/Controllers/SectionController.cs @@ -719,5 +719,35 @@ namespace ManagerService.Controllers { return new ObjectResult("ArticleDTO") { StatusCode = 200 }; } + + /// + /// Useless, just to generate dto code + /// + [ProducesResponseType(typeof(PdfDTO), 200)] + [HttpGet("PdfDTO")] + public ObjectResult GetPdfDTO() + { + return new ObjectResult("PdfDTO") { StatusCode = 200 }; + } + + /// + /// Useless, just to generate dto code + /// + [ProducesResponseType(typeof(PuzzleDTO), 200)] + [HttpGet("PuzzleDTO")] + public ObjectResult GetPuzzleDTO() + { + return new ObjectResult("PuzzleDTO") { StatusCode = 200 }; + } + + /// + /// Useless, just to generate dto code + /// + [ProducesResponseType(typeof(AgendaDTO), 200)] + [HttpGet("AgendaDTO")] + public ObjectResult GetAgendaDTO() + { + return new ObjectResult("AgendaDTO") { StatusCode = 200 }; + } } } diff --git a/ManagerService/Startup.cs b/ManagerService/Startup.cs index 504e664..2a37b04 100644 --- a/ManagerService/Startup.cs +++ b/ManagerService/Startup.cs @@ -133,7 +133,9 @@ namespace ManagerService }; }); +#if RELEASE services.AddMqttClientHostedService(); +#endif services.AddScoped(typeof(ProfileLogic)); services.AddScoped(); services.AddScoped();