-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fb3e390
commit 8cb346c
Showing
4 changed files
with
32 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
using System.ComponentModel.DataAnnotations; | ||
|
||
namespace PetSearch.API.Models; | ||
|
||
/// <summary> | ||
/// The location DTO object to serve to our client application after a successful MapBox API request. | ||
/// </summary> | ||
/// <param name="Zipcode">A five digit zipcode.</param> | ||
/// <param name="LocationName">The location name in the following format: {City}, {State} {Zipcode}, {Country}</param> | ||
public record LocationDto(string Zipcode, string LocationName); | ||
public record LocationDto( | ||
[property: Required] string Zipcode, | ||
[property: Required] string LocationName | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,14 @@ | ||
using System.Text.Json.Serialization; | ||
|
||
namespace PetSearch.API.Models; | ||
|
||
public record PaginationMetaData(int CurrentPage, int TotalPages, int PageSize, int TotalCount); | ||
public record PaginationMetaData( | ||
[property: JsonPropertyName("currentPage")] | ||
int CurrentPage, | ||
[property: JsonPropertyName("totalPages")] | ||
int TotalPages, | ||
[property: JsonPropertyName("pageSize")] | ||
int PageSize, | ||
[property: JsonPropertyName("totalCount")] | ||
int TotalCount | ||
); |