Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted August 15, 20177 yr Hello, Your comment controls menu currently has the following check: {{if $comment->canEdit() || $comment->canSplit() || $comment->canHide()}} If we want to add something to this menu it means we have to overload one of these methods or rely on one of them to be true, which is not ideal. Could you add a more generic function for checking whether a comment should have this control menu appear? I also want the control menu to be possible to have on the first post in a topic, so if you could make that a possibillity as well I would appreciate it.
August 15, 20177 yr I've pushed the already existing request in our internally engineering changes tracker.
August 15, 20177 yr Author Thanks, @Daniel F. But this area seems a bit confusing to me when I look closer into it. Those options also includes "Recommend" when I look at my install, so I guess it's really this check that it does? {{if $comment->canPromoteToSocialMedia() || $comment->canDelete() || $comment->canSplit() || ( $comment instanceof \IPS\Content\Hideable AND ( ( !$comment->hidden() and $comment->canHide() ) || ( $comment->hidden() and $comment->canUnhide() ) ) ) || ( $comment->hidden() == -2 AND \IPS\Member::loggedIn()->modPermission('can_manage_deleted_content') )}} But I'm pretty sure I chose the selector inside the if-check I presented above, so not sure what I'm missing here.
Archived
This topic is now archived and is closed to further replies.