source: bus-n-go-do-5ta-faza/src/main/java/mk/ukim/finki/busngo/model/entities/Bilet.java

Last change on this file was baf4cc4, checked in by ppaunovski <paunovskipavel@…>, 3 months ago

split group project and individual project into two separate folders

  • Property mode set to 100644
File size: 1015 bytes
Line 
1package mk.ukim.finki.busngo.model.entities;
2
3import jakarta.persistence.*;
4import lombok.Data;
5import mk.ukim.finki.busngo.model.enums.BILET_STATUS;
6import org.hibernate.annotations.Type;
7
8import java.sql.Timestamp;
9import java.util.Collection;
10import java.util.List;
11import java.util.Objects;
12
13@Data
14@Entity
15public class Bilet {
16 @GeneratedValue(strategy = GenerationType.IDENTITY)
17 @Id
18 @Column(name = "b_id")
19 private Long BId;
20
21 @Basic
22 @Column(name = "b_datum_na_kupuvanje")
23 private Timestamp bDatumNaKupuvanje;
24
25 @Basic
26 @Column(name = "b_status", columnDefinition = "string_kratok")
27 @Enumerated(EnumType.STRING)
28 private BILET_STATUS bStatus;
29
30 @ManyToOne
31 @JoinColumn(name = "patnik_k_id", referencedColumnName = "k_id")
32 private Patnik korisnikByPatnikKId;
33
34 @ManyToOne
35 @JoinColumn(name = "tb_id", referencedColumnName = "tb_id")
36 private Tipbilet tipbiletByTbId;
37// @OneToMany(mappedBy = "biletByBId")
38// private List<Vozenje> vozenjesByBId;
39}
Note: See TracBrowser for help on using the repository browser.