Commit 1c431100 authored by lpsolit%gmail.com's avatar lpsolit%gmail.com

Bug 519040: After creating a new series, redirect the user to a more useful page…

Bug 519040: After creating a new series, redirect the user to a more useful page - Patch by Fré©ric Buclin <LpSolit@gmail.com> r=gerv a=LpSolit
parent aef9ce78
......@@ -142,19 +142,15 @@ elsif ($action eq "create") {
my $series = new Bugzilla::Series($cgi);
if (!$series->existsInDatabase()) {
$series->writeToDatabase();
$vars->{'message'} = "series_created";
}
else {
ThrowUserError("series_already_exists", {'series' => $series});
}
ThrowUserError("series_already_exists", {'series' => $series})
if $series->existsInDatabase;
$series->writeToDatabase();
$vars->{'message'} = "series_created";
$vars->{'series'} = $series;
print $cgi->header();
$template->process("global/message.html.tmpl", $vars)
|| ThrowTemplateError($template->error());
my $chart = new Bugzilla::Chart($cgi);
view($chart);
}
elsif ($action eq "edit") {
detaint_natural($series_id) || ThrowCodeError("invalid_series_id");
......
......@@ -742,9 +742,6 @@
has been created. Note that you may need to wait up to
[%+ series.frequency * 2 %] days before there will be enough data for a
chart of this series to be produced.
<br><br>
Go back or
<a href="query.cgi?format=create-series">create another series</a>.
[% ELSIF message_tag == "shutdown" %]
[% title = "$terms.Bugzilla is Down" %]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment