95 lines
2.2 KiB
Java
95 lines
2.2 KiB
Java
package gr.cite.annotation.data;
|
|
|
|
import gr.cite.annotation.common.enums.IsActive;
|
|
import gr.cite.annotation.data.conventers.IsActiveConverter;
|
|
import gr.cite.annotation.data.tenant.TenantScopedBaseEntity;
|
|
import jakarta.persistence.*;
|
|
|
|
import java.time.Instant;
|
|
import java.util.UUID;
|
|
|
|
@Entity
|
|
@Table(name = "\"EntityUser\"")
|
|
public class EntityUserEntity extends TenantScopedBaseEntity {
|
|
|
|
@Id
|
|
@Column(name = "\"id\"", columnDefinition = "uuid", updatable = false, nullable = false)
|
|
private UUID id;
|
|
|
|
public static final String _id = "id";
|
|
|
|
@Column(name = "\"entity_id\"", columnDefinition = "uuid", nullable = false)
|
|
private UUID entityId;
|
|
|
|
public static final String _entityId = "entityId";
|
|
|
|
@Column(name = "\"user_id\"", columnDefinition = "uuid", nullable = false)
|
|
private UUID userId;
|
|
|
|
public static final String _userId = "userId";
|
|
|
|
@Column(name = "\"created_at\"", nullable = false)
|
|
private Instant createdAt;
|
|
|
|
public static final String _createdAt = "createdAt";
|
|
|
|
@Column(name = "\"updated_at\"", nullable = false)
|
|
private Instant updatedAt;
|
|
|
|
public static final String _updatedAt = "updatedAt";
|
|
|
|
@Column(name = "is_active", nullable = false)
|
|
@Convert(converter = IsActiveConverter.class)
|
|
private IsActive isActive;
|
|
|
|
public static final String _isActive = "isActive";
|
|
|
|
public UUID getId() {
|
|
return id;
|
|
}
|
|
|
|
public void setId(UUID id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public UUID getEntityId() {
|
|
return entityId;
|
|
}
|
|
|
|
public void setEntityId(UUID entityId) {
|
|
this.entityId = entityId;
|
|
}
|
|
|
|
public UUID getUserId() {
|
|
return userId;
|
|
}
|
|
|
|
public void setUserId(UUID userId) {
|
|
this.userId = userId;
|
|
}
|
|
|
|
public Instant getCreatedAt() {
|
|
return createdAt;
|
|
}
|
|
|
|
public void setCreatedAt(Instant createdAt) {
|
|
this.createdAt = createdAt;
|
|
}
|
|
|
|
public Instant getUpdatedAt() {
|
|
return updatedAt;
|
|
}
|
|
|
|
public void setUpdatedAt(Instant updatedAt) {
|
|
this.updatedAt = updatedAt;
|
|
}
|
|
|
|
public IsActive getIsActive() {
|
|
return isActive;
|
|
}
|
|
|
|
public void setIsActive(IsActive isActive) {
|
|
this.isActive = isActive;
|
|
}
|
|
}
|