Ignore:
Timestamp:
02/08/22 20:13:23 (3 years ago)
Author:
Petar Partaloski <ppartaloski@…>
Branches:
main
Children:
0226942, 3fe36de
Parents:
3c0f9a9
Message:

Added new core functionalities, fixed bugs and improved visual clarity

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/com/wediscussmovies/project/service/impl/MovieServiceImpl.java

    r3c0f9a9 rc02189f  
    1313import com.wediscussmovies.project.model.relation.MovieLikes;
    1414import com.wediscussmovies.project.model.relation.MovieRates;
     15import com.wediscussmovies.project.querymodels.MovieLikesQM;
    1516import com.wediscussmovies.project.repository.*;
    1617import com.wediscussmovies.project.model.exception.MovieIdNotFoundException;
     
    7374    public Movie findById(Integer id) {
    7475        return this.movieRepository.findById(id).orElseThrow(() -> new MovieIdNotFoundException(id));
     76    }
     77
     78    @Override
     79    public Movie findBasicById(Integer id) {
     80        return this.movieRepository.findBasicById(id).orElseThrow(() -> new MovieIdNotFoundException(id));
     81    }
     82
     83    @Override
     84    public MovieLikesQM findLikesForMovieById(int movieId) {
     85        return this.movieRepository.findLikesForMovie(movieId).get(0);
    7586    }
    7687
Note: See TracChangeset for help on using the changeset viewer.