Changeset 7f36551 in Git for src/main/java/com/wediscussmovies/project/web/controller/UsersController.java
- Timestamp:
- 02/06/22 22:56:26 (3 years ago)
- Branches:
- main
- Children:
- 3c0f9a9, ad4243e
- Parents:
- 42d565b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/main/java/com/wediscussmovies/project/web/controller/UsersController.java
r42d565b r7f36551 8 8 import com.wediscussmovies.project.service.MovieService; 9 9 import com.wediscussmovies.project.service.UserService; 10 import com.wediscussmovies.project.web.DesignFrontMovies; 10 11 import org.springframework.stereotype.Controller; 11 12 import org.springframework.ui.Model; … … 65 66 List<Movie> movieList = this.movieService.findLikedMoviesByUser(LoggedUser.getLoggedUser()); 66 67 List<List<Movie>> movie_rows = new ArrayList<>(); 67 for(int i=0; i<movieList.size(); i+=4){ 68 int j = i+4; 69 if(j>movieList.size()) 70 j= movieList.size(); 71 movie_rows.add(movieList.subList(i, j)); 72 } 68 DesignFrontMovies.designMovieList(movieList,movie_rows); 73 69 model.addAttribute("movie_rows", movie_rows); 74 70 model.addAttribute("contentTemplate","favoriteList");
Note:
See TracChangeset
for help on using the changeset viewer.