diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Contracts/Project/ProjectOverviewResponse.cs b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Contracts/Project/ProjectOverviewResponse.cs index c0b512b65..288d0587b 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Contracts/Project/ProjectOverviewResponse.cs +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Contracts/Project/ProjectOverviewResponse.cs @@ -87,7 +87,7 @@ public record ProjectRiskOverviewResponse public record PupilNumbersOverviewResponse { - public int Capacity { get; set; } + public int TotalCapacity { get; set; } public int Pre16PublishedAdmissionNumber { get; set; } public int Post16PublishedAdmissionNumber { get; set; } public int MinimumViableNumberForFirstYear { get; set; } diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Tests/Integration/ProjectOverviewApiTests.cs b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Tests/Integration/ProjectOverviewApiTests.cs index 9dbd14fc6..ba621ecbc 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Tests/Integration/ProjectOverviewApiTests.cs +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API.Tests/Integration/ProjectOverviewApiTests.cs @@ -115,7 +115,7 @@ public async Task When_Get_AllFieldsSet_Returns_200() // Pupil numbers var pupilNumbers = result.Data.PupilNumbers; - pupilNumbers.Capacity.Should().Be(300); + pupilNumbers.TotalCapacity.Should().Be(300); pupilNumbers.Pre16PublishedAdmissionNumber.Should().Be(15); pupilNumbers.Post16PublishedAdmissionNumber.Should().Be(67); pupilNumbers.MinimumViableNumberForFirstYear.Should().Be(121); @@ -165,7 +165,7 @@ public async Task When_Get_MandatoryFieldsSet_Returns_200() // Pupil numbers var pupilNumbers = result.Data.PupilNumbers; - pupilNumbers.Capacity.Should().Be(0); + pupilNumbers.TotalCapacity.Should().Be(0); pupilNumbers.Pre16PublishedAdmissionNumber.Should().Be(0); pupilNumbers.Post16PublishedAdmissionNumber.Should().Be(0); pupilNumbers.MinimumViableNumberForFirstYear.Should().Be(0); diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API/UseCases/ProjectOverview/GetProjectOverviewService.cs b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API/UseCases/ProjectOverview/GetProjectOverviewService.cs index 69ebdc2d9..7b4b48f61 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API/UseCases/ProjectOverview/GetProjectOverviewService.cs +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.API/UseCases/ProjectOverview/GetProjectOverviewService.cs @@ -19,22 +19,11 @@ public interface IGetProjectOverviewService public Task Execute(string projectId); } - public class GetProjectOverviewService : IGetProjectOverviewService + public class GetProjectOverviewService(MfspContext context, IGetProjectSitesService getProjectSitesService) : IGetProjectOverviewService { - private readonly MfspContext _context; - private readonly IGetProjectSitesService _getProjectSitesService; - - public GetProjectOverviewService( - MfspContext context, - IGetProjectSitesService getProjectSitesService) - { - _context = context; - _getProjectSitesService = getProjectSitesService; - } - public async Task Execute(string projectId) { - var project = await _context.Kpi.FirstOrDefaultAsync(k => k.ProjectStatusProjectId == projectId); + var project = await context.Kpi.FirstOrDefaultAsync(k => k.ProjectStatusProjectId == projectId); if (project == null) { @@ -42,19 +31,18 @@ public async Task Execute(string projectId) } var risk = await GetRisk(project.Rid); - var sites = await _getProjectSitesService.Execute(project); + var sites = await getProjectSitesService.Execute(project); var pupilNumbers = await GetPupilNumbers(project.Rid); return BuildOverviewResponse(project, risk, sites, pupilNumbers); } private static ProjectOverviewResponse BuildOverviewResponse( - Kpi project, - ProjectRiskOverviewResponse risk, - GetProjectSitesResponse sites, + Kpi project, + ProjectRiskOverviewResponse risk, + GetProjectSitesResponse sites, PupilNumbersOverviewResponse pupilNumbers) { - var projectOverviewResponse = new ProjectOverviewResponse() { ProjectStatus = new ProjectStatusResponse() @@ -116,17 +104,18 @@ private static ProjectOverviewResponse BuildOverviewResponse( PupilNumbers = pupilNumbers }; - projectOverviewResponse.ProjectType = projectOverviewResponse.ProjectStatus.ApplicationWave == "FS - Presumption" + projectOverviewResponse.ProjectType = + projectOverviewResponse.ProjectStatus.ApplicationWave == "FS - Presumption" ? "Presumption" : "Central Route"; - return projectOverviewResponse; + return projectOverviewResponse; } - + private async Task GetRisk(string rid) { - var rag = await _context.Rag - .Select(e => new + var rag = await context.Rag + .Select(e => new { e.Rid, RiskRating = e.RagRatingsOverallRagRating, @@ -134,7 +123,7 @@ private async Task GetRisk(string rid) Date = EF.Property(e, "PeriodStart") }).FirstOrDefaultAsync(r => r.Rid == rid); - if (rag == null) + if (rag == null) { return new ProjectRiskOverviewResponse(); } @@ -151,31 +140,21 @@ private async Task GetRisk(string rid) private async Task GetPupilNumbers(string rid) { - var result = await _context.Po + var result = await context.Po .Where(p => p.Rid == rid) - .Select(po => - new PupilNumbersOverviewResponse() + .Select(po => new PupilNumbersOverviewResponse { - Capacity = po.PupilNumbersAndCapacityNurseryUnder5s.ToInt() + - po.PupilNumbersAndCapacityYrY6Capacity.ToInt() + - po.PupilNumbersAndCapacityY7Y11Capacity.ToInt() + - po.PupilNumbersAndCapacityY12Y14Post16Capacity.ToInt() + - po.PupilNumbersAndCapacitySpecialistResourceProvisionSpecial.ToInt() + - po.PupilNumbersAndCapacitySpecialistResourceProvisionAp.ToInt(), + TotalCapacity = po.PupilNumbersAndCapacityTotalOfCapacityTotals.ToInt(), Pre16PublishedAdmissionNumber = po.PupilNumbersAndCapacityTotalPanPre16.ToInt(), Post16PublishedAdmissionNumber = po.PupilNumbersAndCapacityTotalPanPost16.ToInt(), - MinimumViableNumberForFirstYear = po.PupilNumbersAndCapacityMinimumFirstYearRecruitmentForViabilityTotal.ToInt(), + MinimumViableNumberForFirstYear = + po.PupilNumbersAndCapacityMinimumFirstYearRecruitmentForViabilityTotal.ToInt(), ApplicationsReceived = po.PupilNumbersAndCapacityNoApplicationsReceivedTotal.ToInt(), AcceptedOffers = po.PupilNumbersAndCapacityNoApplicationsAcceptedTotal.ToInt(), }) .FirstOrDefaultAsync(); - if (result == null) - { - return new PupilNumbersOverviewResponse(); - } - - return result; + return result ?? new PupilNumbersOverviewResponse(); } } -} +} \ No newline at end of file diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/e2e/project-pupil-numbers.cy.ts b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/e2e/project-pupil-numbers.cy.ts index 85cfebb3d..572c4c17a 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/e2e/project-pupil-numbers.cy.ts +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/e2e/project-pupil-numbers.cy.ts @@ -111,7 +111,7 @@ describe("Testing the setting of pupil numbers", () => { .hasYear12ToYear14("40") .hasSpecialEducationalNeeds("50") .hasAlternativeProvision("60") - .hasTotal("210"); + .hasTotal("90"); }); it("Should be able to edit the pre-16 published admission numbers", () => { @@ -592,7 +592,7 @@ describe("Testing the setting of pupil numbers", () => { viewPupilNumbersPage.backToProjectOverview(); pupilNumbersSummaryComponent - .hasCapacity("210") + .hasCapacity("90") .hasPre16PublishedAdmissionNumber("110") .hasPost16PublishedAdmissionNumber("35") .hasMinimumViableNumber("168") diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/pages/pupil-numbers/pupilNumbersSummaryComponent.ts b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/pages/pupil-numbers/pupilNumbersSummaryComponent.ts index a3556a1c1..7b531da9e 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/pages/pupil-numbers/pupilNumbersSummaryComponent.ts +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects.CypressTests/cypress/pages/pupil-numbers/pupilNumbersSummaryComponent.ts @@ -1,7 +1,7 @@ class PupilNumbersSummaryComponent { public hasCapacity(value: string): this { - cy.getByTestId("capacity").should("contain.text", value); + cy.getByTestId("total-capacity").should("contain.text", value); return this; } diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/ProjectOverview.cshtml b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/ProjectOverview.cshtml index 8904af857..05f01f395 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/ProjectOverview.cshtml +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/ProjectOverview.cshtml @@ -514,10 +514,10 @@
- Capacity + Total capacity
-
- @Model.Project.PupilNumbers.Capacity +
+ @Model.Project.PupilNumbers.TotalCapacity
diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/EditCapacityWhenFull.cshtml b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/EditCapacityWhenFull.cshtml index b9d555e47..dbb8f3273 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/EditCapacityWhenFull.cshtml +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/EditCapacityWhenFull.cshtml @@ -27,6 +27,39 @@ + + + + + + + + + + + + + + + + + + + + +
Edit Capacity when full
School groupCapacity
Reception to year 6 + +
Year 7 to year 11 + + +
Year 12 to year 14 + + +
+ + + + @@ -40,27 +73,6 @@ - - - - - - - - - - - - + + + + +
Nursery and specialist resource provision
School group
Reception to year 6 - - -
Year 7 to year 11 - - -
Year 12 to year 14 - - -
Special educational needs (specialist resource provision) diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml index 73489c636..02dfcb851 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml @@ -28,288 +28,311 @@ }
- @if (Model.ShowBanner) - { -
+ Total capacity + @capacityWhenFull.Total
- Edit Pre-16 PAN + + + + + + + + + + + + + + + + + + + + + + +
Capacity when full - nursery and specialist resource provision
School groupCapacity
Nursery@capacityWhenFull.Nursery
Special educational needs (specialist resource provision)@capacityWhenFull.SpecialEducationNeeds
Alternative provision (specialist resource provision)@capacityWhenFull.AlternativeProvision
- - - - - - - - - - - - - - - - - - - - - - -
Post-16 published admission number (PAN)
School yearPAN in first year of opening
Year 12@post16PublishedAdmissionNumber.Year12
Other post-16@post16PublishedAdmissionNumber.OtherPost16
Total - @post16PublishedAdmissionNumber.Total -
+Edit Capacity when full - Edit Post-16 PAN + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Pre-16 published admission number (PAN)
School yearPAN in first year of opening
Reception@pre16PublishedAdmissionNumber.Reception
Year 7@pre16PublishedAdmissionNumber.Year7
Year 10@pre16PublishedAdmissionNumber.Year10
Other pre-16@pre16PublishedAdmissionNumber.OtherPre16
+ Total + + @pre16PublishedAdmissionNumber.Total +
+Edit Pre-16 PAN - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Recruitment and viability
School yearMinimum viable number (MVN) for first yearApplications receivedPercentage received compared to MVNPercentage received compared to published admission number (PAN)Accepted OffersPercentage accepted compared to MVNPercentage accepted compared to published admission number (PAN)
Reception to year 6@recruitmentAndViability.ReceptionToYear6.MinimumViableNumber@recruitmentAndViability.ReceptionToYear6.ApplicationsReceived@recruitmentAndViability.ReceptionToYear6.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.AcceptedOffers@recruitmentAndViability.ReceptionToYear6.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
Year 7 to year 11@recruitmentAndViability.Year7ToYear11.MinimumViableNumber@recruitmentAndViability.Year7ToYear11.ApplicationsReceived@recruitmentAndViability.Year7ToYear11.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.AcceptedOffers@recruitmentAndViability.Year7ToYear11.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
Year 12 to year 14@recruitmentAndViability.Year12ToYear14.MinimumViableNumber@recruitmentAndViability.Year12ToYear14.ApplicationsReceived@recruitmentAndViability.Year12ToYear14.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.AcceptedOffers@recruitmentAndViability.Year12ToYear14.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
Total - @recruitmentAndViability.Total.MinimumViableNumber - - @recruitmentAndViability.Total.ApplicationsReceived - - - - @recruitmentAndViability.Total.AcceptedOffers - - -
- Edit Recruitment and viability + + + + + + + + + + + + + + + + + + + + + + +
Post-16 published admission number (PAN)
School yearPAN in first year of opening
Year 12@post16PublishedAdmissionNumber.Year12
Other post-16@post16PublishedAdmissionNumber.OtherPost16
+ Total + + @post16PublishedAdmissionNumber.Total +
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Pre-16 capacity build-up
School yearCurrent capacity (if school is open)First yearSecond yearThird yearFourth yearFifth yearSixth yearSeventh year
+Edit Post-16 PAN - Edit Pre-16 capacity buildup + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Recruitment and viability
School yearMinimum viable number (MVN) for first yearApplications receivedPercentage received compared to MVNPercentage received compared to published admission number (PAN)Accepted OffersPercentage accepted compared to MVNPercentage accepted compared to published admission number (PAN)
Reception to year 6@recruitmentAndViability.ReceptionToYear6.MinimumViableNumber@recruitmentAndViability.ReceptionToYear6.ApplicationsReceived@recruitmentAndViability.ReceptionToYear6.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.AcceptedOffers@recruitmentAndViability.ReceptionToYear6.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.ReceptionToYear6.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
Year 7 to year 11@recruitmentAndViability.Year7ToYear11.MinimumViableNumber@recruitmentAndViability.Year7ToYear11.ApplicationsReceived@recruitmentAndViability.Year7ToYear11.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.AcceptedOffers@recruitmentAndViability.Year7ToYear11.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year7ToYear11.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
Year 12 to year 14@recruitmentAndViability.Year12ToYear14.MinimumViableNumber@recruitmentAndViability.Year12ToYear14.ApplicationsReceived@recruitmentAndViability.Year12ToYear14.ReceivedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.ReceivedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.AcceptedOffers@recruitmentAndViability.Year12ToYear14.AcceptedPercentageComparedToMinimumViable.ToPercentageWith2Dp()@recruitmentAndViability.Year12ToYear14.AcceptedPercentageComparedToPublishedAdmissionNumber.ToPercentageWith2Dp()
+ Total + + @recruitmentAndViability.Total.MinimumViableNumber + + @recruitmentAndViability.Total.ApplicationsReceived + + + + @recruitmentAndViability.Total.AcceptedOffers + + +
- - - - - - - - - - - - - - - - - - - - - -
Post-16 capacity build-up
School yearCurrent capacity (if school is open)First yearSecond yearThird yearFourth yearFifth yearSixth yearSeventh year
+Edit Recruitment and viability - Edit Post-16 capacity buildup + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Pre-16 capacity build-up
School yearCurrent capacity (if school is open)First yearSecond yearThird yearFourth yearFifth yearSixth yearSeventh year
-
-
+Edit Pre-16 capacity buildup -

- Related tasks -

-

You may want to complete the following related tasks.

+ + + + + + + + + + + + + + + + + + + + + +
Post-16 capacity build-up
School yearCurrent capacity (if school is open)First yearSecond yearThird yearFourth yearFifth yearSixth yearSeventh year
-
    - -
-
    - -
-
-
+Edit Post-16 capacity buildup + +
+
+ +

+ Related tasks +

+ +

You may want to complete the following related tasks.

+ +
    + +
+
    + +
+
+ \ No newline at end of file diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml.cs b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml.cs index fbcb4b857..49d179992 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml.cs +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/PupilNumbers/ViewPupilNumbers.cshtml.cs @@ -7,7 +7,7 @@ namespace Dfe.ManageFreeSchoolProjects.Pages.Project.PupilNumbers { - public class ViewPupilNumbersModel : PageModel + public class ViewPupilNumbersModel(IGetPupilNumbersService getPupilNumbersService, IGetProjectByTaskSummaryService getProjectByTaskSummaryService) : PageModel { [BindProperty(SupportsGet = true, Name = "projectId")] public string ProjectId { get; set; } @@ -19,32 +19,17 @@ public class ViewPupilNumbersModel : PageModel [BindProperty(SupportsGet = true, Name = "fromSaveForm")] public bool ShowBanner { get; set; } - private readonly IGetPupilNumbersService _getPupilNumbersService; - private readonly IGetProjectByTaskSummaryService _getProjectByTaskSummaryService; - - public ViewPupilNumbersModel( - IGetPupilNumbersService getPupilNumbersService, - IGetProjectByTaskSummaryService getProjectByTaskSummaryService) - { - _getPupilNumbersService = getPupilNumbersService; - _getProjectByTaskSummaryService = getProjectByTaskSummaryService; - } - public async Task OnGet() { - PupilNumbers = await _getPupilNumbersService.Execute(ProjectId); + PupilNumbers = await getPupilNumbersService.Execute(ProjectId); - PupilNumbers.CapacityWhenFull.Total = PupilNumbers.CapacityWhenFull.ReceptionToYear6 + - PupilNumbers.CapacityWhenFull.Year7ToYear11 + - PupilNumbers.CapacityWhenFull.Year12ToYear14 + - PupilNumbers.CapacityWhenFull.Nursery + - PupilNumbers.CapacityWhenFull.SpecialEducationNeeds + - PupilNumbers.CapacityWhenFull.AlternativeProvision; + PupilNumbers.CapacityWhenFull.Total = PupilNumbers.CapacityWhenFull.ReceptionToYear6 + + PupilNumbers.CapacityWhenFull.Year7ToYear11 + + PupilNumbers.CapacityWhenFull.Year12ToYear14; - - ProjectTaskListSummary = await _getProjectByTaskSummaryService.Execute(ProjectId); + ProjectTaskListSummary = await getProjectByTaskSummaryService.Execute(ProjectId); return Page(); } } -} +} \ No newline at end of file diff --git a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/Tasks/PupilNumbersChecks/ViewPupilNumbersChecksTask.cshtml.cs b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/Tasks/PupilNumbersChecks/ViewPupilNumbersChecksTask.cshtml.cs index 4130cd398..df72d4aea 100644 --- a/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/Tasks/PupilNumbersChecks/ViewPupilNumbersChecksTask.cshtml.cs +++ b/Dfe.ManageFreeSchoolProjects/Dfe.ManageFreeSchoolProjects/Pages/Project/Tasks/PupilNumbersChecks/ViewPupilNumbersChecksTask.cshtml.cs @@ -5,29 +5,20 @@ using Microsoft.AspNetCore.Mvc; using Microsoft.Extensions.Logging; using System.Threading.Tasks; -using Dfe.ManageFreeSchoolProjects.API.Contracts.Project; using Dfe.ManageFreeSchoolProjects.Logging; namespace Dfe.ManageFreeSchoolProjects.Pages.Project.Tasks.PupilNumbersChecks { - public class ViewPupilNumbersChecksModel : ViewTaskBaseModel + public class ViewPupilNumbersChecksModel( + IGetProjectByTaskService getProjectService, + ILogger logger, + IGetTaskStatusService getTaskStatusService, + IUpdateTaskStatusService updateTaskStatusService) + : ViewTaskBaseModel(getProjectService, getTaskStatusService, updateTaskStatusService) { - public ProjectByTaskSummaryResponse ProjectTaskListSummary { get; set; } - - private readonly ILogger _logger; - - public ViewPupilNumbersChecksModel( - IGetProjectByTaskService getProjectService, - ILogger logger, - IGetTaskStatusService getTaskStatusService, IUpdateTaskStatusService updateTaskStatusService) : base(getProjectService, getTaskStatusService, updateTaskStatusService) - { - _logger = logger; - } - public ProjectOverviewResponse ProjectOverview { get; set; } - public async Task OnGet() { - _logger.LogMethodEntered(); + logger.LogMethodEntered(); await GetTask(TaskName.PupilNumbersChecks); @@ -36,7 +27,7 @@ public async Task OnGet() public async Task OnPost() { - _logger.LogMethodEntered(); + logger.LogMethodEntered(); await PostTask(TaskName.PupilNumbersChecks);