api/customer
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
package com.aitrainer.api.model
|
||||
|
||||
import com.aitrainer.api.enums.SexEnum
|
||||
|
||||
import javax.persistence.Entity
|
||||
import javax.persistence.GeneratedValue
|
||||
import javax.persistence.GenerationType
|
||||
import javax.persistence.Id
|
||||
import javax.validation.constraints.NotBlank
|
||||
|
||||
@Entity
|
||||
data class Customer (
|
||||
@get: NotBlank
|
||||
val name: String = "",
|
||||
|
||||
val firstname: String,
|
||||
val email: String,
|
||||
val age: Int,
|
||||
val sex: String,
|
||||
|
||||
@Id @GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
val customer_id: Long? = null
|
||||
)
|
||||
Reference in New Issue
Block a user