main
Last change
on this file since cadbec3 was ada7108, checked in by Filip Chorbeski <86695898+FilipChorbeski@…>, 20 months ago |
change ids from int to Integer
Co-Authored-By: SazdovaEkaterina <74919977+SazdovaEkaterina@…>
|
-
Property mode
set to
100644
|
File size:
1010 bytes
|
Line | |
---|
1 | package finki.paw5.model.relations;
|
---|
2 |
|
---|
3 | import jakarta.persistence.*;
|
---|
4 | import lombok.Data;
|
---|
5 |
|
---|
6 | import java.time.LocalDate;
|
---|
7 | import java.util.Date;
|
---|
8 |
|
---|
9 | @Data
|
---|
10 | @Entity
|
---|
11 | @Table(name = "pet_needs_intervention_in_vet_clinic")
|
---|
12 | @IdClass(PetNeedsInterventionInVetClinicId.class)
|
---|
13 | public class PetNeedsInterventionInVetClinic {
|
---|
14 |
|
---|
15 | @Id
|
---|
16 | @Column(name = "id_pet", nullable = false)
|
---|
17 | private Integer petId;
|
---|
18 |
|
---|
19 | @Id
|
---|
20 | @Column(name = "id_vet_clinic", nullable = false)
|
---|
21 | private Integer vetClinicId;
|
---|
22 |
|
---|
23 | @Column(name = "date_of_interventing", nullable = false)
|
---|
24 | private LocalDate interventionDate;
|
---|
25 |
|
---|
26 | @Column(name = "description", length = 100)
|
---|
27 | private String description;
|
---|
28 |
|
---|
29 | public PetNeedsInterventionInVetClinic(int petId, int vetClinicId, LocalDate interventionDate, String description) {
|
---|
30 | this.petId = petId;
|
---|
31 | this.vetClinicId = vetClinicId;
|
---|
32 | this.interventionDate = interventionDate;
|
---|
33 | this.description = description;
|
---|
34 | }
|
---|
35 |
|
---|
36 | public PetNeedsInterventionInVetClinic() {
|
---|
37 |
|
---|
38 | }
|
---|
39 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.