title: How to get All the elements of the entity in spring-boot ?
body: <p>I'm sending a GET request from angular5 to spring-boot to get all the elements of the entity Contrat below  .</p>
  
  <p>This is the entity : </p>
  
  <pre><code>@Entity
  @Data
  @AllArgsConstructor
  @NoArgsConstructor
  public class Contrat implements Serializable{
  
          @Id @GeneratedValue
          private Long id;
          private Date dateDebut ;
          private Date dateFin ;
          @ManyToOne
          @JoinColumn(name = "Id_Project")
          @JsonBackReference(value="projet-contrat")
          private Project project;
  
          @ManyToOne
          @JoinColumn(name = "Id_AppUser")
          @JsonBackReference(value="appuser-contrat")
          private AppUser appUser;
  }
  </code></pre>
  
  <p>This is the repository : </p>
  
  <pre><code>  public interface ContratRepo extends JpaRepository&lt;Contrat,Long&gt; {
  
      @Query("select from Contrat c where c.appUser = :userApp")
      public Page&lt;Contrat&gt; chercherContrat(@Param("userApp") AppUser userApp  
     , Pageable pageable);
  
     }
  </code></pre>
  
  <p>In Angular5 the console.log(data) returns this result for exemple: </p>
  
  <pre><code> {id: 1, dateDebut: 1526083200000, dateFin: 1526083200000} 
  </code></pre>
  
  <p>So as you can see there is not the project element (that i need in front-end) .</p>
  
  <p>I want to show in angular the contrat elements plus some information of the project related to .</p>
  
  <p>Any idea ? </p>