Hi Everyone,,
I created a Jira Custom Field 'Project Properties Viewer" and its searcher ProjectPropertiesViewerSearcher as described by the following code:
<atlassian-plugin key="${atlassian.plugin.key}" name="${project.name}" plugins-version="2">
<plugin-info>
<description>${project.description}</description>
<version>${project.version}</version>
<vendor name="${project.organization.name}" url="${project.organization.url}" />
<param name="plugin-icon">images/jira-favicon-scaled.png</param>
<param name="plugin-logo">images/EngineeringALM-icon_medium.png</param>
</plugin-info>
<!-- add our i18n resource -->
<resource type="i18n" name="i18n" location="project-properties-viewer"/>
<!-- add our web resources -->
<web-resource key="project-properties-viewer-resources" name="project-properties-viewer Web Resources">
<dependency>com.atlassian.auiplugin:ajs</dependency>
<resource type="download" name="project-properties-viewer.css" location="/css/project-properties-viewer.css"/>
<resource type="download" name="project-properties-viewer.js" location="/js/project-properties-viewer.js"/>
<resource type="download" name="images/" location="/images"/>
<context>project-properties-viewer</context>
</web-resource>
<customfield-type key="ProjectPropertiesViewer" name="ESL ALM: Project Properties Viewer" class="it.eng.esl.jira.plugins.customfield.ProjectPropertiesViewerCustomField"
i18n-name-key="projectPropertiesViewer.name">
<description key="projectPropertiesViewer.description">Customfield to view the project properties in the issues</description>
<resource type="i18n" name="i18n" location="i18n.projectPropertiesViewer" />
<resource type="velocity" name="view" location="templates/plugins/fields/view/view-basictext.vm" />
<resource type="velocity" name="edit" location="templates/plugins/fields/edit/edit-basictext.vm"/>
<resource type="velocity" name="xml" location="templates/plugins/fields/xml/xml-basictext.vm"/>
</customfield-type>
<!-- Free Text Searcher -->
<customfield-searcher key="ppv-text-searcher" name="PPV Text Searcher" class="it.eng.esl.jira.plugins.customfield.ProjectPropertiesViewerSearcher">
<description key="admin.customfield.searcher.textsearcher.desc">Search for Project Properties Text Field using a free text search.</description>
<resource type="velocity" name="search" location="templates/plugins/fields/edit-searcher/search-basictext.vm"/>
<resource type="velocity" name="view" location="templates/plugins/fields/view-searcher/view-searcher-basictext.vm"/>
<valid-customfield-type package="${atlassian.plugin.key}" key="ProjectPropertiesViewer"/>
</customfield-searcher>
</atlassian-plugin>
public class ProjectPropertiesViewerSearcher extends TextSearcher {
public ProjectPropertiesViewerSearcher(FieldVisibilityManager fieldVisibilityManager,
JqlOperandResolver jqlOperandResolver,
CustomFieldInputHelper customFieldInputHelper) {
super (fieldVisibilityManager,jqlOperandResolver,customFieldInputHelper );
}
}
Then I added a Custom Field of type 'Project Properties Viewer' to Jira (let's name it Goofy for explanation purpose).
However when I use the Jira issues search bar and I type 'Goofy' I don't see my custom field among those suggested by the system, like it didn't exist.
What am I doing wrong? May this depend on the specific implementation for ProjectPropertiesViewerCustomField?
Hello @gfinesch , I'm having exact same issue. Specified my custom field and searcher similarly. I even tried a default searcher class of
com.atlassian.jira.issue.customfields.searchers.TextSearcher
that didn't work either.
My field works well, just can't get a searcher to work for it.
Hello,
While you were adding the custom field did you see your searcher in drop down list?
I mean, after you add custom field, it asks you available searchers. If you do not see your searcher there, there should be something wrong with the plugin code, and it is wise to check the log file.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.