Some access controls implemented... we'll see how well this works
--- a/decir/viewforum.php Wed Oct 17 23:17:09 2007 -0400
+++ b/decir/viewforum.php Wed Oct 17 23:44:22 2007 -0400
@@ -79,9 +79,8 @@
$num_replies = 0;
if ( $last_row['topic_deleted'] == 1 )
{
- $thread_link = '';
- // FIXME: This will be controlled by an ACL rule
- if ( $session->user_level >= USER_LEVEL_MOD )
+ $thread_link = '<Deleted>';
+ if ( $session->get_permissions('decir_see_deleted_topic_full') )
{
$thread_link = '<b><a class="wikilink-nonexistent" href="' . makeUrlNS('DecirTopic', $last_row['topic_id']) . '">' . $last_row['topic_title'] . '</a></b>';
}
--- a/decir/viewtopic.php Wed Oct 17 23:17:09 2007 -0400
+++ b/decir/viewtopic.php Wed Oct 17 23:44:22 2007 -0400
@@ -72,7 +72,7 @@
$topic_id = $row['topic_id'];
$topic_exists = true;
// FIXME: This will be controlled by an ACL rule
- if ( $row['topic_deleted'] == 1 && $session->user_level < USER_LEVEL_MOD )
+ if ( $row['topic_deleted'] == 1 && !$session->get_permissions('decir_see_deleted_topic_full') )
{
$topic_exists = false;
}
--- a/plugins/Decir.php Wed Oct 17 23:17:09 2007 -0400
+++ b/plugins/Decir.php Wed Oct 17 23:44:22 2007 -0400
@@ -59,7 +59,7 @@
$session->register_acl_type('decir_see_deleted_post', AUTH_ALLOW, 'See placeholders for deleted posts', Array('read'), 'Special|DecirPost|DecirTopic|DecirForum');
$session->register_acl_type('decir_see_deleted_post_full', AUTH_DISALLOW, 'Read the full contents of deleted posts', Array('decir_see_deleted_post'), 'Special|DecirPost|DecirTopic|DecirForum');
$session->register_acl_type('decir_see_deleted_topic', AUTH_ALLOW, 'See placeholders for deleted topics', Array('read'), 'DecirTopic|DecirForum');
- $session->register_acl_type('decir_see_deleted_topic_full', AUTH_DISALLOW, 'Read the full contents of deleted topics', Array('decir_see_deleted_topic'), 'DecirTopic|DecirForum');
+ $session->register_acl_type('decir_see_deleted_topic_full', AUTH_DISALLOW, 'Read the full contents of deleted topics', Array('decir_see_deleted_topic'), 'Special|DecirTopic|DecirForum');
}
function page_Special_Forum()