Bugzilla::Status - Bug status class.
use Bugzilla::Status;
my $bug_status = new Bugzilla::Status({name => 'ASSIGNED'});
my $bug_status = new Bugzilla::Status(4);
my @closed_bug_statuses = closed_bug_statuses();
Bugzilla::Status::add_missing_bug_status_transitions($bug_status);
Status.pm represents a bug status object. It is an implementation of Bugzilla::Object, and thus provides all methods that Bugzilla::Object provides.
The methods that are specific to Bugzilla::Status are listed below.
closed_bug_statuses Description: Returns a list of C<Bugzilla::Status> objects which can have
a resolution associated with them ("closed" bug statuses).
Params: none.
Returns: A list of Bugzilla::Status objects.
can_change_to Description: Returns the list of active statuses a bug can be changed to
given the current bug status. If this method is called as a
class method, then it returns all bug statuses available on
bug creation.
Params: none.
Returns: A list of Bugzilla::Status objects.
can_change_from 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<can_change_to> instead.
Params: none.
Returns: A list of Bugzilla::Status objects.
allow_change_fromTells you whether or not a change to this status from another status is allowed.
$old_status - The Bugzilla::Status you're changing from.
$product - A Bugzilla::Product representing the product of the bug you're changing. Needed to check product-specific workflow issues (such as whether or not the UNCONFIRMED status is enabled in this product).1 if you are allowed to change to this status from that status, or 0 if you aren't allowed.
Note that changing from a status to itself is always allowed.
comment_required_on_change_fromChecks if a comment is required to change to this status from another status, according to the current settings in the workflow.
Note that this doesn't implement the checks enforced by the various commenton parameters--those are checked by internal checks in Bugzilla::Bug.
$old_status - The status you're changing from.
1 if a comment is required on this change, 0 if not.
add_missing_bug_status_transitionsDescription: Insert all missing transitions to a given bug status. Params: $bug_status - The value (name) of a bug status. Returns: nothing.