mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-15 12:15:50 +00:00
Fix date formatting
This commit is contained in:
parent
5b0f037d06
commit
45da5a4d3b
2 changed files with 2 additions and 2 deletions
2
src/main/java/org/springframework/samples/petclinic/owner/Pet.java
Normal file → Executable file
2
src/main/java/org/springframework/samples/petclinic/owner/Pet.java
Normal file → Executable file
|
@ -53,7 +53,7 @@ public class Pet extends NamedEntity {
|
|||
|
||||
@Column(name = "birth_date")
|
||||
@Temporal(TemporalType.DATE)
|
||||
@DateTimeFormat(pattern = "yyyy/MM/dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private Date birthDate;
|
||||
|
||||
@ManyToOne
|
||||
|
|
|
@ -39,7 +39,7 @@ public class Visit extends BaseEntity {
|
|||
|
||||
@Column(name = "visit_date")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@DateTimeFormat(pattern = "yyyy/MM/dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private Date date;
|
||||
|
||||
@NotEmpty
|
||||
|
|
Loading…
Reference in a new issue