Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

ApplicantConfiguration.cs 1.3KB

12345678910111213141516171819202122232425
  1. using Microsoft.EntityFrameworkCore.Metadata.Builders;
  2. namespace Diligent.WebAPI.Data.Configurations
  3. {
  4. public class ApplicantConfiguration : IEntityTypeConfiguration<Applicant>
  5. {
  6. public void Configure(EntityTypeBuilder<Applicant> builder)
  7. {
  8. builder.Property(c => c.FirstName).HasMaxLength(128);
  9. builder.Property(c => c.LastName).HasMaxLength(128);
  10. builder.Property(c => c.LastName).HasMaxLength(128);
  11. builder.Property(c => c.Position).HasMaxLength(128);
  12. builder.Property(c => c.ProfessionalQualification).HasMaxLength(128);
  13. builder.Property(c => c.CV).IsRequired(true);
  14. builder.Property(c => c.Email).HasMaxLength(128);
  15. builder.Property(c => c.PhoneNumber).HasMaxLength(30);
  16. builder.Property(c => c.LinkedlnLink).IsRequired(false);
  17. builder.Property(c => c.GithubLink).IsRequired(false);
  18. builder.Property(c => c.BitBucketLink).IsRequired(false);
  19. builder.Property(c => c.ApplicationChannel).IsRequired(false);
  20. builder.Property(c => c.TypeOfEmployment).IsRequired(true).HasConversion<string>();
  21. builder.Property(c => c.Gender).IsRequired(true).HasConversion<string>();
  22. }
  23. }
  24. }