Test project pagination in foscommentsbundle
-
Integrate FosCommentBundle with Page Entity
-
Output comments on page
-
Override service FOS\CommentBundle\Entity\CommentManager.php (method findCommentsByThread) to pagination by root comments (with depth = 0) For test purpose you can use $_GET parameter in your service
-
Override part of fos comments.js (part of used code for example) in your custom js file
FOS_COMMENT.thread_container.on('click',
'.fos_comment_comment_reply_show_form',
function(e) {
...
var container_in = parent.find('> .fos_comment_comment_reply');
...
FOS_COMMENT.get(
form_data.url,
{parentId: form_data.parentId},
function(data) {
...
container_in.addClass('fos_comment_replying');
container_in.html(data);
...
}
);
}
);
- In the output make patch