Closed Bug 1154026 Opened 9 years ago Closed 9 years ago

Pre-fill Bounty Attachment form fields for e.g. date and reporter

Categories

(bugzilla.mozilla.org :: General, defect)

Production
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: freddy, Assigned: dylan)

References

()

Details

Attachments

(1 file)

Some things could be clearly pre-filled, this would make editing the form much easier.

reporter: from bug creation
reported date: from bug creation
fixed date: from when bug was marked fixed
awarded date (to "today"))
publish: default to yes

Even if they might be incorrect, we could still
yes, please!
Assignee: nobody → dylan
Component: Custom Bug Entry Forms → General
Important clarification since freddy mentioned the word "edit" (please read his request s/editing/filling out/): this enhancement request is for when the attachment is first created!

We do not want pre-existing values over-written.
Status: NEW → ASSIGNED
OS: Linux → All
Hardware: x86_64 → All
Change is up on bugzilla-dev, let me know if you're not in the bounty-team on -dev. 

https://bugzilla-dev.allizom.org/page.cgi?id=attachment_bounty_form.html&bug_id=69267
Flags: needinfo?(fbraun)
Let me know if this behaves as you expect.
Flags: needinfo?(dveditz)
Currently, "reporter" is pre-filled with my current login, when it should instead default to the bugzilla id from the person who reported the bug. Besides this, we're good to go.
Flags: needinfo?(fbraun)
Flags: needinfo?(dveditz)
Attached patch 1154026_1.patchSplinter Review
Uses $bug->reporter now. Pretty simple patch, picking glob as he's made changes to it in the past.
Attachment #8597995 - Flags: review?(glob)
I just tested this on the dev site and it looks good.  When could we expect this on the production site?
Comment on attachment 8597995 [details] [diff] [review]
1154026_1.patch

Review of attachment 8597995 [details] [diff] [review]:
-----------------------------------------------------------------

r=glob, fix date issue on commit

::: extensions/BMO/Extension.pm
@@ +267,5 @@
> +    else {
> +        $vars->{form} = {
> +            reporter_email => $bug->reporter->email,
> +            reported_date  => format_time($bug->creation_ts, "%Y-%m-%d"),
> +            awarded_date   => format_time(DateTime->now, "%Y-%m-%d"),

you need to ask the database for the date to ensure the correct date is used when the user tz pref doesn't match the server's
Attachment #8597995 - Flags: review?(glob) → review+
To ssh://gitolite3@git.mozilla.org/webtools/bmo/bugzilla.git
   c19995a..2d50ce5  master -> master


(In reply to Raymond Forbes[:rforbes] from comment #7)
> I just tested this on the dev site and it looks good.  When could we expect
> this on the production site?

this will land on prod within the next couple of hours.

generally we push every week at about this time (the time of this comment), so it can take up to a week for reviewed and committed changes to land on production.  you can follow blog.glob.com.au or https://wiki.mozilla.org/BMO/Recent_Changes to keep abreast of changes as they land on production.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: