[EP-tech] Re: Export plugin with views.pm features
Sebastien Francois
sf2 at ecs.soton.ac.uk
Wed Jul 30 17:38:45 BST 2014
Your example can be done via a search:
http://demoprints.eprints.org/cgi/search/archive/advanced?screen=Search&dataset=archive&type=article&refereed=TRUE&satisfyall=ALL&order=-date%2Fcreators_name%2Ftitle&_action_search=Search
Searches can be exported (like any list of objects).
Otherwise you can write your own CGI (if your conditions are more
complex) - something like (adapt to your needs):
my $list = $repo->dataset( 'archive' )->search(
filters => [
{ meta_fields => [qw/ type /], value => 'article', match =>
'EX', },
{ meta_fields => [qw/ refereed /], value => 'TRUE', match =>
'EX', },
] );
binmode( STDOUT, ":utf8" );
$list->export( 'XML', fh => *STDOUT );
Seb.
On 30/07/14 17:01, Gaston.Fournier at etsmtl.ca wrote:
>
> Here is an example of the Boolean expressions used in a cgi script to
> generate a subset of eprints for the output :
>
> if ( $eprint->get_value( "type" ) eq "article" && $eprint->get_value(
> "refereed" ) eq "TRUE" )
>
> GF
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ecs.soton.ac.uk/pipermail/eprints-tech/attachments/20140730/9e1ef905/attachment-0001.html
More information about the Eprints-tech
mailing list