Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
* initial commit

* Closes #2: Create aggregation for User profile.
  • Loading branch information
aprajshekhar authored Sep 15, 2023
1 parent 97aaa40 commit 0f11234
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/com/gamedoora/model/dao/Skills.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ public class Skills extends Audit implements Serializable {
@JoinTable(name = "skills_sources", joinColumns = @JoinColumn(name = "skill_id"), inverseJoinColumns = @JoinColumn(name = "source_id"))
Set<Sources> sources;

@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER)
@JoinTable(name = "roles_skills", joinColumns = @JoinColumn(name = "role_id"), inverseJoinColumns = @JoinColumn(name = "skill_id"))
@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER, mappedBy = "skills")
//@JoinTable(name = "roles_skills", joinColumns = @JoinColumn(name = "role_id"), inverseJoinColumns = @JoinColumn(name = "skill_id"))
Set<Roles> roles;

public long getId() {
Expand Down
14 changes: 14 additions & 0 deletions src/main/java/com/gamedoora/model/dto/GdUser.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package com.gamedoora.model.dto;

import lombok.*;

import java.util.List;


@EqualsAndHashCode(callSuper = false)
@Builder
public class GdUser {
private List<RoleDTO> roles;
private List<SkillsDTO> skills;
private UserDTO user;
}

0 comments on commit 0f11234

Please sign in to comment.