Customizing Bugzilla: New Bug Attribute in Bug Report

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Customizing Bugzilla: New Bug Attribute in Bug Report

Steve Ma
Dear Sirs,

Two Questions:

1. How do I add additional attributes in addition to the existing ones in a
bug report, (ie. add a new "Customers" list for developer to select in
addition to the existing OS, Platform, Product...etc.)? Can this be done in
the <BUGZILLA_ROOT>/template/en/default directory?  Because it seems to have
modified the Table "bugs" in MySQL DB.

2. If I would like to add additional values to existing attributes in bug
report (ie. for Platform attribute, add a new value "Websphere" as a
selection), can this be done via template modification in
<BUGZILLA_ROOT>/template/en/default as well?

Thank you,
Steve


_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Customizing Bugzilla: New Bug Attribute in Bug Report

Jonathan Gdalevich
Hi,

1.  There are several ways of doing it depending on what you want to do.
  For a simple field, the easiest is to change one the existing fields.
  For example, if you do not care about Platform or Severity, all you
have to do is change the database (or checksetup.pl) to replace existing
fields with the ones you want.  Afterwards you can go to each template
and change the name of the field while keeping all the logic the same.
There are also a number of sites on google that tell you how to add
brand new fields but this could be complex depending on what you want to
do.  I read that it is easy to add a simple, single value field in bugs
table.  You can also use flags to store information.

2.  This is much easier, all you have to do is edit the database (or
checksetup.pl).  Platform or OS would require no additional changes,
changing Status or Resolution can require changes in multiple templates.
    I suggest changing the database first and seeing if anything broke.
  Also, read the postings above since they contains information that can
prove useful.

Sincerely,

Jonathan Gdalevich
Software Engineering Intern (ClickFox, Inc.)
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Customizing Bugzilla: New Bug Attribute in Bug Report

A. Karl Kornel
In reply to this post by Steve Ma
In article <d8o8oq$[hidden email]>,
 "Steve Ma" <[hidden email]> wrote:

> Dear Sirs,
>
> Two Questions:
>
> 1. How do I add additional attributes in addition to the existing ones in a
> bug report, (ie. add a new "Customers" list for developer to select in
> addition to the existing OS, Platform, Product...etc.)? Can this be done in
> the <BUGZILLA_ROOT>/template/en/default directory?  Because it seems to have
> modified the Table "bugs" in MySQL DB.

   As Steve already said, the best thing right now would be to simply
hijack one of the other fields to use.  I warn you though, I did this
and there are a LOT of templates to edit, and you still won't be able to
get to everything!  Being able to add custom fields is being tracked as
a bug in bugzilla.mozilla.org, if you want to see how it's going.  Being
able to rename built-in fields is a bug I submitted (#297616), and may
also be covered under other bugs (this is a relatively hot issue).

   As for customers, you may be able to use the keywords sub-system to
cover that.  Simply create one keyword per customer (or customer group,
or whatever).

> 2. If I would like to add additional values to existing attributes in bug
> report (ie. for Platform attribute, add a new value "Websphere" as a
> selection), can this be done via template modification in
> <BUGZILLA_ROOT>/template/en/default as well?

   Platform & OS options can be found in localconfig (NOT
localconfig.js).  Remember to run checksetup.pl after changing the list.  
You can add & delete values, but renaming doesn't seem to go very well.  
localconfig won't exist until you run checksetup.pl for the first time.

   For custom fields like the reproducibility fields used on
bugzilla.mozilla.org, take a look at
<BUGZILLA_ROOT>/template/en/default/bug/create/create-guided.html.tmpl
and
<BUGZILLA_ROOT>/template/en/default/bug/create/comments-guided.txt.tmpl.
--
=============================
|   Alfred Karl Kornel
|   -- [hidden email]
|   Member- Europa Research Group
|   UNIX / RESOLVE Consultant
=============================

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Customizing Bugzilla: New Bug Attribute in Bug Report

Steve Ma
Dear Alfred,

Thank you for your help.  I tried manually adding a new field, which
required altering some of the CGI scripts used to create the DB tables.  It
was quite a painful thing to do and I couldn't imagin maintaince for future
Bugzilla release.  The keyword function seems to be quite useful.  Will
probably stick with that and rename existing fields.

Regards,
Steve

"A. Karl Kornel" <[hidden email]> wrote in message
news:42afc4cf$[hidden email]...

> In article <d8o8oq$[hidden email]>,
> "Steve Ma" <[hidden email]> wrote:
>
>> Dear Sirs,
>>
>> Two Questions:
>>
>> 1. How do I add additional attributes in addition to the existing ones in
>> a
>> bug report, (ie. add a new "Customers" list for developer to select in
>> addition to the existing OS, Platform, Product...etc.)? Can this be done
>> in
>> the <BUGZILLA_ROOT>/template/en/default directory?  Because it seems to
>> have
>> modified the Table "bugs" in MySQL DB.
>
>   As Steve already said, the best thing right now would be to simply
> hijack one of the other fields to use.  I warn you though, I did this
> and there are a LOT of templates to edit, and you still won't be able to
> get to everything!  Being able to add custom fields is being tracked as
> a bug in bugzilla.mozilla.org, if you want to see how it's going.  Being
> able to rename built-in fields is a bug I submitted (#297616), and may
> also be covered under other bugs (this is a relatively hot issue).
>
>   As for customers, you may be able to use the keywords sub-system to
> cover that.  Simply create one keyword per customer (or customer group,
> or whatever).
>
>> 2. If I would like to add additional values to existing attributes in bug
>> report (ie. for Platform attribute, add a new value "Websphere" as a
>> selection), can this be done via template modification in
>> <BUGZILLA_ROOT>/template/en/default as well?
>
>   Platform & OS options can be found in localconfig (NOT
> localconfig.js).  Remember to run checksetup.pl after changing the list.
> You can add & delete values, but renaming doesn't seem to go very well.
> localconfig won't exist until you run checksetup.pl for the first time.
>
>   For custom fields like the reproducibility fields used on
> bugzilla.mozilla.org, take a look at
> <BUGZILLA_ROOT>/template/en/default/bug/create/create-guided.html.tmpl
> and
> <BUGZILLA_ROOT>/template/en/default/bug/create/comments-guided.txt.tmpl.
> --
> =============================
> |   Alfred Karl Kornel
> |   -- [hidden email]
> |   Member- Europa Research Group
> |   UNIX / RESOLVE Consultant
> =============================
>
> ----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet
> News==----
> http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+
> Newsgroups
> ----= East and West-Coast Server Farms - Total Privacy via Encryption
> =----



_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools