- Timestamp:
- 02/03/23 10:49:45 (17 months ago)
- Branches:
- main
- Children:
- e294983
- Parents:
- 4885da3 (diff), 579bf6d (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Prototype Application/Paw5/src/main/java/finki/paw5/model/Donor.java
r4885da3 r8ae6217 1 1 package finki.paw5.model; 2 2 3 import jakarta.persistence.Column; 4 import jakarta.persistence.Entity; 5 import jakarta.persistence.Id; 6 import jakarta.persistence.Table; 3 import jakarta.persistence.*; 7 4 import lombok.Data; 5 6 import java.time.LocalDate; 8 7 9 8 @Data 10 9 @Entity 11 10 @Table(name = "donor") 12 public class Donor { 13 14 @Id 15 @Column(name = "id_user", nullable = false) 16 private int id; 11 @PrimaryKeyJoinColumn(name = "id_user") 12 public class Donor extends User { 17 13 18 14 @Column(name = "is_from_organisation", nullable = false) … … 22 18 private String organisationName; 23 19 24 public Donor(int id, boolean fromOrganisation, String organisationName) { 25 this.id = id; 20 public Donor(LocalDate dateCreated, String name, String email, String password, String telephone, boolean fromOrganisation, String organisationName) { 21 super(dateCreated, name, email, password, telephone); 22 this.fromOrganisation = fromOrganisation; 23 this.organisationName = organisationName; 24 } 25 26 public Donor(boolean fromOrganisation, String organisationName) { 26 27 this.fromOrganisation = fromOrganisation; 27 28 this.organisationName = organisationName; … … 30 31 public Donor() { 31 32 } 33 32 34 }
Note:
See TracChangeset
for help on using the changeset viewer.