package de.oaa.xxx.games.chastity.keyholder;

import jakarta.persistence.*;
import lombok.Getter;
import lombok.Setter;

import java.time.LocalDateTime;
import java.util.UUID;

@Getter
@Setter
@Entity
@Table(name = "keyholder_offer")
public class KeyholderOfferEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.UUID)
    @Column
    private UUID id;

    @Column(nullable = false)
    private UUID offererId;

    @Column(nullable = false)
    private UUID templateId;

    /** Denormalisiert für schnelle Anzeige */
    @Column(length = 200)
    private String templateName;

    /** "CARDLOCK" oder "TIMELOCK" – denormalisiert */
    @Column(length = 20)
    private String templateType;

    /** Kommagetrennte Geschlechter: z.B. "WEIBLICH,DIVERS" – leer = alle */
    @Column(length = 100)
    private String targetGenders;

    /** true = Lock wird sofort gestartet; false = Keyholder muss erst bestätigen */
    @Column(nullable = false)
    private boolean directStart;

    @Column(nullable = false)
    private int acceptanceCount = 0;

    @Column(nullable = false)
    private LocalDateTime createdAt;
}
