diff options
author | myk%mozilla.org <> | 2006-01-06 23:22:55 +0100 |
---|---|---|
committer | myk%mozilla.org <> | 2006-01-06 23:22:55 +0100 |
commit | 199d6ed76f022232c3799036c75661604a6d70d4 (patch) | |
tree | 2def77ae1ab734f5131b22e609b013734f2620fb /Bugzilla.pm | |
parent | 8a751a1e448b17a66a63b5728ffce0b456bc762b (diff) | |
download | bugzilla-199d6ed76f022232c3799036c75661604a6d70d4.tar.gz bugzilla-199d6ed76f022232c3799036c75661604a6d70d4.tar.xz |
Bug 287325: an initial implementation of custom fields, including the ability to add text custom fields via the command-line script customfield.pl, search them via the boolean charts, display and edit them on the show bug page, and see changes to them in bug activity; r=mkanat, glob
Diffstat (limited to 'Bugzilla.pm')
-rw-r--r-- | Bugzilla.pm | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/Bugzilla.pm b/Bugzilla.pm index 86d6e6e70..5267f3dbd 100644 --- a/Bugzilla.pm +++ b/Bugzilla.pm @@ -35,6 +35,7 @@ use Bugzilla::Template; use Bugzilla::User; use Bugzilla::Error; use Bugzilla::Util; +use Bugzilla::Field; use File::Basename; @@ -276,6 +277,17 @@ sub switch_to_main_db { return $class->dbh; } +sub get_fields { + my $class = shift; + my $criteria = shift; + return Bugzilla::Field::match($criteria); +} + +sub custom_field_names { + # Get a list of custom fields and convert it into a list of their names. + return map($_->{name}, Bugzilla::Field::match({ custom=>1, obsolete=>0 })); +} + # Private methods # Per process cleanup |