package com.magistr.app.model;

import jakarta.persistence.*;

import java.time.LocalDate;

@Entity
@Table(name = "time_slot_date_assignments")
public class TimeSlotDateAssignment {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @Column(name = "assignment_date", nullable = false, unique = true)
    private LocalDate date;

    @ManyToOne(optional = false)
    @JoinColumn(name = "time_slot_scope_id", nullable = false)
    private TimeSlotScope timeSlotScope;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public LocalDate getDate() {
        return date;
    }

    public void setDate(LocalDate date) {
        this.date = date;
    }

    public TimeSlotScope getTimeSlotScope() {
        return timeSlotScope;
    }

    public void setTimeSlotScope(TimeSlotScope timeSlotScope) {
        this.timeSlotScope = timeSlotScope;
    }
}
