#!/usr/bin/perl # # $Id: bugrindex.pl,v 1.3 2006/01/23 21:39:30 ddoughty Exp $ # # Source File: bugrindex.pl # Get config require 'bugsitecfg.pl'; &app_initialize; print "Content-Type: text/html\n\n"; opendir(DIR, $dataroot); print "\n"; # @rpts = grep { /rptdefect\./ && -f "$_" } readdir(DIR); @rpts = readdir(DIR); closedir DIR; $cnt = 0; print "\n\n"; print "New Report
\n"; foreach $rpt (@rpts) { if ($rpt =~ /rptdefect./) { $cnt++; &get_report($rpt); ($trash, $rno) = split(/\./, $rpt); if ($REPORT{'status'} eq 'r') { push @statusr, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'f') { push @statusf, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'd') { push @statusd, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'e') { push @statuse, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'u') { push @statusu, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'c') { push @statusc, "$rno - $REPORT{'title'}
 
"; } elsif ($REPORT{'status'} eq 'w') { push @statusw, "$rno - $REPORT{'title'}
 
"; } else { push @statuso, "$rno - $REPORT{'title'}
 
"; } } } @rpts = (); if ($cnt > 0) { print "
Regression Test Deviations
\n"; foreach $statusr (@statusr) { print "$statusr\n"; } print "
Open
\n"; foreach $statuso (@statuso) { print "$statuso\n"; } print "
Under Review
\n"; foreach $statusu (@statusu) { print "$statusu\n"; } print "
Work Around
\n"; foreach $statusw (@statusw) { print "$statusw\n"; } print "
Enhancements
\n"; foreach $statuse (@statuse) { print "$statuse\n"; } print "
Fixed
\n"; foreach $statusf (@statusf) { print "$statusf\n"; } print "
Design Issues
\n"; foreach $statusd (@statusd) { print "$statusd\n"; } print "
Closed
\n"; foreach $statusc (@statusc) { print "$statusc\n"; } print "
\n"; } else { print "No reports.
\n"; } print "
\n\n";