[EP-tech] help on plugin

Yuri yurj at alfa.it
Wed Nov 7 16:12:53 GMT 2012


Hi!

  Is there a way in new() on a plugin to get the current repository?

I'm tryng with:

sub new
{
         my( $class, %params ) = @_;

         my $self = $class->SUPER::new(%params);

         #       $self->{priv} = # no specific priv - one per action

         #my $session = EPrints::Session->new();
         #my $repo_name = $session->get_repository->get_id;
         my $repo_name = 
$self->{processor}->{eprint}->{session}->get_repository->get_id;

also $self->{session}->get_repository->get_id;

does not work... even an hack is ok for me. Thanks!


More information about the Eprints-tech mailing list