5.7.207. Bugzilla::Extension::Releases::Schedule

5.7.207.1. NAME

Bugzilla::Extension::Releases::Schedule - Red Hat Bugzilla Release Schedule class.

5.7.207.2. SYNOPSIS

use Bugzilla::Extension::Releases::Schedule;

my $schedule = Bugzilla::Extension::Releases::Schedule->new($schedule_id);
my $schedule = Bugzilla::Extension::Releases::Schedule->new({ release => $release_name });
my $schedule = Bugzilla::Extension::Releases::Schedule->new({ release_id => $release_id });

my $schedule = Bugzilla::Extension::Releases::Schedule->check({ release => $release_name });
my $schedule = Bugzilla::Extension::Releases::Schedule->check({ release_id => $release_id });

my $schedule =
  Bugzilla::Extension::Releases::Release->create({ release => $release_name,
                                              phases  => $phases });

$schedule->set_phases($new_phases);
$schedule->set_release_id($release->id);

$schedule->update();

$schedule->remove_from_db;

5.7.207.3. DESCRIPTION

Release.pm represents a Red Hat Bugzilla Release object.

5.7.207.4. METHODS

  • new($param)
Description: The constructor is used to load an existing Release Schedule
             by passing a release ID or a hash with the release
             name.

Params:      $param - If you pass an integer, the integer is the
                      release ID from the database that we want to
                      read in. If you pass in a hash with the 'release'
                      key, then the value of the release
                      key is the release name.

Returns:     A Release Schedule object.
  • set_release_id
Description: Changes the release id of the schedule.

Params:      $new_release_id - new release_id of the schedule (integer).

Returns:     Nothing.
  • set_phases
Description: Changes the schedule phases of the release.

Params:      $new_phases - a hash reference containing phase names which are references
             to other hashes containing their start and end dates.
             NOTE: This is a make exact type operation. Any phases not passed in will be removed.
             { development => { date_start => 'YYYY-MM-DD', date_end => 'YYYY-MM-DD' } }

Returns:     Nothing.
  • update()
Description: Write changes made to the schedule into the DB.

Params:      none.

Returns:     A hashref with changes made to the schedule object.
  • remove_from_db()
Description: Deletes the current full schedule from the DB. The object itself
             is not destroyed.

Params:      none.

Returns:     Nothing.

5.7.207.5. CLASS METHODS

  • create(\%params)
Description: Create a new schedule.

Params:      The hashref must have the following keys:
             release - release name for the new schedule (string).
             phases  - a hash reference containing phase names which are references
             to other hashes containing their start and end dates (hash)
             { development => { date_start => 'YYYY-MM-DD', date_end => 'YYYY-MM-DD' } }

Returns:     A Release Schedule object.

This documentation undoubtedly has bugs; if you find some, please file them here.