20 lines
558 B
C#
20 lines
558 B
C#
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Metadata.Builders;
|
|
using RecNet.Domain.GameVersions;
|
|
|
|
namespace RecNet.Infrastructure.Persistence.Configurations;
|
|
|
|
public class GameVersionConfiguration : IEntityTypeConfiguration<GameVersion>
|
|
{
|
|
public void Configure(EntityTypeBuilder<GameVersion> builder)
|
|
{
|
|
builder.HasKey(x => x.Version);
|
|
|
|
builder.Property(x => x.Version)
|
|
.HasMaxLength(32)
|
|
.IsRequired();
|
|
|
|
builder.Property(x => x.IsValid)
|
|
.IsRequired();
|
|
}
|
|
} |