Update SurveyLib and add support for multiple answer questions

This commit is contained in:
Вячеслав 2025-06-08 14:59:41 +05:00
parent 00b422b8f3
commit 690eaaa32f
4 changed files with 401 additions and 6 deletions

View file

@ -76,20 +76,27 @@ namespace SurveyBackend.Infrastructure.Data.Migrations
modelBuilder.Entity("SurveyLib.Core.Models.Answer", b =>
{
b.Property<int>("CompletionId")
.HasColumnType("INTEGER");
b.Property<int>("QuestionId")
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("AnswerText")
.IsRequired()
.HasColumnType("TEXT");
b.HasKey("CompletionId", "QuestionId");
b.Property<int>("CompletionId")
.HasColumnType("INTEGER");
b.Property<int>("QuestionId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("QuestionId");
b.HasIndex("CompletionId", "QuestionId", "AnswerText")
.IsUnique();
b.ToTable("Answers");
});