Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Prints for division function
=method prints_for_division
Returns an EPrints results set for all prints in a given division.
=cut
sub prints_for_division {
my ($session, $division) = shift;
my $dataset = $session->get_repository->get_dataset("eprint");
my $search = EPrints::Search->new(
session => $session,
dataset => $dataset,
satisfy_all => 1);
$search->add_field(
$dataset->get_field("divisions"),
$division);
return $search->perform_search;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment