summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTiago Mello <timello@gmail.com>2011-10-15 17:13:08 +0200
committerTiago Mello <timello@gmail.com>2011-10-15 17:13:08 +0200
commit25603c4968b0f69170ea2aa122f6fc92ca14581a (patch)
tree82fe4a6e64d246b50a086fde9d5048d593f5243b
parentf7e95019ed490a8e3b783a17b031bb29f19efd28 (diff)
downloadbugzilla-25603c4968b0f69170ea2aa122f6fc92ca14581a.tar.gz
bugzilla-25603c4968b0f69170ea2aa122f6fc92ca14581a.tar.xz
Bug 689862: Fix Product.get to only return the Classification name,
instead of all the classification info. r/a=LpSolit
-rw-r--r--Bugzilla/WebService/Product.pm19
1 files changed, 2 insertions, 17 deletions
diff --git a/Bugzilla/WebService/Product.pm b/Bugzilla/WebService/Product.pm
index 0f4c858d7..07633dcaf 100644
--- a/Bugzilla/WebService/Product.pm
+++ b/Bugzilla/WebService/Product.pm
@@ -195,7 +195,7 @@ sub _product_to_hash {
is_active => $self->type('boolean', $product->is_active),
default_milestone => $self->type('string', $product->default_milestone),
has_unconfirmed => $self->type('boolean', $product->allows_unconfirmed),
- classification => $self->_classification_to_hash($product->classification),
+ classification => $self->type('string', $product->classification->name),
};
if (filter_wants($params, 'components')) {
$field_data->{components} = [map {
@@ -215,20 +215,6 @@ sub _product_to_hash {
return filter($params, $field_data);
}
-sub _classification_to_hash {
- my ($self, $classification) = @_;
- return {
- id =>
- $self->type('int', $classification->id),
- name =>
- $self->type('string', $classification->name),
- description =>
- $self->type('string' , $classification->description),
- sort_key =>
- $self->type('int', $classification->sortkey),
- };
-}
-
sub _component_to_hash {
my ($self, $component) = @_;
return {
@@ -427,8 +413,7 @@ for this product.
=item C<classification>
-C<hash> Contains the classification C<id>, C<name>, C<description>
-and C<sort_key> as keys.
+C<string> The classification name for the product.
=item C<components>