X-Git-Url: https://defaria.com/gitweb/?a=blobdiff_plain;f=maps%2Fbin%2Fdetail.cgi;fp=maps%2Fbin%2Fdetail.cgi;h=ee2d2f4352ec04d190e7583b355fe1d84fbad480;hb=8d6e59ba7728e19d42da1533b9f24d0216867899;hp=f4885fd77053a8a9829cfbf747171462314d20b7;hpb=2911826fd83a57b69c528e4daaf8df30c00b6d2b;p=clearscm.git diff --git a/maps/bin/detail.cgi b/maps/bin/detail.cgi index f4885fd..ee2d2f4 100755 --- a/maps/bin/detail.cgi +++ b/maps/bin/detail.cgi @@ -240,7 +240,11 @@ sub Body($) { } # unless } # unless - my ($list, $sequence, $comment); + $hit_count //= ''; + + my $list = ''; + my $sequence = 0; + my $comment = ''; # Parse rule if ($rule) { @@ -259,6 +263,7 @@ sub Body($) { $rule =~ s/\\@/\@/; } # if + $sequence //= 0; $next++; # Start Sender line @@ -311,12 +316,18 @@ sub Body($) { }, $comment; print end_Tr; + my $msgnbr = 0; + for my $rec (@$msgs) { + $msgnbr++; + # We increased $next earlier so do not add 1 here if (($next % $lines) == (@senders % $lines)) { $dataclass = 'tablebottomdata'; - $rightclass = 'tablebottomright'; - $subjectclass = 'subjectbottom'; + $rightclass = 'tablebottomright' if $msgnbr == @$msgs; + + # Only subjectbottom the last message + $subjectclass = 'subjectbottom' if $msgnbr == @$msgs; } # if if ($date eq substr ($rec->{timestamp}, 0, 10)) { @@ -336,11 +347,11 @@ sub Body($) { -class => $subjectclass, -colspan => 4, }, a { - -href => "display.cgi?sender=$sender;msg_date=$rec->{timestamp}", + -href => "display.cgi?sender=$sender;msg_date=$rec->{timestamp}", }, '    ' . $rec->{subject}, - td {-class => $rightclass, - -width => '150', - -align => 'right'}, span {-class => 'date'}, $rec->{date} . ' ', + td {-class => $rightclass, + -width => '150', + -align => 'right'}, span {-class => 'date'}, $rec->{date} . ' ', ]; } # for } # for @@ -388,8 +399,10 @@ if ($date eq '') { $condition .= "type = '$type' and timestamp > '$sod' and timestamp < '$eod'"; } # if -$total = CountLog( +# Need to count distinct on sender +$total = CountLogDistinct( userid => $userid, + column => 'sender', additional => $condition, );