package ru.kayashov.bar.model.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import lombok.Getter;
import lombok.Setter;

import java.util.List;

@Getter
@Setter
@Entity
@Table(name = "category")
public class CategoryEntity {
    @Id
    private Integer id;
    @Column(name = "en_name")
    private String enName;
    private String name;

    @OneToMany(mappedBy = "categoryEntity")
    private List<CocktailEntity> cocktails;
}