using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Metadata.Builders; using CellularManagement.Domain.Entities; namespace CellularManagement.Infrastructure.Configurations.Permission; public class PermissionConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { builder.ToTable("tb_permissions"); builder.HasKey(p => p.Id); builder.Property(p => p.Name).IsRequired().HasMaxLength(50); builder.Property(p => p.Description).HasMaxLength(200); builder.Property(p => p.Code).IsRequired().HasMaxLength(50); builder.Property(p => p.Type).IsRequired().HasMaxLength(50); builder.Property(p => p.CreatedAt).IsRequired().HasColumnType("timestamp with time zone"); } }