Custom fields product specific

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

Custom fields product specific

Sebastian Huber-2
Hello,

i was wondering if there is a /will be a solution to create custom fields
specific for every issue. It would be very suitable for the company i am
working for. We like the BugZilla conception, but having no product specific
fields would be a knock-out criterion.

Regards,

Sebastian Huber


_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you reply.
Reply | Threaded
Open this post in threaded view
|

Re: Custom fields product specific

Unca Ghryswald
Sebastian Huber-2 wrote
...will there be a solution to create product specific custom fields...
Sebastian Huber
Sebastian,
If you're looking to "hide" specific fields for certain Products, you can edit the templates to allow/deny the field display on your forms, effectively giving yourself "product specific custom fields."

For example:  I don't want my "cf_steps_to_reproduce" field displayed with the other custom fields.  So I added the code below to prevent that field from displaying when the other custom fields are presented on the served page.
[% IF field.name != "cf_steps_to_reproduce" %]
      [% PROCESS bug/create_field.html.tmpl editable=1 value_span=0 %]
[% END %]


You can do the same by identifying PRODUCT names.  Perhaps going so far as to create a [BLOCK] for each product that has different exceptions.  That would keep your logic uncomplicated, but add a bit of length to your templates.

There is a *LOT* you can do simply by manipulating the templates and adding/maipulating the existing javascript.

Good Luck!
Unca Ghrys
Reply | Threaded
Open this post in threaded view
|

RE: Custom fields product specific

Tosh, Michael J
Creating per-issue custom fields would be a nightmare for the advanced
search page.  I do a similar thing for my installation, where I added a
'like' parameter to the get_fields function.  then I can do
Bugzilla->getfields(like => "cf_${product.name}") to get a list of
product-specific fields to show.


-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Unca
Ghryswald
Sent: Wednesday, November 21, 2007 9:27 AM
To: [hidden email]
Subject: Re: Custom fields product specific



Sebastian Huber-2 wrote:
>
> ...will there be a solution to create product specific custom
fields...
> Sebastian Huber
>

Sebastian,
If you're looking to "hide" specific fields for certain Products, you
can
edit the templates to allow/deny the field display on your forms,
effectively giving yourself "product specific custom fields."

For example:  I don't want my "cf_steps_to_reproduce" field displayed
with
the other custom fields.  So I added the code below to prevent that
field
from displaying when the other custom fields are presented on the served
page.
[% IF field.name != "cf_steps_to_reproduce" %]
      [% PROCESS bug/create_field.html.tmpl editable=1 value_span=0 %]
[% END %]

You can do the same by identifying PRODUCT names.  Perhaps going so far
as
to create a [BLOCK] for each product that has different exceptions.
That
would keep your logic uncomplicated, but add a bit of length to your
templates.

There is a *LOT* you can do simply by manipulating the templates and
adding/maipulating the existing javascript.

Good Luck!
Unca Ghrys
--
View this message in context:
http://www.nabble.com/Custom-fields-product-specific-tf4850173.html#a138
78056
Sent from the Bugzilla - Users mailing list archive at Nabble.com.

_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you
reply.
_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you reply.
Reply | Threaded
Open this post in threaded view
|

Re: Custom fields product specific

Richard Quinn
In reply to this post by Unca Ghryswald
Hey that#s a good idea.

I suppose that it is extensible to other levels of granularity:
classification and component.
Ideas?

- Richard

On Nov 21, 3:38 pm, "Tosh, Michael J" <[hidden email]> wrote:

> Creating per-issue custom fields would be a nightmare for the advanced
> search page.  I do a similar thing for my installation, where I added a
> 'like' parameter to the get_fields function.  then I can do
> Bugzilla->getfields(like => "cf_${product.name}") to get a list of
> product-specific fields to show.
>
> -----Original Message-----
> From: [hidden email]
>
> [mailto:[hidden email]] On Behalf Of Unca
> Ghryswald
> Sent: Wednesday, November 21, 2007 9:27 AM
> To: [hidden email]
> Subject: Re: Custom fields product specific
>
> Sebastian Huber-2 wrote:
>
> > ...will there be a solution to create product specific custom
> fields...
> > Sebastian Huber
>
> Sebastian,
> If you're looking to "hide" specific fields for certain Products, you
> can
> edit the templates to allow/deny the field display on your forms,
> effectively giving yourself "product specific custom fields."
>
> For example:  I don't want my "cf_steps_to_reproduce" field displayed
> with
> the other custom fields.  So I added the code below to prevent that
> field
> from displaying when the other custom fields are presented on the served
> page.
> [% IF field.name != "cf_steps_to_reproduce" %]
>       [% PROCESS bug/create_field.html.tmpl editable=1 value_span=0 %]
> [% END %]
>
> You can do the same by identifying PRODUCT names.  Perhaps going so far
> as
> to create a [BLOCK] for each product that has different exceptions.
> That
> would keep your logic uncomplicated, but add a bit of length to your
> templates.
>
> There is a *LOT* you can do simply by manipulating the templates and
> adding/maipulating the existing javascript.
>
> Good Luck!
> Unca Ghrys
> --
> View this message in context:http://www.nabble.com/Custom-fields-product-specific-tf4850173.html#a138
> 78056
> Sent from the Bugzilla - Users mailing list archive at Nabble.com.
>
> _______________________________________________
> support-bugzilla mailing list
> [hidden email]://lists.mozilla.org/listinfo/support-bugzilla
> PLEASE put [hidden email] in the To: field when you
> reply.

_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you reply.
Reply | Threaded
Open this post in threaded view
|

RE: Custom fields product specific

Tosh, Michael J
All depends on how you name your custom fields.  My fields are
cf_productname_fieldname. I also added a notlike parameter.

In Bugzilla/Field.pm, I added the following 2 IF statements in the match
sub, after name.

<     if (defined $criteria->{like}) {
<         push(@terms, "name like " .
Bugzilla->dbh->quote($criteria->{like}));
<     }
<     if (defined $criteria->{notlike}) {
<         push(@terms, "name not like " .
Bugzilla->dbh->quote($criteria->{notlike}));
<     }

Then use:
Bugzilla->getfields(like => "cf_${product.name}%")

(I had put %'s around the like and not like in Field.pm, but it makes
more sense to put it in the getfields call. More flexibility.  If I add
a field, cf_licf_line, it was possible to match cf_li AND cf_line)

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Richard
Quinn
Sent: Friday, November 23, 2007 9:00 AM
To: [hidden email]
Subject: Re: Custom fields product specific

Hey that#s a good idea.

I suppose that it is extensible to other levels of granularity:
classification and component.
Ideas?

- Richard

On Nov 21, 3:38 pm, "Tosh, Michael J" <[hidden email]> wrote:
> Creating per-issue custom fields would be a nightmare for the advanced
> search page.  I do a similar thing for my installation, where I added
a

> 'like' parameter to the get_fields function.  then I can do
> Bugzilla->getfields(like => "cf_${product.name}") to get a list of
> product-specific fields to show.
>
> -----Original Message-----
> From: [hidden email]
>
> [mailto:[hidden email]] On Behalf Of Unca
> Ghryswald
> Sent: Wednesday, November 21, 2007 9:27 AM
> To: [hidden email]
> Subject: Re: Custom fields product specific
>
> Sebastian Huber-2 wrote:
>
> > ...will there be a solution to create product specific custom
> fields...
> > Sebastian Huber
>
> Sebastian,
> If you're looking to "hide" specific fields for certain Products, you
> can
> edit the templates to allow/deny the field display on your forms,
> effectively giving yourself "product specific custom fields."
>
> For example:  I don't want my "cf_steps_to_reproduce" field displayed
> with
> the other custom fields.  So I added the code below to prevent that
> field
> from displaying when the other custom fields are presented on the
served
> page.
> [% IF field.name != "cf_steps_to_reproduce" %]
>       [% PROCESS bug/create_field.html.tmpl editable=1 value_span=0 %]
> [% END %]
>
> You can do the same by identifying PRODUCT names.  Perhaps going so
far

> as
> to create a [BLOCK] for each product that has different exceptions.
> That
> would keep your logic uncomplicated, but add a bit of length to your
> templates.
>
> There is a *LOT* you can do simply by manipulating the templates and
> adding/maipulating the existing javascript.
>
> Good Luck!
> Unca Ghrys
> --
> View this message in
context:http://www.nabble.com/Custom-fields-product-specific-tf4850173.h
tml#a138
> 78056
> Sent from the Bugzilla - Users mailing list archive at Nabble.com.
>
> _______________________________________________
> support-bugzilla mailing list
>
[hidden email]://lists.mozilla.org/listinfo/sup
port-bugzilla
> PLEASE put [hidden email] in the To: field when
you
> reply.

_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you
reply.
_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you reply.
Reply | Threaded
Open this post in threaded view
|

Re: Custom fields product specific

Sebastian Huber-2
In reply to this post by Richard Quinn
Thank you so far for the good ideas!

Sebastian Huber

"Tosh, Michael J" <[hidden email]> schrieb im Newsbeitrag
news:[hidden email]...

> All depends on how you name your custom fields.  My fields are
> cf_productname_fieldname. I also added a notlike parameter.
>
> In Bugzilla/Field.pm, I added the following 2 IF statements in the match
> sub, after name.
>
> <     if (defined $criteria->{like}) {
> <         push(@terms, "name like " .
> Bugzilla->dbh->quote($criteria->{like}));
> <     }
> <     if (defined $criteria->{notlike}) {
> <         push(@terms, "name not like " .
> Bugzilla->dbh->quote($criteria->{notlike}));
> <     }
>
> Then use:
> Bugzilla->getfields(like => "cf_${product.name}%")
>
> (I had put %'s around the like and not like in Field.pm, but it makes
> more sense to put it in the getfields call. More flexibility.  If I add
> a field, cf_licf_line, it was possible to match cf_li AND cf_line)
>
> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]] On Behalf Of Richard
> Quinn
> Sent: Friday, November 23, 2007 9:00 AM
> To: [hidden email]
> Subject: Re: Custom fields product specific
>
> Hey that#s a good idea.
>
> I suppose that it is extensible to other levels of granularity:
> classification and component.
> Ideas?
>
> - Richard
>
> On Nov 21, 3:38 pm, "Tosh, Michael J" <[hidden email]> wrote:
>> Creating per-issue custom fields would be a nightmare for the advanced
>> search page.  I do a similar thing for my installation, where I added
> a
>> 'like' parameter to the get_fields function.  then I can do
>> Bugzilla->getfields(like => "cf_${product.name}") to get a list of
>> product-specific fields to show.
>>
>> -----Original Message-----
>> From: [hidden email]
>>
>> [mailto:[hidden email]] On Behalf Of Unca
>> Ghryswald
>> Sent: Wednesday, November 21, 2007 9:27 AM
>> To: [hidden email]
>> Subject: Re: Custom fields product specific
>>
>> Sebastian Huber-2 wrote:
>>
>> > ...will there be a solution to create product specific custom
>> fields...
>> > Sebastian Huber
>>
>> Sebastian,
>> If you're looking to "hide" specific fields for certain Products, you
>> can
>> edit the templates to allow/deny the field display on your forms,
>> effectively giving yourself "product specific custom fields."
>>
>> For example:  I don't want my "cf_steps_to_reproduce" field displayed
>> with
>> the other custom fields.  So I added the code below to prevent that
>> field
>> from displaying when the other custom fields are presented on the
> served
>> page.
>> [% IF field.name != "cf_steps_to_reproduce" %]
>>       [% PROCESS bug/create_field.html.tmpl editable=1 value_span=0 %]
>> [% END %]
>>
>> You can do the same by identifying PRODUCT names.  Perhaps going so
> far
>> as
>> to create a [BLOCK] for each product that has different exceptions.
>> That
>> would keep your logic uncomplicated, but add a bit of length to your
>> templates.
>>
>> There is a *LOT* you can do simply by manipulating the templates and
>> adding/maipulating the existing javascript.
>>
>> Good Luck!
>> Unca Ghrys
>> --
>> View this message in
> context:http://www.nabble.com/Custom-fields-product-specific-tf4850173.h
> tml#a138
>> 78056
>> Sent from the Bugzilla - Users mailing list archive at Nabble.com.
>>
>> _______________________________________________
>> support-bugzilla mailing list
>>
> [hidden email]://lists.mozilla.org/listinfo/sup
> port-bugzilla
>> PLEASE put [hidden email] in the To: field when
> you
>> reply.
>
> _______________________________________________
> support-bugzilla mailing list
> [hidden email]
> https://lists.mozilla.org/listinfo/support-bugzilla
> PLEASE put [hidden email] in the To: field when you
> reply.


_______________________________________________
support-bugzilla mailing list
[hidden email]
https://lists.mozilla.org/listinfo/support-bugzilla
PLEASE put [hidden email] in the To: field when you reply.