Closed
Bug 401953
Opened 18 years ago
Closed 18 years ago
Move work_time validation from process_bug to Bugzilla::Bug
Categories
(Bugzilla :: Creating/Changing Bugs, enhancement)
Tracking
()
RESOLVED
FIXED
Bugzilla 3.2
People
(Reporter: mkanat, Assigned: mkanat)
References
Details
Attachments
(1 file)
2.85 KB,
patch
|
LpSolit
:
review+
|
Details | Diff | Splinter Review |
This is part of adding a comment, really, at this point, so that's how it's going to have to work.
Assignee | ||
Comment 1•18 years ago
|
||
Okay, so work_time is already actually updated in Bugzilla::Bug, but there's just a bit of validation that has to be moved into process_bug--the part that checks that a comment has actually been made.
Summary: Move work_time updating from process_bug to Bugzilla::Bug → Move work_time comment validation from process_bug to Bugzilla::Bug
Assignee | ||
Updated•18 years ago
|
Summary: Move work_time comment validation from process_bug to Bugzilla::Bug → Move work_time validation from process_bug to Bugzilla::Bug
Assignee | ||
Comment 2•18 years ago
|
||
This is pretty straightforward. I tested it and it works.
Attachment #286893 -
Flags: review?(LpSolit)
![]() |
||
Comment 3•18 years ago
|
||
Comment on attachment 286893 [details] [diff] [review]
v1
>+++ process_bug.cgi
>-# Validate work_time
>-if (defined $cgi->param('work_time')
>- && $cgi->param('work_time') ne $cgi->param('dontchange'))
You are lucky that you cannot edit work_time when editing several bugs at once. Else you could pass --do-not-change-- to _check_time() and it would complain.
> $bug_objects{$id}->add_comment(scalar($cgi->param('comment')),
> { isprivate => scalar($cgi->param('commentprivacy')),
>- work_time => $work_time, type => $type,
>+ work_time => scalar $cgi->param('work_time'), type => $type,
> extra_data => $duplicate});
Nit: type => $type could now be on its own line.
Your patch seems to work correctly, even when editing several bugs at once. The bug I found while testing your patch is unrelated to it, so that's fine. ;) r=LpSolit
Attachment #286893 -
Flags: review?(LpSolit) → review+
![]() |
||
Updated•18 years ago
|
Flags: approval+
Assignee | ||
Comment 4•18 years ago
|
||
Checking in process_bug.cgi;
/cvsroot/mozilla/webtools/bugzilla/process_bug.cgi,v <-- process_bug.cgi
new revision: 1.392; previous revision: 1.391
done
Checking in Bugzilla/Bug.pm;
/cvsroot/mozilla/webtools/bugzilla/Bugzilla/Bug.pm,v <-- Bug.pm
new revision: 1.213; previous revision: 1.212
done
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•