Added hit_count
[clearscm.git] / maps / bin / detail.cgi
index 2bac172..b4c3e90 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 #################################################################################
+#
 # File:         $RCSfile: detail.cgi,v $
 # Revision:     $Revision: 1.1 $
 # Description:  Displays list of email addresses based on report type.
@@ -10,7 +11,8 @@
 #
 # (c) Copyright 2000-2006, Andrew@DeFaria.com, all rights reserved.
 #
-################################################################################use strict;
+################################################################################
+use strict;
 use warnings;
 
 use MIME::Words qw(:all);
@@ -172,17 +174,17 @@ sub PrintTable {
   foreach my $sender (ReturnSenders $userid, $type, $next, $lines, $date) {
     my @msgs = ReturnMessages $userid, $sender;
     my @msgs2 = @msgs;
+    my $onlist;
+    my $rule      = 'none';
+    my $hit_count = 0;
 
-    my ($onlist, $rule);
-    $rule = 'none';
-
-    ($onlist, $rule) = OnNulllist $sender;
+    ($onlist, $rule, $hit_count) = OnWhitelist $sender, $userid, 0;
 
     unless ($onlist) {
-      ($onlist, $rule) = OnBlacklist $sender;
+      ($onlist, $rule, $hit_count) = OnBlacklist $sender, 0;
 
       unless ($onlist) {
-        ($onlist, $rule) = OnWhitelist $sender;
+        ($onlist, $rule, $hit_count) = OnNulllist $sender, 0;
       } # unless
     } # unless
 
@@ -193,7 +195,7 @@ sub PrintTable {
       if ($rule =~ /(\w+):(\d+)/) {
         my $list     = $1;
         my $sequence = $2 - 1;
-        my $link     = "<a href=\"/maps/php/list.php?type=$list&next=$sequence\">$list:$2</a>";
+        my $link     = "<a href=\"/maps/php/list.php?type=$list&next=$sequence\">$list:$2</a>/$hit_count";
 
         $rule =~ s/\w+:\d+/$link/;
       } # if
@@ -293,6 +295,7 @@ sub PrintTable {
 } # PrintTable
 
 # Main
+my $condition;
 my @scripts = ('ListActions.js');
 
 my $heading_date =$date ne '' ? ' on ' . FormatDate ($date) : '';