Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions AdminUI/LearningHub.Nhs.AdminUI/Services/CatalogueService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,11 @@ public class CatalogueService : BaseService, ICatalogueService
/// Initializes a new instance of the <see cref="CatalogueService"/> class.
/// </summary>
/// <param name="learningHubHttpClient">The learningHubHttpClient<see cref="ILearningHubHttpClient"/>.</param>
/// <param name="openApiHttpClient">The Open Api Http Client.</param>
/// <param name="openApiFacade">The openApiFacade<see cref="IOpenApiFacade"/>.</param>
public CatalogueService(
ILearningHubHttpClient learningHubHttpClient,
IOpenApiHttpClient openApiHttpClient,
IOpenApiFacade openApiFacade)
: base(learningHubHttpClient)
{
Expand Down
2 changes: 1 addition & 1 deletion AdminUI/LearningHub.Nhs.AdminUI/Services/ContentService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public class ContentService : BaseService, IContentService
/// <param name="fileService">The fileService<see cref="IFileService"/>.</param>
/// <param name="azureMediaService">azureMediaService.</param>
public ContentService(ILearningHubHttpClient learningHubHttpClient, IOpenApiHttpClient openApiHttpClient, IFileService fileService, IAzureMediaService azureMediaService)
: base(learningHubHttpClient)
: base(learningHubHttpClient, openApiHttpClient)
{
this.fileService = fileService;
this.azureMediaService = azureMediaService;
Expand Down
4 changes: 3 additions & 1 deletion AdminUI/LearningHub.Nhs.AdminUI/Services/UserGroupService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,17 @@ public class UserGroupService : BaseService, IUserGroupService
/// Initializes a new instance of the <see cref="UserGroupService"/> class.
/// </summary>
/// <param name="learningHubHttpClient">The learningHubHttpClient<see cref="ILearningHubHttpClient"/>.</param>
/// <param name="openApiHttpClient">The Open Api Http Client.</param>
/// <param name="contextAccessor">The http context accessor.</param>
/// <param name="cacheService">The cacheService.</param>
/// <param name="roleService">The roleService.</param>
public UserGroupService(
ILearningHubHttpClient learningHubHttpClient,
IOpenApiHttpClient openApiHttpClient,
ICacheService cacheService,
IRoleService roleService,
IHttpContextAccessor contextAccessor)
: base(learningHubHttpClient)
: base(learningHubHttpClient, openApiHttpClient)
{
this.contextAccessor = contextAccessor;
this.cacheService = cacheService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ public CatalogueBasicViewModel GetBasicCatalogue(int catalogueNodeId)
/// </summary>
/// <param name="searchTerm">The searchTerm.</param>
/// <returns>The catalogues.</returns>
public List<CatalogueViewModel> GetCatalogues(string searchTerm)
public List<CatalogueViewModel> GetCatalogues(string? searchTerm)
{
IQueryable<CatalogueNodeVersion> catalogueVersions = this.catalogueNodeVersionRepository.GetAll()
.Include(x => x.Keywords)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public async Task<IActionResult> GetAllCataloguesAsync(string filterChar = null)
/// <returns>The catalogues.</returns>
[HttpGet]
[Route("Catalogues")]
public IActionResult GetCatalogues(string searchTerm)
public IActionResult GetCatalogues([FromQuery] string? searchTerm)
{
var catalogues = this.catalogueService.GetCatalogues(searchTerm);
return this.Ok(catalogues);
Expand Down Expand Up @@ -152,7 +152,7 @@ public IActionResult GetCataloguesForCurrentUser()
/// <returns>The actionResult.</returns>
[HttpPost]
[Route("Catalogues")]
public async Task<IActionResult> CreateCatalogue(CatalogueViewModel viewModel)
public async Task<IActionResult> CreateCatalogue([FromBody] CatalogueViewModel viewModel)
{
try
{
Expand Down Expand Up @@ -237,7 +237,7 @@ public async Task<IActionResult> AccessRequest(int accessRequestId)
/// <returns>The updated catalogue.</returns>
[HttpPut]
[Route("Catalogues")]
public async Task<IActionResult> UpdateCatalogue(CatalogueViewModel viewModel)
public async Task<IActionResult> UpdateCatalogue([FromBody] CatalogueViewModel viewModel)
{
try
{
Expand Down
Loading