16160f6424
Initial version of the data model Includes EF initialization and migrations EF migrations are applied on application start
27 lines
737 B
C#
27 lines
737 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace TournamentOrganizer.Models;
|
|
|
|
public class Tournament
|
|
{
|
|
[Key]
|
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
|
public int Id { get; set; }
|
|
public int GameId { get; set; }
|
|
public int EventId { get; set; }
|
|
public DateTime Start { get; set; }
|
|
public DateTime End { get; set; }
|
|
|
|
public RuleSet S1RuleSet { get; set; }
|
|
public int S1Groups;
|
|
public int S1GroupAdvances;
|
|
public RuleSet? S2RuleSet { get; set; }
|
|
|
|
public required Game Game { get; set; }
|
|
public required Event Event { get; set; }
|
|
|
|
} |