I'm creating a custom plugin for Jira. I now have start date and end date fields. How can I add a field to select the user for which the report will be generated?
<atlassian-plugin key="${atlassian.plugin.key}" name="${project.name}" plugins-version="2">
<plugin-info>
...
</plugin-info>
<report name="Creation Report" ...>
<description ...>
<resource ...>
<property>
<key>startDate</key>
<name>report.issuecreation.startdate</name>
<description>report.issuecreation.startdate.description</description>
<type>date</type>
</property>
<property>
<key>endDate</key>
<name>report.issuecreation.enddate</name>
<description>report.issuecreation.enddate.description</description>
<type>date</type>
</property>
<property>
<key>users</key>
<name>report.issuecreation.users</name>
<description>report.issuecreation.users.description</description>
<type>select</type> # i don't know
???
</property>
</report>
</atlassian-plugin>
Read this documentation: https://developer.atlassian.com/server/jira/platform/object-configurable-parameters/
Then you can see some examples like this:
The type
select
is correct, but I believe you will need something called UserValuesGenerator, these generators basically extend com.atlassian.com.configurable.ValuesGeneratorSo you can write your own UserValuesGenerator and use it.