Create User entity

This commit is contained in:
Marcel Schwarz 2020-04-17 18:02:57 +02:00
parent 41338738b0
commit 9ef00cc092

View File

@ -1,4 +1,30 @@
package de.hft.geotime.user;
import lombok.Data;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
@Data
@Entity
public class User {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private long id;
private String username;
private String firstname;
private String lastname;
//TODO: roleid(FK)
//TODO: timetrackaccounts[List]
protected User() {
}
public User(String firstname, String lastname) {
this.firstname = firstname;
this.lastname = lastname;
}
}