Hey there,

When you have the sort order of Heartbeat Comment Settings set to 'Oldest comments on top' it does indeed work great on default display, however if you are using the 'Load with AJAX' more button, the comments expand when clicked but are in the reversed order of 'Most recent comments on top'. Its possible its not checking the sort order when it returns the more list, but just a heads up. If I find and fix the issue I'll definitely post a patch.

Thanks for the hard work on this module, its rather awesome.

CommentFileSizeAuthor
#9 heartbeat_comments-sorting-1062116.patch2.69 KBvishun
#7 oldestcommentsontopmoreclick-1062116-4316626.patch3.12 KBAnonymous (not verified)
#2 heartbeat_6411_01.patch1.32 KBAnonymous (not verified)
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Anonymous’s picture

+1

Anonymous’s picture

Assigned: Unassigned »
Status: Active » Patch (to be ported)
FileSize
1.32 KB

Here is the patch I made.
Now the "more link" respects the original order and it is at the top of the list.

vishun’s picture

Hey, awesome patch, thank you very much for contributing it. Worked great.

My personal preference for "oldest on top" was having the more button on the bottom so I did a little switcheroo on that aspect. Almost seems like maybe the more button should have its own setting on whether to appear at the top or bottom, that way you could mix and match as desired. I'll join the fun and try provide a patch for that in the next couple days. Also, I just split the 'add heartbeat comment' permission into having a 'view heartbeat comments' permission so anonymous can see comments but not place comments. Previously the two concepts were tied solely to the 'add heartbeat comment' permission.

It's pretty unrelated to this issue and patch, but its quite useful and relatively related in that its heartbeat comments. Should we just combine the added permissions (and also possibly the added setting for more button on top or bottom) into a mega patch?

Stalski’s picture

Cool :)
Is there any reason why I can apply this patch?

Anonymous’s picture

With the patch, the "more" button works also with the "Oldest comments on top" option.
Is it a sufficient reason?

Stalski’s picture

I meant, why I CAN't apply the patch :)
It's invalid

Anonymous’s picture

Sorry, misunderstanding.
My previous patch is an SVN patch.
Here is the right one.

Stalski’s picture

Status: Patch (to be ported) » Closed (fixed)

Sorry to see this just now. It seems that this was pushed to git long time ago. Sorry for that.

vishun’s picture

Status: Closed (fixed) » Needs review
FileSize
2.69 KB

The present implementation does not appear to work properly in all instances and I have made some adjustments that seems to make things solid. The proposed changes moves closer to the source, the database query, instead of further down the line in heartbeat_comments_widget().