Skip to content

Commit

Permalink
Added reports/library/taxa/taxon_names_2.xml
Browse files Browse the repository at this point in the history
(New version of taxon_names.xml)
  • Loading branch information
burkmarr committed Aug 11, 2022
1 parent c64eb5e commit 42d5f18
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions reports/library/taxa/taxon_names_2.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<report
title="Species Data"
description="Report used to retrieve details of a species excluding custom attributes for the species details form. Includes default common name and external key."
>
<query>
select distinct tall.id, tall.taxon_meaning_id, tall.external_key, tall.default_common_name,
case tall.language_iso when 'lat' then '&lt;em&gt;' || tall.taxon || '&lt;/em&gt;' || coalesce(' ' || tall.authority, '') else tall.taxon end,
tall.language_iso,
tall.language_iso='lat' as latin,
tall.preferred
from cache_taxa_taxon_lists t
join cache_taxa_taxon_lists tall on tall.taxon_meaning_id=t.taxon_meaning_id
where 1=1

</query>
<order_bys>
<order_by>tall.preferred desc, tall.language_iso='lat' desc, tall.language_iso desc, tall.id asc</order_by>
</order_bys>
<params>
<param name='taxa_taxon_list_id' display='Taxa Taxon List ID' default='' description='Taxa_taxon_list_id of the taxon to load' datatype='text'>
<where>t.id=#taxa_taxon_list_id#</where>
</param>
<param name='taxon_meaning_id' display='Taxon Meaning ID' default='' description='Taxon meaning ID of the taxon to load. Provide this OR the taxa taxon list ID OR the external key.' datatype='text'>
<where>t.taxon_meaning_id=#taxon_meaning_id#</where>
</param>
<param name='external_key' display='External key' default='' description='Taxon meaning ID of the taxon to load. Provide this (tvk) OR the taxa taxon list ID OR the taxon meaning ID.' datatype='text'>
<where>t.external_key='#external_key#'</where>
</param>
</params>
</report>

0 comments on commit 42d5f18

Please sign in to comment.