• This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

AVForums Moderator Checkpoint System

alexD

Well-known member
This add-on aims to provide you and your moderators an easy way to know if a post has already been reviewed by any of you.

checkpoint07.webp node_permissions.webp moderator.webporder_hook.webp

Features:
Installs with default permissions (set to moderators).
Action log.
Automatically sets to "checked", posts made by staff member (see "Auto check own post" permission).
Per forum permissions.
Active checking.
Change the highlight colors via style properties.
Thread ordering based on the checked post count.

This add-on uses 2 template hooks and requires 8 manual template edits.

(if you are upgrading your add-on you can make the v1.0.0 Αlphα to v1.0.1 template edits).

Note that whenever you upgrade your XenForo, you will need to remake the following template edits, again, until we get more template hooks.

Template name: thread_list_item
1) Find (* may be anything) [updated in v1.0.1]:
Rich (BB code):
<li id="thread-{$thread.thread_id}" class="discussionListItem {$thread.discussion_state} {xen:if {$thread.sticky}, 'sticky'} {xen:if {$thread.isNew}, 'unread'}" data-author="{$thread.username}">
Replace with (* is what to be added):
Rich (BB code):
<li id="thread-{$thread.thread_id}" class="discussionListItem {$thread.discussion_state} {xen:if {$thread.sticky}, 'sticky'} {xen:if {$thread.isNew}, 'unread'} {xen:if {$thread.isChecked}, 'checked'}" data-author="{$thread.username}">
2) Find:
Code:
<xen:require css="discussion_list.css" />
Add, below:
Code:
<xen:require css="AVFCheckpoint_discussion_list.css" />
Hit enter to create a new line, after you paste the previous.

Template name: message
1) Find (should at the 1st line):
Code:
<xen:require css="message.css" />
Add, below:
Code:
<xen:require css="AVFCheckpoint_message.css" />

2) Find (* may be anything) [updated in v1.0.1]:
Rich (BB code):
<li id="{$messageId}" class="message {xen:if $message.isDeleted, 'deleted'} {xen:if '{$message.is_admin} OR {$message.is_moderator}', 'staff'}" data-author="{$message.username}">
Replace with (* is what to be added):
Rich (BB code):
<li id="{$messageId}" class="message {xen:if $message.isDeleted, 'deleted'} {xen:if '{$message.is_admin} OR {$message.is_moderator}', 'staff'} <xen:if is="{$post.checkpoint.checkStatus} == 'checked'">{xen:if $post.checkpoint.justChecked, 'justChecked', 'checked'}</xen:if>" data-author="{$message.username}">
Hit enter to create a new line, after you paste the previous.

Template name: inline_mod_controls_thread
Find:
Code:
        <xen:if is="{$inlineModOptions.unlock}"><option value="unlock">{xen:phrase unlock_threads}</option></xen:if>
Add, below:
Code:
        <xen:if is="{$inlineModOptions.check}"><option value="check">{xen:phrase check_threads}</option></xen:if>
        <xen:if is="{$inlineModOptions.uncheck}"><option value="uncheck">{xen:phrase uncheck_threads}</option></xen:if>

Template name: thread_view
Find:
Code:
                    <xen:if is="{$inlineModOptions.move}"><option value="move">{xen:phrase move_posts}...</option></xen:if>
Add, above:
Code:
                    <xen:if is="{$inlineModOptions.check}"><option value="check">{xen:phrase check_posts}</option></xen:if>
                    <xen:if is="{$inlineModOptions.uncheck}"><option value="uncheck">{xen:phrase uncheck_posts}</option></xen:if>

Template name: post
Find [updated in v1.0.1]:
Code:
                <xen:if is="{$canViewIps} AND {$post.ip_id}"><a href="{xen:link posts/ip, $post}" class="item control ip OverlayTrigger"><span></span>{xen:phrase ip}</a></xen:if>
Add, below:
Code:
                <xen:if is="{$post.checkpoint}">
                    <xen:if is="{$post.checkpoint.checkStatus} == 'checked'"><span class="checked">{xen:phrase last_checked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate" >(<xen:datetime time="$post.checkpoint.last_action_date" />)</span><!-- <span class="unchecked">{xen:phrase uncheck}</span>--></span>
                    <xen:elseif is="{$post.checkpoint.checkStatus} == 'unchecked'" /><span class="unchecked">{xen:phrase last_unchecked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate">(<xen:datetime time="$post.checkpoint.last_action_date" />)</span><!-- <span class="checked">{xen:phrase check}</span>--></span>
                    <xen:else /><span class="notChecked">{xen:phrase not_yet_checked}<!-- — <span class="checked">Check</span>--></span>
                    </xen:if>
                </xen:if>

NEW[1.0.3]
Template name: thread_list_item
Find:
Code:
 <dl class="minor"><dt>{xen:phrase views}:</dt> <dd>{xen:if $thread.isRedirect, '&ndash;', {xen:number $thread.view_count}}</dd></dl>
Add, below:
Code:
 <dl class="minor" style="margin-top:-5px;"><dt>{xen:phrase Unchecked}:</dt> <dd>{xen:if $thread.isRedirect, '&ndash;', {xen:number $thread.uncheckedCount}}</dd></dl>
 

Attachments

I really like this, but would prefer far less template edits.
I think I'll wait for more hooks........?
 
Yesterday one of my moderators was complaining that his moderated thread got re-moderated by some other moderator. There was no intention behind it, I’m sure if there were an option like this add-on provides, that could have been easily avoided. For busy forums this feature is almost vital. Yet, the template modifications have scared me a bit. Maybe when there are more hooks available and no need for manual modification I'll install it. Thanks alexD, I'll keep an eye on this.
 
v1.0.0 Alphα to v1.0.1 Template Edits:

Find:
Code:
<li id="thread-{$thread.thread_id}" class="discussionListItem {$thread.discussion_state} {xen:if {$thread.sticky}, 'sticky'} {xen:if {$thread.isNew}, 'unread'} {xen:if {$thread.isUnchecked}, 'unchecked'}" data-author="{$thread.username}">
Replace with:
Code:
<li id="thread-{$thread.thread_id}" class="discussionListItem {$thread.discussion_state} {xen:if {$thread.sticky}, 'sticky'} {xen:if {$thread.isNew}, 'unread'} {xen:if {$thread.isChecked}, 'checked'}" data-author="{$thread.username}">

Find:
Code:
<li id="{$messageId}" class="message {xen:if $message.isDeleted, 'deleted'} {xen:if '{$message.is_admin} OR {$message.is_moderator}', 'staff'} <xen:if is="{$post.checkpoint.checkStatus} == 'unchecked' OR {$post.highlight}">unchecked</xen:if>" data-author="{$message.username}">
Replace with:
Code:
<li id="{$messageId}" class="message {xen:if $message.isDeleted, 'deleted'} {xen:if '{$message.is_admin} OR {$message.is_moderator}', 'staff'} <xen:if is="{$post.checkpoint.checkStatus} == 'checked'">{xen:if $post.checkpoint.justChecked, 'justChecked', 'checked'}</xen:if>" data-author="{$message.username}">

Find:
Code:
                <xen:if is="{$post.checkpoint}">
                    <xen:if is="{$post.checkpoint.checkStatus} == 'checked'"><span class="checked">{xen:phrase last_checked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate">(<xen:datetime time="$checkpoint.last_action_date" />)</span><!-- <span class="unchecked">{xen:phrase uncheck}</span>--></span>
                    <xen:else /><span class="unchecked">{xen:phrase last_unchecked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate">(<xen:datetime time="$checkpoint.last_action_date" />)</span><!-- <span class="checked">{xen:phrase check}</span>--></span>
                    </xen:if>
                <xen:else /><span class="notChecked">{xen:phrase not_yet_checked}<!-- — <span class="checked">Check</span>--></span>
                </xen:if>
Replace with:
Code:
                <xen:if is="{$post.checkpoint}">
                    <xen:if is="{$post.checkpoint.checkStatus} == 'checked'"><span class="checked">{xen:phrase last_checked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate" >(<xen:datetime time="$post.checkpoint.last_action_date" />)</span><!-- <span class="unchecked">{xen:phrase uncheck}</span>--></span>
                    <xen:elseif is="{$post.checkpoint.checkStatus} == 'unchecked'" /><span class="unchecked">{xen:phrase last_unchecked_by_x, 'username={$post.checkpoint.last_moderator_username}'} <span class="actionDate">(<xen:datetime time="$post.checkpoint.last_action_date" />)</span><!-- <span class="checked">{xen:phrase check}</span>--></span>
                    <xen:else /><span class="notChecked">{xen:phrase not_yet_checked}<!-- — <span class="checked">Check</span>--></span>
                    </xen:if>
                </xen:if>
 
Top Bottom