EPrints Technical Mailing List Archive
See the EPrints wiki for instructions on how to join this mailing list and related information.
Message: #07732
< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First
Re: [EP-tech] Abstract Metadata Rendering/EPC
- To: <eprints-tech@ecs.soton.ac.uk>
- Subject: Re: [EP-tech] Abstract Metadata Rendering/EPC
- From: James Kerwin <jkerwin2101@gmail.com>
- Date: Thu, 14 Mar 2019 10:53:34 +0000
Morning All,
In case anybody else faces the same challenge, I managed to do this eventually. I'm not certain it's the best way, but it does work well so far.
My task was to change the creators field in the EPrint metadata from:
To (or something similar):
I had a few false starts looking at altering (in my cfg.d!) EPrints::Repository::render_name and in EPrints::MetaField::Name::render_single_value as well as Compile.pm. I took some inspiration from z_orcid_support.pl. I copied and altered this (z_render_citation_name.pl) and then in summary_page.xml (recollect_summary_page.xml in this case) called my new function:
Where I previously had:
<epc:print expr="$item.property($fieldname)" />
I now have:
<epc:if test="$fieldname != 'creators_name'">
<epc:print expr="$item.property($fieldname)" />
</epc:if>
<epc:if test="$fieldname = 'creators_name'">
<print expr="citation_namesmeta(creators, eprintid)" />
</epc:if>
In my new function I can pretty much alter the display to be anything I like, which is helpful! I can't say if this is the ideal approach, but it suits my needs.
Thanks,
James
On Tue, Mar 12, 2019 at 9:51 AM James Kerwin via Eprints-tech <eprints-tech@ecs.soton.ac.uk> wrote:
*** Options: http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-techHi All,I'm back on the "Hedonic Treadmill" of EPrints and need some advice.I can't work out how the metadata in an EPrint abstract is rendered, which I need to know in order to change how names of authors/creators are shown. At the moment they are listed side by side, separated by commas. There are too many commas and it's difficult to read.Could anybody point me in the right direction? I'm with it as far as:<epc:print expr="$item.property($fieldname)" />in my "summary_page.xml" file. The "name" field in question is a compound field called "creators" ("name" and "id") and in the summary_page_metadata config I've passed the name as "creators_name" so as to not display the related "id" on the abstract pages.I spent hours trying to work this out yesterday and didn't get far.Thanks,James
*** Archive: http://www.eprints.org/tech.php/
*** EPrints community wiki: http://wiki.eprints.org/
*** EPrints developers Forum: http://forum.eprints.org/
- Follow-Ups:
- Re: [EP-tech] Abstract Metadata Rendering/EPC
- From: James Kerwin <jkerwin2101@gmail.com>
- Re: [EP-tech] Abstract Metadata Rendering/EPC
- References:
- [EP-tech] Abstract Metadata Rendering/EPC
- From: James Kerwin <jkerwin2101@gmail.com>
- Re: [EP-tech] Abstract Metadata Rendering/EPC
- From: James Kerwin <jkerwin2101@gmail.com>
- [EP-tech] Abstract Metadata Rendering/EPC
- Prev by Date: Re: [EP-tech] Fwd: how to configure smtp for eprints ?
- Next by Date: [EP-tech] EPrints Data Repository - Elements RT2
- Previous by thread: [EP-tech] EPrints/CRIS
- Next by thread: [EP-tech] DOI handling in orcid_support_advance
- Index(es):