From e1b433e3d54504dceb151213d4addac42a1e5ca9 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Sat, 12 Dec 2009 21:55:15 +0000 Subject: Bug 512606: Make statuses currently available for the user to change this bug to be controlled by Bugzilla::Bug, not the template Patch by Max Kanat-Alexander r=LpSolit, a=LpSolit --- Bugzilla/Status.pm | 33 --------------------------------- 1 file changed, 33 deletions(-) (limited to 'Bugzilla/Status.pm') diff --git a/Bugzilla/Status.pm b/Bugzilla/Status.pm index 4720dc129..4d1281e7e 100644 --- a/Bugzilla/Status.pm +++ b/Bugzilla/Status.pm @@ -176,28 +176,6 @@ sub can_change_to { return $self->{'can_change_to'}; } -sub can_change_from { - my $self = shift; - my $dbh = Bugzilla->dbh; - - if (!defined $self->{'can_change_from'}) { - my $old_status_ids = $dbh->selectcol_arrayref('SELECT old_status - FROM status_workflow - INNER JOIN bug_status - ON id = old_status - WHERE isactive = 1 - AND new_status = ? - AND old_status IS NOT NULL', - undef, $self->id); - - # Allow the bug status to remain unchanged. - push(@$old_status_ids, $self->id); - $self->{'can_change_from'} = Bugzilla::Status->new_from_list($old_status_ids); - } - - return $self->{'can_change_from'}; -} - sub comment_required_on_change_from { my ($self, $old_status) = @_; my ($cond, $values) = $self->_status_condition($old_status); @@ -300,17 +278,6 @@ below. Returns: A list of Bugzilla::Status objects. -=item C - - Description: Returns the list of active statuses a bug can be changed from - given the new bug status. If the bug status is available on - bug creation, this method doesn't return this information. - You have to call C instead. - - Params: none. - - Returns: A list of Bugzilla::Status objects. - =item C =over -- cgit v1.2.3-24-g4f1b