Closed aso2101 closed 7 years ago
This adds a parameter to the app:abc-filter() function, so you can pass in the element you want to sort on.
Use case:
for $i in util:eval(concat("$persons",app:abc-filter('tei:person[1]/tei:persName[1]'),facet:facet-filter($facet-def)))
let $name := $i//tei:person[1]/tei:persName[1]
order by $name
return $i
@aso2101 if this works as desired you can close it. We will also use this for the bibliographic browse.
yes, this fixes it.
Since my practice is to prefix an abbreviated place name to the xml:ids for people, I think it's better for
app:browse-get-persons
to order the hits by the "real" name (the firstpersName
in the record), rather than by the xml:id (so the person with the xml:id Hi-Rakṣita is sorted under R rather than H). However, when I try setting$name
to$i//tei:persName[1]/text()
, we end up with multiple entries having the same value for$name
, which doesn't work. Maybe you have an easy solution @wsalesky?