Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Commit

Permalink
Merge pull request #10 from DFE-Digital/feature/academies-api-contracts
Browse files Browse the repository at this point in the history
Feature/academies api contracts
  • Loading branch information
paullocknimble authored Nov 7, 2023
2 parents 63bff39 + 6c5f23f commit b047e12
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
<RepositoryUrl>https://github.com/DFE-Digital/academisation-nuget-packages</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<Version>1.0.3</Version>
<AssemblyVersion>1.0.4</AssemblyVersion>
</PropertyGroup>

<ItemGroup>
Expand Down
22 changes: 22 additions & 0 deletions academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
namespace Dfe.Academies.Contracts.V4;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

[Serializable]
public class AddressDto
{
public string Street { get; set; }

Check warning on line 11 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Street' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 11 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Street' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

public string Town { get; set; }

Check warning on line 13 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Town' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 13 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Town' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

public string County { get; set; }

Check warning on line 15 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'County' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 15 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'County' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

public string Postcode { get; set; }

Check warning on line 17 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Postcode' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 17 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Postcode' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

public string Locality { get; set; }

Check warning on line 19 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Locality' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 19 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Locality' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

public string Additional { get; set; }

Check warning on line 21 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Additional' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.

Check warning on line 21 in academiesContracts/Dfe.Academies.Contracts/V4/AddressDto.cs

View workflow job for this annotation

GitHub Actions / build

Non-nullable property 'Additional' must contain a non-null value when exiting constructor. Consider declaring the property as nullable.
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
namespace Dfe.Academies.Contracts.Establishments;

using Dfe.Academies.Contracts.Trusts;
namespace Dfe.Academies.Contracts.V4.Establishments;

[Serializable]
public class EstablishmentDto
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
namespace Dfe.Academies.Contracts.V4;
using System.Collections.Generic;

[Serializable]
public class PagedDataResponse<TResponse> where TResponse : class
{

Expand All @@ -18,6 +19,8 @@ public PagedDataResponse(IEnumerable<TResponse> data, PagingResponse pagingRespo
public PagedDataResponse(TResponse data) => Data = new List<TResponse> { data };

}

[Serializable]
public class PagingResponse
{
public int Page { get; set; }
Expand Down
18 changes: 1 addition & 17 deletions academiesContracts/Dfe.Academies.Contracts/V4/Trusts/TrustDto.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Dfe.Academies.Contracts.Trusts;
namespace Dfe.Academies.Contracts.V4.Trusts;

[Serializable]
public class TrustDto
Expand All @@ -14,19 +14,3 @@ public class TrustDto
public AddressDto Address { get; set; }

}

[Serializable]
public class AddressDto
{
public string Street { get; set; }

public string Town { get; set; }

public string County { get; set; }

public string Postcode { get; set; }

public string Locality { get; set; }

public string Additional { get; set; }
}

0 comments on commit b047e12

Please sign in to comment.