4 use CXGN
::Chado
::Cvterm
;
6 # Displays a static cvterm detail page.
8 use CatalystX
::GlobalContext
qw( $c );
12 my $dbh = CXGN::DB::Connection->new();
14 my $cvterm_id = $q->param("cvterm_id") + 0;
15 my $cvterm_accession = $q->param("cvterm_name");
18 if ( $cvterm_accession ) {
19 $cvterm = CXGN::Chado::Cvterm->new_with_accession( $dbh, $cvterm_accession);
20 $cvterm_id = $cvterm->get_cvterm_id();
21 } elsif ( $cvterm_id ) {
22 $cvterm = CXGN::Chado::Cvterm->new( $dbh, $cvterm_id );
25 unless ( $cvterm_id && $cvterm_id =~ m /^\d+$/ ) {
26 $c->throw( is_client_error => 1, public_message => 'Invalid arguments' );
31 $c->forward_to_mason_view(