Sube carpetas API, API.Tests, Application y Domain del Backend
This commit is contained in:
@@ -0,0 +1,56 @@
|
||||
using Application.DTOs.Abstract.Response;
|
||||
using Application.DTOs.Team.Response;
|
||||
using Application.DTOs.Venue.Response;
|
||||
|
||||
using System;
|
||||
|
||||
namespace Application.DTOs.Match.Response;
|
||||
|
||||
/// <summary>
|
||||
/// Represents the response data for a match.
|
||||
/// </summary>
|
||||
public class DetailedMatchResponse : BaseEntityResponse
|
||||
{
|
||||
public required DateTime MatchDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The 1-based matchday this match belongs to; null for stages with no round-robin matchday.
|
||||
/// </summary>
|
||||
public int? Round { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The type of the match, regular or playoff.
|
||||
/// </summary>
|
||||
public required string MatchType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The unique, URL-friendly identifier used in public match links.
|
||||
/// </summary>
|
||||
public required string Slug { get; set; }
|
||||
|
||||
public TeamDetailedMatchResponse? HomeTeam { get; set; }
|
||||
|
||||
public TeamDetailedMatchResponse? VisitorTeam { get; set; }
|
||||
|
||||
public VenueResponse? Venue { get; set; }
|
||||
|
||||
public required bool IsFinished { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The result lifecycle state: Scheduled, Played, Suspended, or WalkOver.
|
||||
/// </summary>
|
||||
public string? Status { get; set; }
|
||||
|
||||
public bool WentToOvertime { get; set; }
|
||||
|
||||
public string? WinningTeamName { get; set; }
|
||||
|
||||
public Guid? WinningTeamId { get; set; }
|
||||
|
||||
public Guid? StageId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The id of the tournament this match belongs to, letting the public page link back to it directly.
|
||||
/// </summary>
|
||||
public Guid? TournamentId { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
using Application.DTOs.Abstract.Response;
|
||||
|
||||
using System;
|
||||
|
||||
namespace Application.DTOs.Match.Response;
|
||||
|
||||
/// <summary>
|
||||
/// Represents the minimal response data for a match, tailored for divisions.
|
||||
/// </summary>
|
||||
public class MinimalMatchResponse : BaseEntityResponse
|
||||
{
|
||||
public required DateTime MatchDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The 1-based matchday this match belongs to; null for stages with no round-robin matchday.
|
||||
/// </summary>
|
||||
public int? Round { get; set; }
|
||||
|
||||
public required string HomeTeamName { get; set; }
|
||||
|
||||
public required string VisitorTeamName { get; set; }
|
||||
|
||||
public int? HomeScore { get; set; }
|
||||
|
||||
public int? VisitorScore { get; set; }
|
||||
|
||||
public string? WinningTeamName { get; set; }
|
||||
|
||||
public required bool IsFinished { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The result lifecycle state: Scheduled, Played, Suspended, or WalkOver.
|
||||
/// </summary>
|
||||
public string? Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The type of the match, regular or playoff.
|
||||
/// </summary>
|
||||
public required string MatchType { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Application.DTOs.Match.Response;
|
||||
|
||||
/// <summary>
|
||||
/// A single matchday and its matches, letting the frontend group the fixture by round instead of date.
|
||||
/// </summary>
|
||||
public class RoundMatchesResponse
|
||||
{
|
||||
/// <summary>
|
||||
/// The 1-based round number; null groups matches with no round-robin matchday.
|
||||
/// </summary>
|
||||
public int? Round { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The matches played in this round, in a stable order.
|
||||
/// </summary>
|
||||
public List<DetailedMatchResponse> Matches { get; set; } = [];
|
||||
}
|
||||
Reference in New Issue
Block a user