Skip to content

Commit

Permalink
Aligned change request UI with updated Figma designs (#1039)
Browse files Browse the repository at this point in the history
  • Loading branch information
hortha authored Jan 3, 2024
1 parent 78fe30e commit 0d20d96
Show file tree
Hide file tree
Showing 27 changed files with 579 additions and 473 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ namespace TeachingRecordSystem.SupportUi.Infrastructure.Security;

public static class AuthorizationPolicies
{
public const string CaseManagement = "CaseManagement";
public const string ChangeRequestManagement = "ChangeRequestManagement";
public const string Hangfire = "Hangfire";
}

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
@page "/change-requests/{ticketNumber}/accept"
@model TeachingRecordSystem.SupportUi.Pages.ChangeRequests.EditChangeRequest.AcceptModel
@{
ViewBag.Title = "Confirm the change";
}

@section BeforeContent {
<govuk-back-link href="@LinkGenerator.EditChangeRequest(Model.TicketNumber)" />
}

<span class="govuk-caption-l">@Model.CaseType - @Model.PersonName</span>
<h1 class="govuk-heading-l">@ViewBag.Title</h1>

<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds-from-desktop">
<form action="@LinkGenerator.AcceptChangeRequest(Model.TicketNumber)" method="post">
<table class="govuk-table">
<thead class="govuk-table__head">
<tr class="govuk-table__row">
<th scope="col" class="govuk-table__header govuk-!-width-one-quarter"></th>
<th scope="col" class="govuk-table__header">Current</th>
<th scope="col" class="govuk-table__header">New</th>
</tr>
</thead>
@if (Model.CaseType == DqtConstants.NameChangeSubjectTitle)
{
<tbody class="govuk-table__body">
@if (Model.NameChangeRequest!.CurrentFirstName != Model.NameChangeRequest!.NewFirstName)
{
<tr class="govuk-table__row" data-testid="first-name">
<td class="govuk-table__cell govuk-!-font-weight-bold" data-testid="first-name-title">First name</td>
<td class="govuk-table__cell" data-testid="first-name-current">@Model.NameChangeRequest!.CurrentFirstName</td>
<td class="govuk-table__cell" data-testid="first-name-new">@Model.NameChangeRequest!.NewFirstName</td>
</tr>
}
@if (Model.NameChangeRequest!.CurrentMiddleName != Model.NameChangeRequest!.NewMiddleName)
{
<tr class="govuk-table__row" data-testid="middle-name">
<td class="govuk-table__cell govuk-!-font-weight-bold" data-testid="middle-name-title">Middle name</td>
<td class="govuk-table__cell" data-testid="middle-name-current">@Model.NameChangeRequest!.CurrentMiddleName</td>
<td class="govuk-table__cell" data-testid="middle-name-new">@Model.NameChangeRequest!.NewMiddleName</td>
</tr>
}
@if (Model.NameChangeRequest!.CurrentLastName != Model.NameChangeRequest!.NewLastName)
{
<tr class="govuk-table__row" data-testid="last-name">
<td class="govuk-table__cell govuk-!-font-weight-bold" data-testid="last-name-title">Last name</td>
<td class="govuk-table__cell" data-testid="last-name-current">@Model.NameChangeRequest!.CurrentLastName</td>
<td class="govuk-table__cell" data-testid="last-name-new">@Model.NameChangeRequest!.NewLastName</td>
</tr>
}
</tbody>
}
@if (Model.CaseType == DqtConstants.DateOfBirthChangeSubjectTitle)
{
<tbody class="govuk-table__body">
<tr class="govuk-table__row" data-testid="date-of-birth">
<td class="govuk-table__cell govuk-!-font-weight-bold" data-testid="date-of-birth-title">Date of birth</td>
<td class="govuk-table__cell" data-testid="date-of-birth-current">@Model.DateOfBirthChangeRequest!.CurrentDateOfBirth.ToString("d MMMM yyyy")</td>
<td class="govuk-table__cell" data-testid="date-of-birth-new">@Model.DateOfBirthChangeRequest!.NewDateOfBirth.ToString("d MMMM yyyy")</td>
</tr>
</tbody>
}
</table>

<govuk-button type="submit">Confirm</govuk-button>
</form>
</div>
</div>
Loading

0 comments on commit 0d20d96

Please sign in to comment.