Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
177 commits
Select commit Hold shift + click to select a range
8d63ee1
updated documentation based on the imported API
OluwatobiAwe Apr 9, 2025
067cd6d
Azure AI search implementation, updated OpenAPI
Nov 14, 2025
bc12dde
Added new search filter and search result page and added feature flag…
Nov 17, 2025
912d9e0
Added resource collection filter
Nov 17, 2025
d23b44f
Get the resource collection filter working completely
Nov 18, 2025
a4d9c97
Updated the resource collection filter from radio button to check boxes
Nov 19, 2025
c877dbd
Refactored some of the codes, fixed sorting, and new catalogue layout
Nov 24, 2025
d6ffff1
Minor fix
Nov 24, 2025
e1c36c0
Merge pull request #1554 from TechnologyEnhancedLearning/Develop/Feat…
binon Nov 24, 2025
9f72b2b
Updated the admin UI to use azure search flag and refactored Azuresea…
Nov 24, 2025
646f2d6
Merge branch 'RC' into Develop/Features/TD-6467-implement-new-search-ui
Nov 25, 2025
7090e75
Merge branch 'RC' into Develop/Features/TD-6212-azure-ai-search-imple…
Nov 25, 2025
b393092
Merge branch 'Develop/Features/TD-6467-implement-new-search-ui' into …
Nov 25, 2025
a0f98fa
Upgraded to latest model project
Nov 25, 2025
47f7149
Merge branch 'Develop/Features/TD-6467-implement-new-search-ui' into …
Nov 25, 2025
fa65ee1
new Commit without token
OluwatobiAwe Nov 26, 2025
7af543d
LH model Update
OluwatobiAwe Nov 26, 2025
d33eb31
Merge pull request #1556 from TechnologyEnhancedLearning/TD-6100-Reset
AnjuJose011 Nov 26, 2025
84b2bf6
Implementing search admin, handling index and indexer
Nov 26, 2025
4d5a356
Merge branch 'Develop/Feature/TD-6601-search-admin' into Develop/Feat…
Nov 26, 2025
0029c3b
TD-6148: Hotfix changes and production release changes
Nov 26, 2025
76e5329
TD06625
AnjuJose011 Nov 27, 2025
84cdfe5
scriptname update
AnjuJose011 Nov 27, 2025
71a6dab
fixes
AnjuJose011 Nov 27, 2025
cad78f8
include-script
AnjuJose011 Nov 27, 2025
0a79d6d
Update LearningHub.Nhs.Database.sqlproj
AnjuJose011 Nov 27, 2025
4668c06
Update LearningHub.Nhs.Database.sqlproj
AnjuJose011 Nov 27, 2025
09f926d
Merge pull request #1563 from TechnologyEnhancedLearning/TD-6625-Addt…
AnjuJose011 Nov 27, 2025
38ee2a9
Merge branch 'RC' into Develop/Features/TD-6148-Create-a-PoC-mechanis…
sarathlal-sarangadharan Nov 27, 2025
633f28b
Merge pull request #1561 from TechnologyEnhancedLearning/Develop/Feat…
AnjuJose011 Nov 27, 2025
ba904c7
fixed scorm filter
Nov 27, 2025
30969e4
TD-6401
AnjuJose011 Nov 28, 2025
465cfa2
Merge pull request #1566 from TechnologyEnhancedLearning/TD-6410-Upda…
AnjuJose011 Nov 28, 2025
f93a174
TD-6401
AnjuJose011 Nov 28, 2025
1f92c00
Merge pull request #1567 from TechnologyEnhancedLearning/TD-6410-Sit-…
AnjuJose011 Nov 28, 2025
04b9bb8
policy update
AnjuJose011 Nov 28, 2025
d832da0
TD-6628 -Update autosuggest panel to improve result limits and update…
Nov 28, 2025
9c300a7
Policy update to Bold
AnjuJose011 Nov 28, 2025
8f75a86
TD-6384: CORS Policy Changes for Moodle Heart beat
swapnamol-abraham Dec 1, 2025
0a3adef
Merge pull request #1568 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Dec 1, 2025
b493ad8
.
OluwatobiAwe Dec 2, 2025
507f772
Moved UseCors after UseRouting
ColinBeebyHEE Dec 2, 2025
933c310
Merge pull request #1570 from TechnologyEnhancedLearning/TD-6384-Move…
swapnamol-abraham Dec 2, 2025
aa8fda2
Modified code to ensure that trailing slash is removed from Moodle URL
ColinBeebyHEE Dec 2, 2025
3132358
Merge pull request #1571 from TechnologyEnhancedLearning/TD-6384-Move…
swapnamol-abraham Dec 2, 2025
7ab3ead
Merge pull request #1577 from TechnologyEnhancedLearning/Bckup-of-RC-…
swapnamol-abraham Dec 4, 2025
5733df6
Acceptence Use policy - SIT fixes
swapnamol-abraham Dec 4, 2025
4a0b74a
dabricks update
OluwatobiAwe Dec 4, 2025
042fb60
update
OluwatobiAwe Dec 4, 2025
7937258
Merge pull request #1578 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Dec 4, 2025
bbc1f5f
Merge pull request #1579 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Dec 4, 2025
e8e51e5
Test file
swapnamol-abraham Dec 4, 2025
7026c2d
Track course click
Dec 4, 2025
ce26c41
Pin the EXACT version vue-ctk-date-time-picker to see whether it fixe…
Dec 4, 2025
cee881a
Pin the EXACT version vue-ctk-date-time-picker
Dec 4, 2025
747c451
Merge pull request #1580 from TechnologyEnhancedLearning/Develop/Fixe…
binon Dec 4, 2025
a56c781
Permission update
OluwatobiAwe Dec 4, 2025
f360366
MERGE
OluwatobiAwe Dec 4, 2025
57a0314
Merge branch 'RC' into Develop/Fixes/TD-6100-refactor-latest
swapnamol-abraham Dec 4, 2025
1649450
Merge pull request #1581 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Dec 4, 2025
88f9ce4
Menu Permission Update
OluwatobiAwe Dec 5, 2025
721e336
Merge pull request #1582 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Dec 5, 2025
1eb04ab
corrected the wording
swapnamol-abraham Dec 5, 2025
840cfe4
Merge pull request #1583 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Dec 5, 2025
14d0815
TD-6653: Fixed pagination issue on update place of work screen.
ArunimaGeorge Dec 5, 2025
ee40571
Merge pull request #1584 from TechnologyEnhancedLearning/Develop/Fixe…
ArunimaGeorge Dec 5, 2025
4a426a3
Td-6646 and TD-6661
Dec 9, 2025
9d1b38a
TD-6652 fixes
OluwatobiAwe Dec 10, 2025
b53a1ba
Merge pull request #1592 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Dec 10, 2025
2add541
Addition of StatMandId config
OluwatobiAwe Dec 12, 2025
217f32b
TD-6652 Update
OluwatobiAwe Dec 16, 2025
4367f91
Date error message update
OluwatobiAwe Dec 16, 2025
0ccba55
Merge pull request #1597 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Dec 17, 2025
425d069
TD-6520 : Refractored the SP to fix DTU Spike
swapnamol-abraham Dec 17, 2025
44b0289
Merge pull request #1601 from TechnologyEnhancedLearning/Decelop/Fixe…
swapnamol-abraham Dec 17, 2025
bf7a3ba
Reporter Permission check to be included for General User
OluwatobiAwe Dec 22, 2025
aebf284
TD-6741 Update
OluwatobiAwe Jan 5, 2026
f36b786
Merge pull request #1623 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Jan 5, 2026
0a47ba6
Merge pull request #1612 from TechnologyEnhancedLearning/Develop/Fixe…
OluwatobiAwe Jan 5, 2026
881172a
Deployment Scipt
OluwatobiAwe Jan 5, 2026
d60cf4f
Merge remote-tracking branch 'origin/RC' into Report_Deployment_Script
OluwatobiAwe Jan 5, 2026
d6c5435
script update and course list fix
OluwatobiAwe Jan 5, 2026
c890881
Merge pull request #1624 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 5, 2026
8a4e45f
Caps update
OluwatobiAwe Jan 5, 2026
64f0f07
Merge pull request #1625 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 5, 2026
dbc9e65
Course Casing at the API and report notification upate
OluwatobiAwe Jan 5, 2026
fdb4b66
Merge pull request #1626 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 5, 2026
dd4392b
.
OluwatobiAwe Jan 5, 2026
8410763
Additional error message and status formating
OluwatobiAwe Jan 6, 2026
51c0496
Merge remote-tracking branch 'origin/RC' into Report_Deployment_Script
OluwatobiAwe Jan 6, 2026
88b594e
Merge pull request #1627 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 6, 2026
e5f931a
inject build number in to swagger
swapnamol-abraham Jan 6, 2026
8d632f4
Update azure-pipeline-openapi-reportapi-ci.yml
swapnamol-abraham Jan 6, 2026
a2b992b
Merge pull request #1630 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Jan 6, 2026
42c78d4
Text casing and Email Template variable update
OluwatobiAwe Jan 7, 2026
01378e4
.
OluwatobiAwe Jan 7, 2026
a6434de
Merge pull request #1631 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 7, 2026
fb05018
Remove build number injection from Swagger definition
swapnamol-abraham Jan 7, 2026
aafb214
TD-6752: Include Build Number in OpenAPI Swagger JSON
swapnamol-abraham Jan 7, 2026
78106f0
Removed the commented line
swapnamol-abraham Jan 7, 2026
e580cb2
bugfix for existing report update
OluwatobiAwe Jan 7, 2026
850958c
Merge remote-tracking branch 'origin/RC' into Report_Deployment_Script
OluwatobiAwe Jan 7, 2026
eedeeb6
Merge pull request #1633 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 7, 2026
49d1706
Merge pull request #1632 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Jan 8, 2026
2b07109
Report Downloa issue fix
OluwatobiAwe Jan 9, 2026
3525dab
Merge pull request #1634 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 9, 2026
23f91b2
Null check to rediect user that are yet to populate form wizard
OluwatobiAwe Jan 9, 2026
054f11c
Merge pull request #1635 from TechnologyEnhancedLearning/Report_Deplo…
OluwatobiAwe Jan 9, 2026
177e6b7
Bugfix for error when alternating between predefined date and custom …
OluwatobiAwe Jan 13, 2026
8b26308
Merge pull request #1643 from TechnologyEnhancedLearning/Report_DateR…
OluwatobiAwe Jan 13, 2026
a787b55
Td-6760: Duplicate record in synced elfh tables in the LH database
swapnamol-abraham Jan 13, 2026
1d8a260
Merge pull request #1644 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Jan 13, 2026
0d595d2
Revert "Td-6760: Duplicate record in synced elfh tables in the LH dat…
AnjuJose011 Jan 13, 2026
040d13c
Merge pull request #1645 from TechnologyEnhancedLearning/revert-1644-…
AnjuJose011 Jan 13, 2026
8e6a6de
TD-6760: Duplicate record in synced elfh tables in the LH database
swapnamol-abraham Jan 14, 2026
0ae9e35
Merge branch 'RC' into Develop/Fixes/TD-6760-Duplicate-record-in-sync…
swapnamol-abraham Jan 14, 2026
2e4df1f
Merge pull request #1646 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Jan 14, 2026
0246cd6
changes
AnjuJose011 Feb 3, 2026
a189bdd
Merge pull request #1661 from TechnologyEnhancedLearning/Test-CTC-Dis…
AnjuJose011 Feb 3, 2026
381056c
Update ActivityController.cs
AnjuJose011 Feb 3, 2026
c99b0e5
Update Script.PreDeployment.sql
AnjuJose011 Feb 3, 2026
8af36fe
Update Script.PreDeployment.sql
AnjuJose011 Feb 3, 2026
4935124
Update Script.PreDeployment.sql
AnjuJose011 Feb 4, 2026
a6401cc
Merging RC changes
Feb 5, 2026
f4bfb05
TD-6860: My Learning history page issue
swapnamol-abraham Feb 5, 2026
e65ca88
Merge pull request #1666 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 5, 2026
3cad0b1
Merge pull request #1665 from TechnologyEnhancedLearning/Develop/Feat…
AnjuJose011 Feb 5, 2026
210a90d
TD-6865, removed the dupliate DI and moved the view
Feb 6, 2026
dbc53c1
Split the views
Feb 6, 2026
c2aedf3
Filename consistency
Feb 6, 2026
c903dc3
Updated the file names according to the naming standard
Feb 6, 2026
86f38e7
chnages the view to build from None
Feb 6, 2026
d74c198
Merge pull request #1671 from TechnologyEnhancedLearning/Develop/Feat…
AnjuJose011 Feb 6, 2026
213945c
TD-6864 Feature flag for InPlatform reporting
OluwatobiAwe Feb 11, 2026
910ad07
Merge pull request #1683 from TechnologyEnhancedLearning/Develop/Feat…
OluwatobiAwe Feb 11, 2026
bcbf080
TD-6869, fix the issue showing unpublished resources on auto suggestion
Feb 12, 2026
f55c34d
Merge pull request #1686 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 12, 2026
87cdc5e
Postporcessing the sort for azure sematic search
Feb 12, 2026
01a764c
Refactored and moved some configs to app settings
Feb 13, 2026
c3b4105
Merge pull request #1690 from TechnologyEnhancedLearning/Develop/Feat…
AnjuJose011 Feb 13, 2026
12cf750
fixed the issue with general user
Feb 13, 2026
35182fc
Merge pull request #1691 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 13, 2026
b2aacaf
TD-6873: Fixed style issues on auto suggestion results during tabbing
ArunimaGeorge Feb 16, 2026
7a49236
Merge pull request #1695 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 16, 2026
32c76cd
TD-6873: Fixed keyboard arrows accessing the auto suggestion results.
ArunimaGeorge Feb 18, 2026
a46550b
Merge pull request #1697 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 18, 2026
dc23e97
Merge pull request #1680 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Feb 10, 2026
6deba09
.
OluwatobiAwe Feb 23, 2026
214d0f5
update
OluwatobiAwe Feb 23, 2026
5b3808d
fixes-6889
AnjuJose011 Feb 23, 2026
df49bf6
Merge pull request #1711 from TechnologyEnhancedLearning/TD-6889-Remo…
AnjuJose011 Feb 24, 2026
481d12c
Merge pull request #1709 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Feb 25, 2026
80acd38
TD-6928 : Issue needs fixing alignment of few 'Search' results with l…
swapnamol-abraham Feb 26, 2026
de48a00
Merge pull request #1712 from TechnologyEnhancedLearning/Develop/Fixe…
swapnamol-abraham Feb 26, 2026
5791d5b
TD-6923: Fixed console error during auto suggestion search results
ArunimaGeorge Feb 27, 2026
6f50991
Merge pull request #1716 from TechnologyEnhancedLearning/Develop/Fixe…
ArunimaGeorge Feb 27, 2026
b5dec77
Fix for the audience access level filter, still need to rebuild the i…
Feb 27, 2026
d351d8e
Fixed the date inconsistency
Mar 2, 2026
dfcccf2
Tidied up some code
Mar 2, 2026
6da78ce
Refactored the code
Mar 2, 2026
d359e6a
refactore authored date time
Mar 3, 2026
a115507
Merge pull request #1718 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Mar 3, 2026
4d856c4
Deleted unwanted code
Mar 3, 2026
0be3ae5
TD-6914:fixed the alignment of Catalogue tag showing on 'Catalogue' …
swapnamol-abraham Mar 3, 2026
d93c319
Merge pull request #1720 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Mar 3, 2026
dfa33bc
Cache causing filter issue, sorted it now
Mar 5, 2026
c59f738
Merge pull request #1726 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Mar 5, 2026
83caf8c
Revert "TD-6899 Refactor of Case Completion status"
AnjuJose011 Mar 5, 2026
ed11bd6
Merge pull request #1727 from TechnologyEnhancedLearning/revert-1709-…
AnjuJose011 Mar 5, 2026
bb8cabc
Added new parameter -resource access level for generic user
Mar 5, 2026
e08288a
Merge pull request #1728 from TechnologyEnhancedLearning/Develop/Fixe…
binon Mar 5, 2026
e41c32d
Fixed the issue with filter combos
Mar 11, 2026
9b1e2b1
Merge pull request #1733 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Mar 11, 2026
724a94f
Fixed the facets are limited to 10
Mar 12, 2026
d98349a
Merge pull request #1734 from TechnologyEnhancedLearning/Develop/Fixe…
AnjuJose011 Mar 12, 2026
29aad9a
Handle inconsistenrt resource type
Mar 17, 2026
ab64387
Merge pull request #1741 from TechnologyEnhancedLearning/Develop/Feat…
AnjuJose011 Mar 17, 2026
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
74 changes: 0 additions & 74 deletions .github/dependabot.yml

This file was deleted.

3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,5 @@ obj
/LearningHub.Nhs.WebUI.slnLaunch.user
/LearningHub.Nhs.WebUI.BlazorClient/LearningHub.Nhs.WebUI.BlazorClient.csproj.user
/LearningHub.Nhs.WebUI.BlazorClient/wwwroot/appsettings.Development.json
/LearningHub.Nhs.WebUI.BlazorClient/Properties/launchSettings.json
/LearningHub.Nhs.WebUI.BlazorClient/Properties/launchSettings.json
/.github/dependabot.yml
33 changes: 33 additions & 0 deletions AdminUI/LearningHub.Nhs.AdminUI/Configuration/AzureSearchConfig.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
namespace LearningHub.Nhs.AdminUI.Configuration
{
/// <summary>
/// Configuration settings for Azure AI Search.
/// </summary>
public class AzureSearchConfig
{
/// <summary>
/// Gets or sets the Azure Search service endpoint URL.
/// </summary>
public string ServiceEndpoint { get; set; }

/// <summary>
/// Gets or sets the admin API key for managing indexes and indexers.
/// </summary>
public string AdminApiKey { get; set; }

/// <summary>
/// Gets or sets the query API key for search operations.
/// </summary>
public string QueryApiKey { get; set; }

/// <summary>
/// Gets or sets the name of the search index.
/// </summary>
public string IndexName { get; set; }

/// <summary>
/// Gets or sets the name of the indexer.
/// </summary>
public string IndexerName { get; set; }
}
}
119 changes: 119 additions & 0 deletions AdminUI/LearningHub.Nhs.AdminUI/Controllers/AzureSearchAdmin.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
namespace LearningHub.Nhs.AdminUI.Controllers
{
using System.Threading.Tasks;
using LearningHub.Nhs.AdminUI.Helpers;
using LearningHub.Nhs.AdminUI.Interfaces;
using LearningHub.Nhs.AdminUI.Models;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Logging;
using Microsoft.FeatureManagement;

/// <summary>
/// Controller for Azure Search administration.
/// </summary>
public class AzureSearchAdminController : BaseController
{
private readonly IAzureSearchAdminService azureSearchAdminService;
private readonly IFeatureManager featureManager;
private readonly ILogger<AzureSearchAdminController> logger;

/// <summary>
/// Initializes a new instance of the <see cref="AzureSearchAdminController"/> class.
/// </summary>
/// <param name="hostingEnvironment">The hosting environment.</param>
/// <param name="azureSearchAdminService">The Azure Search admin service.</param>
/// <param name="featureManager">The feature manager.</param>
/// <param name="logger">The logger.</param>
public AzureSearchAdminController(
IWebHostEnvironment hostingEnvironment,
IAzureSearchAdminService azureSearchAdminService,
IFeatureManager featureManager,
ILogger<AzureSearchAdminController> logger)
: base(hostingEnvironment)
{
this.azureSearchAdminService = azureSearchAdminService;
this.featureManager = featureManager;
this.logger = logger;
}

/// <summary>
/// Displays the Azure Search Admin dashboard.
/// </summary>
/// <returns>The view.</returns>
[HttpGet]
public async Task<IActionResult> Index()
{
if (!await this.featureManager.IsEnabledAsync(FeatureFlags.AzureSearch))
{
return this.NotFound();
}

var viewModel = new AzureSearchAdminViewModel
{
Indexers = await this.azureSearchAdminService.GetIndexersStatusAsync(),
Indexes = await this.azureSearchAdminService.GetIndexesStatusAsync(),
};

return this.View(viewModel);
}

/// <summary>
/// Triggers an indexer run.
/// </summary>
/// <param name="indexerName">The name of the indexer to run.</param>
/// <returns>Redirects to Index with status message.</returns>
[HttpPost]
[ValidateAntiForgeryToken]
public async Task<IActionResult> RunIndexer(string indexerName)
{
if (!await this.featureManager.IsEnabledAsync(FeatureFlags.AzureSearch))
{
return this.NotFound();
}

if (string.IsNullOrEmpty(indexerName))
{
return this.BadRequest("Indexer name is required.");
}

var success = await this.azureSearchAdminService.RunIndexerAsync(indexerName);

this.TempData["Message"] = success
? $"Indexer '{indexerName}' has been triggered successfully."
: $"Failed to trigger indexer '{indexerName}'.";
this.TempData["IsError"] = !success;

return this.RedirectToAction("Index");
}

/// <summary>
/// Resets an indexer.
/// </summary>
/// <param name="indexerName">The name of the indexer to reset.</param>
/// <returns>Redirects to Index with status message.</returns>
[HttpPost]
[ValidateAntiForgeryToken]
public async Task<IActionResult> ResetIndexer(string indexerName)
{
if (!await this.featureManager.IsEnabledAsync(FeatureFlags.AzureSearch))
{
return this.NotFound();
}

if (string.IsNullOrEmpty(indexerName))
{
return this.BadRequest("Indexer name is required.");
}

var success = await this.azureSearchAdminService.ResetIndexerAsync(indexerName);

this.TempData["Message"] = success
? $"Indexer '{indexerName}' has been reset successfully. You may now run it to perform a full re-index."
: $"Failed to reset indexer '{indexerName}'.";
this.TempData["IsError"] = !success;

return this.RedirectToAction("Index");
}
}
}
5 changes: 5 additions & 0 deletions AdminUI/LearningHub.Nhs.AdminUI/Helpers/FeatureFlags.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,10 @@ public static class FeatureFlags
/// The DisplayAudioVideo.
/// </summary>
public const string DisplayAudioVideo = "DisplayAudioVideo";

/// <summary>
/// The AzureSearch.
/// </summary>
public const string AzureSearch = "AzureSearch";
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
namespace LearningHub.Nhs.AdminUI.Interfaces
{
using System.Collections.Generic;
using System.Threading.Tasks;
using LearningHub.Nhs.AdminUI.Models;

/// <summary>
/// Interface for Azure Search administration operations.
/// </summary>
public interface IAzureSearchAdminService
{
/// <summary>
/// Gets the status of all indexers.
/// </summary>
/// <returns>A list of indexer statuses.</returns>
Task<List<IndexerStatusViewModel>> GetIndexersStatusAsync();

/// <summary>
/// Gets the status of all indexes.
/// </summary>
/// <returns>A list of index statuses.</returns>
Task<List<IndexStatusViewModel>> GetIndexesStatusAsync();

/// <summary>
/// Runs an indexer manually.
/// </summary>
/// <param name="indexerName">The name of the indexer to run.</param>
/// <returns>True if successful, false otherwise.</returns>
Task<bool> RunIndexerAsync(string indexerName);

/// <summary>
/// Resets an indexer (clears state and allows full reindex).
/// </summary>
/// <param name="indexerName">The name of the indexer to reset.</param>
/// <returns>True if successful, false otherwise.</returns>
Task<bool> ResetIndexerAsync(string indexerName);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
<PackageReference Include="HtmlSanitizer" Version="6.0.453" />
<PackageReference Include="IdentityModel" Version="4.6.0" />
<PackageReference Include="LearningHub.Nhs.Caching" Version="2.0.2" />
<PackageReference Include="LearningHub.Nhs.Models" Version="4.0.3" />
<PackageReference Include="LearningHub.Nhs.Models" Version="4.0.12" />
<PackageReference Include="Microsoft.ApplicationInsights.AspNetCore" Version="2.19.0" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="6.0.36" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="6.0.36" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
<DebuggerFlavor>ProjectDebugger</DebuggerFlavor>
</PropertyGroup>
<PropertyGroup>
<ActiveDebugProfile>IIS Local</ActiveDebugProfile>
<ActiveDebugProfile>Local IIS</ActiveDebugProfile>
<Controller_SelectedScaffolderID>MvcControllerEmptyScaffolder</Controller_SelectedScaffolderID>
<Controller_SelectedScaffolderCategoryPath>root/Common/MVC/Controller</Controller_SelectedScaffolderCategoryPath>
<View_SelectedScaffolderID>RazorViewEmptyScaffolder</View_SelectedScaffolderID>
<View_SelectedScaffolderCategoryPath>root/Common/MVC/View</View_SelectedScaffolderCategoryPath>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
namespace LearningHub.Nhs.AdminUI.Models
{
using System.Collections.Generic;

/// <summary>
/// View model for Azure Search Admin page.
/// </summary>
public class AzureSearchAdminViewModel
{
/// <summary>
/// Gets or sets the list of indexer statuses.
/// </summary>
public List<IndexerStatusViewModel> Indexers { get; set; } = new List<IndexerStatusViewModel>();

/// <summary>
/// Gets or sets the list of index statuses.
/// </summary>
public List<IndexStatusViewModel> Indexes { get; set; } = new List<IndexStatusViewModel>();

/// <summary>
/// Gets or sets a message to display to the user.
/// </summary>
public string Message { get; set; }

/// <summary>
/// Gets or sets a value indicating whether the message is an error.
/// </summary>
public bool IsError { get; set; }
}
}
23 changes: 23 additions & 0 deletions AdminUI/LearningHub.Nhs.AdminUI/Models/IndexStatusViewModel.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
namespace LearningHub.Nhs.AdminUI.Models
{
/// <summary>
/// View model for Azure Search index status.
/// </summary>
public class IndexStatusViewModel
{
/// <summary>
/// Gets or sets the name of the index.
/// </summary>
public string Name { get; set; }

/// <summary>
/// Gets or sets the document count in the index.
/// </summary>
public long? DocumentCount { get; set; }

/// <summary>
/// Gets or sets the storage size in bytes.
/// </summary>
public long? StorageSize { get; set; }
}
}
Loading
Loading