Ignore:
Timestamp:
02/10/22 13:28:00 (3 years ago)
Author:
Test <matonikolov77@…>
Branches:
main
Children:
980eeda
Parents:
6f91f99
Message:

Changed DiscussionRepository and DiscussionServiceImpl for fetching likes

Location:
src/main/java/com/wediscussmovies/project/model
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/com/wediscussmovies/project/model/Discussion.java

    r6f91f99 r8f1b7e9  
    11package com.wediscussmovies.project.model;
    22
    3 import com.wediscussmovies.project.model.relation.DiscussionLikes;
     3import lombok.AllArgsConstructor;
    44import lombok.Data;
     5import org.springframework.beans.factory.annotation.Value;
    56
    67import javax.persistence.*;
    7 import java.sql.Date;
    8 import java.util.List;
     8import java.time.LocalDate;
    99import java.util.Objects;
    1010
     
    2828    @Basic
    2929    @Column(name = "date")
    30     private Date date;
     30    private LocalDate date;
    3131
    3232
     
    4747
    4848    @Transient
    49     private Long likes;
     49    private long likes;
    5050
    51     public Discussion(Character type, String text, String title, Date date, User user) {
     51    public Discussion(Character type, String text, String title, LocalDate date, User user) {
    5252        this.type = type;
    5353        this.text = text;
     
    5656        this.user = user;
    5757    }
     58
     59
    5860
    5961    public Discussion() {
  • src/main/java/com/wediscussmovies/project/model/Movie.java

    r6f91f99 r8f1b7e9  
    99
    1010import javax.persistence.*;
     11import java.io.Serializable;
    1112import java.sql.Date;
    1213import java.util.Collection;
  • src/main/java/com/wediscussmovies/project/model/Person.java

    r6f91f99 r8f1b7e9  
    77import javax.persistence.*;
    88import javax.swing.text.DateFormatter;
     9import java.io.Serializable;
    910import java.sql.Date;
    1011import java.time.LocalDate;
  • src/main/java/com/wediscussmovies/project/model/User.java

    r6f91f99 r8f1b7e9  
    1010
    1111import javax.persistence.*;
     12import java.io.Serializable;
    1213import java.util.ArrayList;
    1314import java.util.Collection;
Note: See TracChangeset for help on using the changeset viewer.