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
15 changes: 15 additions & 0 deletions LearningHub.Nhs.WebUI/Helpers/ViewActivityHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -524,5 +524,20 @@ public static bool CanDownloadCertificate(this ActivityDetailedItemViewModel act

return false;
}

/// <summary>
/// GetReportStatusDisplayText.
/// </summary>
/// <param name="status">The status.</param>
/// <returns>The string.</returns>
public static string GetReportStatusDisplayText(string status)
{
if (status == "Not completed")
{
return "In progress";
}

return status;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
case NotificationType.AccessRequest:
return [{ text: 'Access request', className: 'fas fa-lock-alt text-dark pt-1' }];
case NotificationType.ReportProcessed:
return [{ text: 'Report processed', className: 'fa-solid fa-circle-check text-success' }];
return [{ text: 'Report', className: 'fa-solid fa-circle-check text-success' }];
default:
return [{ text: 'unknown', className: '' }];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,16 @@
<div class="nhsuk-hint">
Create a course progress report
</div>

@if (errorHasOccurred)
{
<vc:error-summary order-of-property-names="@(new[] { nameof(Model.TimePeriod) })" />
}
<h1 class="nhsuk-heading-xl">
Reporting period
</h1>
<div class="nhsuk-u-padding-bottom-9">

@if (errorHasOccurred)
{
<vc:error-summary order-of-property-names="@(new[] { nameof(Model.TimePeriod) })" />
}

<form asp-controller="Reports" asp-action="CreateReportSummary" method="post">
<input type="hidden" name="returnUrl" value="@ViewBag.ReturnUrl" />
@Html.HiddenFor(x=>x.HintText)
Expand All @@ -56,6 +56,16 @@
For the last:
</div>

@if (errorHasOccurred)
{
<div id="TimePeriod-error" class="nhsuk-u-padding-top-1 nhsuk-u-padding-bottom-3">

<span class="error-message--margin-bottom-1 nhsuk-error-message">
<span class="nhsuk-u-visually-hidden">Error:</span> Select a reporting period
</span>
</div>
}

<div class="nhsuk-radios" data-module="nhsuk-radios">
@foreach (var (radio, index) in Model.PopulateDateRange().Select((r, i) => (r, i)))
{
Expand Down
2 changes: 1 addition & 1 deletion LearningHub.Nhs.WebUI/Views/Reports/Index.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
</div>
<div class="nhsuk-summary-list__row">
<dt class="nhsuk-summary-list__key nhsuk-summary-list__key--tight">Type:</dt>
<dd class="nhsuk-summary-list__value">course progress</dd>
<dd class="nhsuk-summary-list__value">Course progress</dd>
</div>
<div class="nhsuk-summary-list__row">
<dt class="nhsuk-summary-list__key nhsuk-summary-list__key--tight">Reporting on:</dt>
Expand Down
4 changes: 2 additions & 2 deletions LearningHub.Nhs.WebUI/Views/Reports/_ReportPaging.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
else
{
<li class="nhsuk-pagination-item--previous">
<a class="nhsuk-pagination__link nhsuk-pagination__link--prev" asp-action="CourseCompletionReport" asp-all-route-data="@previousRouteData">
<a class="nhsuk-pagination__link nhsuk-pagination__link--prev" asp-action="CourseProgressReport" asp-all-route-data="@previousRouteData">
<span class="nhsuk-pagination__title">Previous</span>
<span class="nhsuk-u-visually-hidden">:</span>
<span class="nhsuk-pagination__page">@previousMessage</span>
Expand All @@ -61,7 +61,7 @@
else
{
<li class="nhsuk-pagination-item--next">
<a class="nhsuk-pagination__link nhsuk-pagination__link--next" asp-action="CourseCompletionReport" asp-all-route-data="@nextRouteData">
<a class="nhsuk-pagination__link nhsuk-pagination__link--next" asp-action="CourseProgressReport" asp-all-route-data="@nextRouteData">
<span class="nhsuk-pagination__title">Next</span>
<span class="nhsuk-u-visually-hidden">:</span>
<span class="nhsuk-pagination__page">@nextMessage</span>
Expand Down
2 changes: 1 addition & 1 deletion LearningHub.Nhs.WebUI/Views/Reports/_ReportTable.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@
</td>
<td role="cell" class="nhsuk-table__cell nhsuk-u-font-size-16">
<span class="nhsuk-table-responsive__heading"> Status </span>
<span class="nhsuk-u-text-align-left table-content-spacing">@entry.CourseStatus</span>
<span class="nhsuk-u-text-align-left table-content-spacing">@ViewActivityHelper.GetReportStatusDisplayText(entry.CourseStatus)</span>

</td>
</tr>
Expand Down
Loading