From 6148ddd9671ccab86a3f0ae2dfa77d833b713ee8 Mon Sep 17 00:00:00 2001 From: Antoine Rey Date: Sun, 15 Dec 2024 18:36:30 +0100 Subject: [PATCH] Uses the date property of the Visit entity --- .../java/org/springframework/samples/petclinic/owner/Pet.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/springframework/samples/petclinic/owner/Pet.java b/src/main/java/org/springframework/samples/petclinic/owner/Pet.java index 03fd26c9375..1fdc77cec2d 100644 --- a/src/main/java/org/springframework/samples/petclinic/owner/Pet.java +++ b/src/main/java/org/springframework/samples/petclinic/owner/Pet.java @@ -55,7 +55,7 @@ public class Pet extends NamedEntity { @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER) @JoinColumn(name = "pet_id") - @OrderBy("visit_date ASC") + @OrderBy("date ASC") private final Set visits = new LinkedHashSet<>(); public void setBirthDate(LocalDate birthDate) {