deviant
09/18/2019, 6:42 AMmiddleName
should be nullable typethanksforallthefish
09/18/2019, 6:49 AMdeviant
09/18/2019, 9:02 AMkqr
09/18/2019, 10:19 AMJason Feng
09/18/2019, 11:04 AMHere we don’t use data classes with val properties because JPA is not designed to work with immutable classes or the methods generated automatically by data classes. If you are using other Spring Data flavor, most of them are designed to support such constructs so you should use classes like data class User(val login: String, …) when using Spring Data MongoDB, Spring Data JDBC, etc.
deviant
09/18/2019, 2:30 PMdata class Funnel(
@ManyToOne
@JoinColumn
@JsonIgnore
val product: CompanyProduct,
var name: String,
@Enumerated(EnumType.STRING)
var state: State = State.ACTIVE,
val createdAt: Instant = Instant.now(),
var updatedAt: Instant = Instant.now(),
var archivedAt: Instant? = null,
@Id @GeneratedValue
val id: Long = 0
)
have no any problems so farLuis Munoz
09/19/2019, 3:41 PM