// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using timetracker.Data;

#nullable disable

namespace timetracker.Data.Migrations
{
    [DbContext(typeof(TimetrackerDbContext))]
    [Migration("20260607213215_AddFlexTimeAndHolidayState")]
    partial class AddFlexTimeAndHolidayState
    {
        /// <inheritdoc />
        protected override void BuildTargetModel(ModelBuilder modelBuilder)
        {
#pragma warning disable 612, 618
            modelBuilder.HasAnnotation("ProductVersion", "10.0.8");

            modelBuilder.Entity("timetracker.Data.AppSettings", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<double>("DailyTargetHours")
                        .HasColumnType("REAL");

                    b.Property<DateOnly?>("FlexTimeStartDate")
                        .HasColumnType("TEXT");

                    b.Property<double>("FlexTimeStartingBalanceHours")
                        .HasColumnType("REAL");

                    b.Property<string>("GermanState")
                        .HasColumnType("TEXT");

                    b.Property<int>("MinimumBreakMinutes")
                        .HasColumnType("INTEGER");

                    b.Property<int>("UserId")
                        .HasColumnType("INTEGER");

                    b.Property<int>("VacationDaysPerYear")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkFriday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkMonday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkSaturday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkSunday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkThursday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkTuesday")
                        .HasColumnType("INTEGER");

                    b.Property<bool>("WorkWednesday")
                        .HasColumnType("INTEGER");

                    b.HasKey("Id");

                    b.ToTable("AppSettings");
                });

            modelBuilder.Entity("timetracker.Data.BreakEntry", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<TimeOnly?>("EndTime")
                        .HasColumnType("TEXT");

                    b.Property<TimeOnly?>("StartTime")
                        .HasColumnType("TEXT");

                    b.Property<int>("WorkDayId")
                        .HasColumnType("INTEGER");

                    b.HasKey("Id");

                    b.HasIndex("WorkDayId");

                    b.ToTable("BreakEntries");
                });

            modelBuilder.Entity("timetracker.Data.PublicHoliday", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("Counties")
                        .HasColumnType("TEXT");

                    b.Property<DateOnly>("Date")
                        .HasColumnType("TEXT");

                    b.Property<string>("Name")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.ToTable("PublicHolidays");
                });

            modelBuilder.Entity("timetracker.Data.User", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<string>("PasswordHash")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("PasswordSalt")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.Property<string>("Username")
                        .IsRequired()
                        .HasColumnType("TEXT");

                    b.HasKey("Id");

                    b.ToTable("Users");
                });

            modelBuilder.Entity("timetracker.Data.VacationDay", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<DateOnly>("Date")
                        .HasColumnType("TEXT");

                    b.Property<string>("Note")
                        .HasColumnType("TEXT");

                    b.Property<int>("UserId")
                        .HasColumnType("INTEGER");

                    b.HasKey("Id");

                    b.ToTable("VacationDays");
                });

            modelBuilder.Entity("timetracker.Data.WorkDay", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd()
                        .HasColumnType("INTEGER");

                    b.Property<DateOnly>("Date")
                        .HasColumnType("TEXT");

                    b.Property<TimeOnly?>("EndTime")
                        .HasColumnType("TEXT");

                    b.Property<TimeOnly?>("StartTime")
                        .HasColumnType("TEXT");

                    b.Property<int>("UserId")
                        .HasColumnType("INTEGER");

                    b.HasKey("Id");

                    b.ToTable("WorkDays");
                });

            modelBuilder.Entity("timetracker.Data.BreakEntry", b =>
                {
                    b.HasOne("timetracker.Data.WorkDay", "WorkDay")
                        .WithMany("Breaks")
                        .HasForeignKey("WorkDayId")
                        .OnDelete(DeleteBehavior.Cascade)
                        .IsRequired();

                    b.Navigation("WorkDay");
                });

            modelBuilder.Entity("timetracker.Data.WorkDay", b =>
                {
                    b.Navigation("Breaks");
                });
#pragma warning restore 612, 618
        }
    }
}
