source: src/main/java/com/example/medweb/model/Transakcija.java@ 7eed782

Last change on this file since 7eed782 was e5fefbd, checked in by Anita Terziska <63020646+Nit4e@…>, 2 years ago

initial commit

  • Property mode set to 100644
File size: 677 bytes
Line 
1package com.example.medweb.model;
2
3
4import lombok.Data;
5
6import javax.persistence.*;
7
8
9@Data
10@Entity
11public class Transakcija {
12
13 @Id
14 @GeneratedValue(strategy = GenerationType.IDENTITY)
15 private Integer tran_id;
16 private Integer suma;
17 private String smetka_bolnica;
18
19 @OneToOne
20 @JoinColumn(name = "rezervacija_id", referencedColumnName = "rezervacija_id", nullable = true)
21 private Rezervacija rezervacija;
22
23
24 public Transakcija() {
25 }
26
27 public Transakcija(Integer suma, String smetka_bolnica, Rezervacija rezervacija) {
28 this.suma = suma;
29 this.smetka_bolnica = smetka_bolnica;
30 this.rezervacija = rezervacija;
31 }
32}
Note: See TracBrowser for help on using the repository browser.