Missed Team ’24? Catch up on announcements here.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to specify valid searcher for custom field types?

LukasG June 1, 2015

In the JIRA developer documentation for custom field types there is mentioned that in order to make a new custom field type searchable one can use the element valid searcher.

<customfield-type ...> ...
<valid-searcher package="com.atlassian.jira.issue.customfields.searchers" key="numberrange" />
</customfield-type>

Should this still work in JIRA 6.4 ?

 

 

 

3 answers

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

4 votes
Answer accepted
LukasG June 1, 2015

I got it working! The solution is to specify the correct package. I used the java package. But one must use the package key which is defined in the system-customfieldtypes-plugin.xml (in the jira-project itself).

Example:

<customfield-type key="euro-field" name="Euro" class="de.codecentric.jira.customfields.EuroCFType">
<description> A custom field type for an Euro Value.
</description>
<resource type="velocity" name="view" location="templates/cf_euro/view.vm" />
<resource type="velocity" name="edit" location="templates/cf_euro/edit.vm" />
<valid-searcher package="com.atlassian.jira.plugin.system.customfieldtypes" key="numberrange" />
</customfield-type>

 

1 vote
Jobin Kuruvilla [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 1, 2015

Yes, it does. You need to pick the searcher when you create the custom field.

0 votes
LukasG June 1, 2015

When I add/edit the field there is an error message "There are no search templates for this custom field type

Can you post an example?

I cant get this to work - and I just found a similar question. If possible I would like to avoid a dummy searcher.. see: https://answers.atlassian.com/questions/69644

TAGS
AUG Leaders

Atlassian Community Events