package EnsEMBL::Web::Component::Website::CurrentSpecies;
### Lists species recorded in the ensembl_website database,
### as opposed to those configured in SiteDefs
use strict;
use warnings;
no warnings "uninitialized";
use base qw(EnsEMBL::Web::Component);
use EnsEMBL::Web::Data::Release;
sub _init {
my $self = shift;
$self->cacheable( 0 );
$self->ajaxable( 0 );
}
sub caption {
my $self = shift;
return '';
}
sub content {
my $self = shift;
my $object = $self->object;
my $html;
my $links = qq(Add a new species | Update database with current species
);
my $release_id = $object->species_defs->ENSEMBL_VERSION;
my $release = EnsEMBL::Web::Data::Release->new($release_id);
my @config_species = $object->species_defs->valid_species;
my %species_lookup;
foreach my $species (@config_species) {
$species_lookup{$species} = 'yes';
}
if ($release) {
$html = qq(Species currently in ensembl_website for Release $release_id
N.B. You will normally only need to update the list of current species if it is empty
(e.g. at the beginning of the release cycle).
);
my @species = $release->species;
if (@species) {
$html .= $links;
$html .= "