[EP-tech] Quick export plugin question
Thomas Lauke
th.lauke at arcor.de
Thu Sep 22 09:31:48 BST 2016
Good morning Robin,
> $data->{B} = $dataobj->get_value( "divisions" ) if $dataobj->exists_and_set( "divisions" );
following ~/Eprints/perl_lib/EPrints/DataObj/Subject.pm what about
if( $dataobj->exists_and_set( "subjects" ) )
{
my $subjectid;
foreach $subjectid ( @{$dataobj->get_value( "subjects" )} )
{
my $subject = EPrints::DataObj::Subject->new( $plugin->{session}, $subjectid );
# avoid problems with bad subjects
next unless( defined $subject );
my $path = $subject->render_with_path( $plugin->{session}, $subject->top ) ;
my $name = $subject->render_description( ) ;
print STDERR 'ID, path, name', $subject, $path, $name, "\n";
}
}
?
Hth
Thomas
More information about the Eprints-tech
mailing list