[Bio] / SubsystemEditor / WebPage / MetaSpreadsheet.pm Repository:
ViewVC logotype

Diff of /SubsystemEditor/WebPage/MetaSpreadsheet.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.9, Tue Sep 16 15:08:24 2008 UTC revision 1.10, Fri Sep 26 12:32:56 2008 UTC
# Line 560  Line 560 
560    if ( defined( $self->{ 'cgi' }->param( 'buttonpressed' ) ) && $self->{ 'cgi' }->param( 'buttonpressed' ) eq 'MoVariants' || $self->{ 'cgi' }->param( 'showMoVariants' ) ) {    if ( defined( $self->{ 'cgi' }->param( 'buttonpressed' ) ) && $self->{ 'cgi' }->param( 'buttonpressed' ) eq 'MoVariants' || $self->{ 'cgi' }->param( 'showMoVariants' ) ) {
561      $show_mo_variants = 1;      $show_mo_variants = 1;
562    }    }
563    if ( defined( $self->{ 'cgi' }->param( 'buttonpressed' ) ) && $self->{ 'cgi' }->param( 'buttonpressed' ) eq 'HideMoVariants' ) {    if ( defined( $self->{ 'cgi' }->param( 'buttonpressed' ) ) && $self->{ 'cgi' }->param( 'buttonpressed' ) eq 'HideOneMOVariants' ) {
564        $show_mo_variants = -1;
565      }
566      if ( defined( $self->{ 'cgi' }->param( 'buttonpressed' ) ) && $self->{ 'cgi' }->param( 'buttonpressed' ) eq 'HideAllMOVariants' ) {
567      $show_mo_variants = 0;      $show_mo_variants = 0;
568    }    }
569    
# Line 590  Line 593 
593      my $tax = $spreadsheet_hash->{ $g }->{ 'taxonomy' };      my $tax = $spreadsheet_hash->{ $g }->{ 'taxonomy' };
594      my $variant = $spreadsheet_hash->{ $g }->{ 'variant' };      my $variant = $spreadsheet_hash->{ $g }->{ 'variant' };
595    
596      unless ( $show_mo_variants ) {      if ( $show_mo_variants ne '1' ) {
597        next if ( $variant eq '-1' );        # need a new way to handle variants here.
598          my @var_subs = split( "\_", $variant );
599          my $countvars = 0;
600          foreach my $vs ( @var_subs ) {
601            if ( $vs eq '-1' ) {
602              $countvars++;
603            }
604      }      }
605          if ( $show_mo_variants == -1 && $countvars > 0 ) {
606            next;
607          }
608          if ( $show_mo_variants == 0 && $countvars == scalar( @var_subs ) ) {
609            next;
610          }
611        }
612    
613    
614    
615      # add link to Organism page here #      # add link to Organism page here #
616      $gname = "<A HREF='seedviewer.cgi?page=Organism&organism=" . $g."' target=_blank>$gname</A>";      $gname = "<A HREF='seedviewer.cgi?page=Organism&organism=" . $g."' target=_blank>$gname</A>";
# Line 1499  Line 1517 
1517    $delete_button .= "<INPUT TYPE=BUTTON VALUE='Delete selected genomes' NAME='DeleteGenomes' ID='DeleteGenomes' ONCLICK='if ( confirm( \"Do you really want to delete the selected genomes from the spreadsheet?\" ) ) {    $delete_button .= "<INPUT TYPE=BUTTON VALUE='Delete selected genomes' NAME='DeleteGenomes' ID='DeleteGenomes' ONCLICK='if ( confirm( \"Do you really want to delete the selected genomes from the spreadsheet?\" ) ) {
1518   document.getElementById( \"DeleteGenomesHidden\" ).value = 1;   document.getElementById( \"DeleteGenomesHidden\" ).value = 1;
1519  SubmitSpreadsheet( \"DeleteGenomes\", 0 ); }'>";  SubmitSpreadsheet( \"DeleteGenomes\", 0 ); }'>";
1520      my $minus1_variant_button = "<INPUT TYPE=BUTTON VALUE='Show all variants' NAME='MoVariants' ID='MoVariants' ONCLICK='SubmitSpreadsheet( \"MOVariants\", 0 );'>";
1521      my $minus1_variant_hideall_button = "<INPUT TYPE=BUTTON VALUE='Hide variants all subsystems -1' NAME='HideAllMOVariants' ID='HideAllMOVariants' ONCLICK='SubmitSpreadsheet( \"HideAllMOVariants\", 0 );'>";
1522      my $minus1_variant_hideone_button = "<INPUT TYPE=BUTTON VALUE='Hide variants one subsystem -1' NAME='HideOneMOVariants' ID='HideOneMOVariants' ONCLICK='SubmitSpreadsheet( \"HideOneMOVariants\", 0 );'>";
1523    
1524    my $spreadsheetbuttons = "<DIV id='controlpanel'><H2>Actions</H2>\n";    my $spreadsheetbuttons = "<DIV id='controlpanel'><H2>Actions</H2>\n";
1525    
1526      $spreadsheetbuttons .= "<TABLE><TR><TD><B>Variants:</B></TD><TD>$minus1_variant_button</TD><TD>$minus1_variant_hideone_button</TD><TD>$minus1_variant_hideall_button</TD></TR></TABLE><BR>";
1527    $spreadsheetbuttons .= "<TABLE><TR><TD><B>View:</B></TD><TD>$plusminus</TD></TR></TABLE><BR>";    $spreadsheetbuttons .= "<TABLE><TR><TD><B>View:</B></TD><TD>$plusminus</TD></TR></TABLE><BR>";
1528    $spreadsheetbuttons .= "<TABLE><TR><TD><B>Selection:</B></TD><TD>$delete_button</TD></TR></TABLE><BR>";    $spreadsheetbuttons .= "<TABLE><TR><TD><B>Selection:</B></TD><TD>$delete_button</TD></TR></TABLE><BR>";
1529    

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3