2024-04-29 15:46:06 +04:00
|
|
|
|
// <auto-generated />
|
|
|
|
|
using System;
|
|
|
|
|
using HotelDataBaseImplement;
|
|
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
2024-05-29 12:33:22 +04:00
|
|
|
|
using Microsoft.EntityFrameworkCore.Metadata;
|
2024-04-29 15:46:06 +04:00
|
|
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
|
|
|
|
|
|
|
|
#nullable disable
|
|
|
|
|
|
|
|
|
|
namespace HotelDataBaseImplement.Migrations
|
|
|
|
|
{
|
|
|
|
|
[DbContext(typeof(HotelDataBase))]
|
2024-05-29 12:33:22 +04:00
|
|
|
|
[Migration("20240528212239_Init")]
|
|
|
|
|
partial class Init
|
2024-04-29 15:46:06 +04:00
|
|
|
|
{
|
|
|
|
|
/// <inheritdoc />
|
|
|
|
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
|
|
|
{
|
|
|
|
|
#pragma warning disable 612, 618
|
|
|
|
|
modelBuilder
|
|
|
|
|
.HasAnnotation("ProductVersion", "7.0.11")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasAnnotation("Relational:MaxIdentifierLength", 128);
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Administrator", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("AdministratorEmail")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("AdministratorFIO")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("AdministratorLogin")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("AdministratorPassword")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("AdministratorPhone")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Administrators");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Conference", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("ConferenceName")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("OrganiserId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-01 19:51:05 +04:00
|
|
|
|
b.Property<DateTime>("StartDate")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("datetime2");
|
2024-05-01 19:51:05 +04:00
|
|
|
|
|
2024-04-29 15:46:06 +04:00
|
|
|
|
b.Property<string>("Subject")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganiserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Conferences");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceBooking", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("AdministratorId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int?>("ConferenceId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<DateTime?>("DateСonference")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("datetime2");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("PlaceСonference")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("AdministratorId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ConferenceId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ConferenceBookings");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceBookingDinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("ConferenceBookingId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("DinnerId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ConferenceBookingId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("DinnerId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ConferenceBookingDinners");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceParticipant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("ConferenceId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("ParticipantId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ConferenceId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ParticipantId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("ConferenceParticipants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Dinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("AdministratorId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("DinnerName")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<double>("DinnerPrice")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("float");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("DinnerСalorieСontent")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("AdministratorId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Dinners");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.MealPlan", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("MealPlanName")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<double>("MealPlanPrice")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("float");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("OrganiserId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganiserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("MealPlans");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.MealPlanParticipant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("MealPlanId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("ParticipantId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("MealPlanId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("ParticipantId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("MealPlanParticipants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Organiser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("OrganiserEmail")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("OrganiserFIO")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("OrganiserLogin")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("OrganiserNumber")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("OrganiserPassword")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Organisers");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Participant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("Number")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("OrganiserId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<string>("ParticipantFIO")
|
|
|
|
|
.IsRequired()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("nvarchar(max)");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("OrganiserId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Participants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Room", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("AdministratorId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-01 19:51:05 +04:00
|
|
|
|
b.Property<DateTime>("DateCreate")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("datetime2");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int?>("MealPlanId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("RoomNumber")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<double>("RoomPrice")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("float");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("AdministratorId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("MealPlanId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("Rooms");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.RoomDinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Property<int>("Id")
|
|
|
|
|
.ValueGeneratedOnAdd()
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
2024-05-29 12:33:22 +04:00
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("DinnerId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.Property<int>("RoomId")
|
2024-05-29 12:33:22 +04:00
|
|
|
|
.HasColumnType("int");
|
2024-04-29 15:46:06 +04:00
|
|
|
|
|
|
|
|
|
b.HasKey("Id");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("DinnerId");
|
|
|
|
|
|
|
|
|
|
b.HasIndex("RoomId");
|
|
|
|
|
|
|
|
|
|
b.ToTable("RoomDinners");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Conference", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Organiser", "Organiser")
|
|
|
|
|
.WithMany("Conferences")
|
|
|
|
|
.HasForeignKey("OrganiserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organiser");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceBooking", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Administrator", "Administrator")
|
|
|
|
|
.WithMany("ConferenceBookings")
|
|
|
|
|
.HasForeignKey("AdministratorId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Conference", "Conference")
|
|
|
|
|
.WithMany("Bookings")
|
|
|
|
|
.HasForeignKey("ConferenceId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Administrator");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Conference");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceBookingDinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.ConferenceBooking", "ConferenceBooking")
|
|
|
|
|
.WithMany("Dinners")
|
|
|
|
|
.HasForeignKey("ConferenceBookingId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Dinner", "Dinner")
|
|
|
|
|
.WithMany("ConferenceBookingDinner")
|
|
|
|
|
.HasForeignKey("DinnerId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("ConferenceBooking");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Dinner");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceParticipant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Conference", "Conference")
|
|
|
|
|
.WithMany("Participants")
|
|
|
|
|
.HasForeignKey("ConferenceId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Participant", "Participant")
|
|
|
|
|
.WithMany("ConferenceParticipants")
|
|
|
|
|
.HasForeignKey("ParticipantId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Conference");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Participant");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Dinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Administrator", "Administrator")
|
|
|
|
|
.WithMany("Dinners")
|
|
|
|
|
.HasForeignKey("AdministratorId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Administrator");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.MealPlan", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Organiser", "Organiser")
|
|
|
|
|
.WithMany("MealPlans")
|
|
|
|
|
.HasForeignKey("OrganiserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organiser");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.MealPlanParticipant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.MealPlan", "MealPlan")
|
|
|
|
|
.WithMany("Participants")
|
|
|
|
|
.HasForeignKey("MealPlanId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Participant", "Participant")
|
|
|
|
|
.WithMany("MealPlanParticipants")
|
|
|
|
|
.HasForeignKey("ParticipantId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("MealPlan");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Participant");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Participant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Organiser", "Organiser")
|
|
|
|
|
.WithMany("Participants")
|
|
|
|
|
.HasForeignKey("OrganiserId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Organiser");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Room", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Administrator", "Administrator")
|
|
|
|
|
.WithMany("Rooms")
|
|
|
|
|
.HasForeignKey("AdministratorId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.MealPlan", "MealPlan")
|
2024-05-01 21:18:31 +04:00
|
|
|
|
.WithMany("Rooms")
|
2024-04-29 15:46:06 +04:00
|
|
|
|
.HasForeignKey("MealPlanId");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Administrator");
|
|
|
|
|
|
|
|
|
|
b.Navigation("MealPlan");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.RoomDinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Dinner", "Dinner")
|
|
|
|
|
.WithMany("RoomDinners")
|
|
|
|
|
.HasForeignKey("DinnerId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.HasOne("HotelDataBaseImplement.Models.Room", "Room")
|
|
|
|
|
.WithMany("Dinners")
|
|
|
|
|
.HasForeignKey("RoomId")
|
|
|
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
|
|
|
.IsRequired();
|
|
|
|
|
|
|
|
|
|
b.Navigation("Dinner");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Room");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Administrator", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("ConferenceBookings");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Dinners");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Rooms");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Conference", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Bookings");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Participants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.ConferenceBooking", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Dinners");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Dinner", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("ConferenceBookingDinner");
|
|
|
|
|
|
|
|
|
|
b.Navigation("RoomDinners");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.MealPlan", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Participants");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Rooms");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Organiser", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Conferences");
|
|
|
|
|
|
|
|
|
|
b.Navigation("MealPlans");
|
|
|
|
|
|
|
|
|
|
b.Navigation("Participants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Participant", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("ConferenceParticipants");
|
|
|
|
|
|
|
|
|
|
b.Navigation("MealPlanParticipants");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
modelBuilder.Entity("HotelDataBaseImplement.Models.Room", b =>
|
|
|
|
|
{
|
|
|
|
|
b.Navigation("Dinners");
|
|
|
|
|
});
|
|
|
|
|
#pragma warning restore 612, 618
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|