RSS

(root)/bugzilla/2.18 : 555 : globals.pl

To get this branch, use:
bzr branch /bugzilla/2.18

« back to all changes in this revision

Viewing changes to globals.pl

dmose%mozilla.org
2000-03-28 21:30:23
Revision ID: cvs-1:dmosemozilla.org-20000329053023-zjgs6h6f6250c5i0
allow users to watch the bugs of other users

Show diffs side-by-side

added added

removed removed

18
18
# Rights Reserved.
19
19
#
20
20
# Contributor(s): Terry Weissman <terry@mozilla.org>
 
21
#                 Dan Mosedale <dmose@mozilla.org>
21
22
 
22
23
# Contains some global variables and routines used throughout bugzilla.
23
24
 
65
66
use Date::Format;               # For time2str().
66
67
use Date::Parse;               # For str2time().
67
68
# use Carp;                       # for confess
 
69
use RelationSet;
68
70
 
69
71
# Contains the version string for the current running Bugzilla.
70
72
$::param{'version'} = '2.9';
118
120
    }
119
121
}
120
122
    
121
 
 
122
 
 
123
 
 
124
123
sub SendSQL {
125
124
    my ($str, $dontshadow) = (@_);
126
125
    my $iswrite =  ($str =~ /^(INSERT|REPLACE|UPDATE|DELETE)/i);
756
755
}
757
756
 
758
757
sub ShowCcList {
759
 
    my ($num) = (@_);
760
 
    my @ccids;
761
 
    my @row;
762
 
    SendSQL("select who from cc where bug_id = $num");
763
 
    while (@row = FetchSQLData()) {
764
 
        push(@ccids, $row[0]);
765
 
    }
766
 
    my @result = ();
767
 
    foreach my $i (@ccids) {
768
 
        push @result, DBID_to_name($i);
769
 
    }
770
 
 
771
 
    return join(',', @result);
 
758
   my ($num) = (@_);
 
759
   
 
760
   my $ccSet = new RelationSet();
 
761
   $ccSet->mergeFromDB("select who from cc where bug_id=$num");
 
762
   return $ccSet->toString();
772
763
}
773
764
 
774
 
 
775
 
 
776
765
# Fills in a hashtable with info about the columns for the given table in the
777
766
# database.  The hashtable has the following entries:
778
767
#   -list-  the list of column names
903
892
}
904
893
 
905
894
 
906
 
sub Param {
 
895
sub Param ($) {
907
896
    my ($value) = (@_);
908
897
    if (defined $::param{$value}) {
909
898
        return $::param{$value};

Loggerhead 1.18.1 is a web-based interface for Bazaar branches