Commit 6481950a by Oscar Gonzalez

se agrega campos de formateo al modelo fecha de Birthdayˆ

parent fcad016f
package com.roshka.modelo;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import javax.persistence.*;
import javax.validation.constraints.NotBlank;
......@@ -18,6 +19,7 @@ public class Birthday {
@NotBlank(message = "Este campo no puede estar vacio")
private String nombreCompleto;
@Column(name="fecha")
@NotBlank(message = "Este campo no puede estar vacio")
@Temporal(TemporalType.DATE)
@DateTimeFormat(pattern = "yyyy-MM-dd")
private Date fecha;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment