- queued nodes can now be viewed by the author and the people who voted

for it.
- comments are shown below the queued node, can be disabled in the admin /
  settings and filters.
4.0.x
Kjartan Mannes 2002-03-20 20:04:23 +00:00
parent c7b58a1e63
commit edfc930a41
1 changed files with 35 additions and 31 deletions

View File

@ -10,6 +10,7 @@ function queue_conf_options() {
$output .= form_select(t("Post threshold"), "queue_threshold_post", variable_get("queue_threshold_post", 4), $threshold_post, t("If new submissions are subject to moderation, select a post threshold.")); $output .= form_select(t("Post threshold"), "queue_threshold_post", variable_get("queue_threshold_post", 4), $threshold_post, t("If new submissions are subject to moderation, select a post threshold."));
$output .= form_select(t("Dump threshold"), "queue_threshold_dump", variable_get("queue_threshold_dump", -2), $threshold_dump, t("If new submissions are subject to moderation, select a dump threshold.")); $output .= form_select(t("Dump threshold"), "queue_threshold_dump", variable_get("queue_threshold_dump", -2), $threshold_dump, t("If new submissions are subject to moderation, select a dump threshold."));
$output .= form_select(t("Expiration threshold"),"queue_threshold_expire", variable_get("queue_threshold_expire", 8), $threshold_expire, t("If new submissions are subject to moderation, select an expiration threshold.")); $output .= form_select(t("Expiration threshold"),"queue_threshold_expire", variable_get("queue_threshold_expire", 8), $threshold_expire, t("If new submissions are subject to moderation, select an expiration threshold."));
$output .= form_select(t("Show comments"),"queue_show_comments", variable_get("queue_show_comments", 1), array(0 => "Disabled", 1 => "Enabled"), t("If enabled comments will be shown below the moderation form."));
return $output; return $output;
} }
@ -115,10 +116,7 @@ function queue_view($nid) {
$node = node_load(array("nid" => $nid, "moderate" => 1)); $node = node_load(array("nid" => $nid, "moderate" => 1));
if ($user->uid == $node->uid || field_get($node->users, $user->uid)) { if ($user->uid != $node->uid && !field_get($node->users, $user->uid)) {
drupal_goto("node.php?id=$node->nid");
}
if ($op == t("Vote") && $votes[$edit["vote"]]) { if ($op == t("Vote") && $votes[$edit["vote"]]) {
/* /*
** If it is a valid vote, record it. ** If it is a valid vote, record it.
@ -145,10 +143,16 @@ function queue_view($nid) {
$output = form($output); $output = form($output);
} }
}
$theme->header(); $theme->header();
node_view($node); node_view($node);
if ($output) {
$theme->box(t("Moderate"), $output); $theme->box(t("Moderate"), $output);
}
if ($node->comment && variable_get("queue_show_comments", 1)) {
comment_render($node->nid, 0);
}
$theme->footer(); $theme->footer();
} }