[Bio] / SeedViewer / seedviewer.cgi Repository:
ViewVC logotype

Diff of /SeedViewer/seedviewer.cgi

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

revision 1.6, Thu Nov 29 16:31:17 2007 UTC revision 1.7, Thu Dec 6 21:17:47 2007 UTC
# Line 1  Line 1 
1  use strict;  use strict;
2  use warnings;  use warnings;
3    no warnings 'once';
4    
5  use DBMaster;  use DBMaster;
6  use WebApplication;  use WebApplication;
# Line 33  Line 34 
34      my $cgi = new CGI();      my $cgi = new CGI();
35      ETracing($cgi);      ETracing($cgi);
36    
     # initialize db-master  
     #my $dbmaster = DBMaster->new(-database => 'WebAppBackend');  
   
37      # initialize layout      # initialize layout
38      # Use the template file for the current mode-- NMPDR or SEED      # Use the template file for the current mode-- NMPDR or SEED
39      my $templateFile = (FIGRules::nmpdr_mode($cgi) ? './Html/NmpdrViewer.tmpl'      my $templateFile = (FIGRules::nmpdr_mode($cgi) ? './Html/NmpdrViewer.tmpl' : './Html/SeedViewer.tmpl');
                                                    : './Html/SeedViewer.tmpl');  
40      Trace("Template file is $templateFile") if T(3);      Trace("Template file is $templateFile") if T(3);
41      my $layout = WebLayout->new($templateFile);      my $layout = WebLayout->new($templateFile);
42      # Start with the normal style.      # Start with the normal style.
# Line 65  Line 62 
62      $menu->add_entry('»Navigate', 'Startpage', '?page=Home');      $menu->add_entry('»Navigate', 'Startpage', '?page=Home');
63      $menu->add_entry('»Navigate', 'Organisms', '?page=OrganismSelect');      $menu->add_entry('»Navigate', 'Organisms', '?page=OrganismSelect');
64      $menu->add_entry('»Navigate', 'Subsystems', '?page=SubsystemSelect');      $menu->add_entry('»Navigate', 'Subsystems', '?page=SubsystemSelect');
65      $menu->add_entry('»Navigate', 'Blast', '?page=BlastRun');      $menu->add_entry('»Navigate', 'Search by', '?page=Home');
66      $menu->add_entry('&raquo;Navigate', "<form style='margin: 0px 0px 0px 6px;'>ID&nbsp;&nbsp;<input type='text' name='pattern' style='border: 1px solid #5da668; width: 120px; height: 17px; margin-top: 2px; font-size: 11px;'><input type='hidden' name='page' value='SearchResult'><input type='hidden' name='action' value='check_search'><input type='submit' style='display:none;'></form>");      $menu->add_entry('&raquo;Navigate', '&nbsp;&nbsp;- BLAST', '?page=BlastRun');
67        $menu->add_entry('&raquo;Navigate', "<form style='margin: 0px 0px 0px 6px;'>&nbsp;&nbsp;- ID&nbsp;&nbsp;<input type='text' name='pattern' style='border: 1px solid #5da668; width: 100px; height: 17px; margin-top: 2px; font-size: 11px;'><input type='hidden' name='page' value='SearchResult'><input type='hidden' name='action' value='check_search'><input type='submit' style='display:none;'></form>");
68    
69      if (defined($FIG_Config::teacher_db)) {      if (defined($FIG_Config::teacher_db)) {
70          $menu->add_category('&raquo;Teacher', '?page=Teach', undef, ['edit', 'problem_list'], 96);          $menu->add_category('&raquo;Teacher', '?page=Teach', undef, ['edit', 'problem_list'], 96);
71          $menu->add_entry('&raquo;Teacher', 'Class Performance', '?page=Teach');          $menu->add_entry('&raquo;Teacher', 'Class Performance', '?page=Teach');
72          $menu->add_entry('&raquo;Teacher', 'Class Management', '?page=ManageClass');          $menu->add_entry('&raquo;Teacher', 'Class Management', '?page=ManageClass');
73          $menu->add_entry('&raquo;Teacher', 'Problem Sets', '?page=ManageProblemSets');          $menu->add_entry('&raquo;Teacher', 'Problem Sets', '?page=ManageProblemSets');
74            $menu->add_entry('&raquo;Teacher', 'Annotation Resolve', '?page=ClassAnnotationResolve');
75      }      }
76      $menu->add_category('&raquo;Admin', '?page=Admin', undef, ['edit', 'scope', '*'], 99);      $menu->add_category('&raquo;Admin', '?page=Admin', undef, ['edit', 'scope', '*'], 99);
77      if (FIGRules::nmpdr_mode($cgi)) {      if (FIGRules::nmpdr_mode($cgi)) {
# Line 90  Line 89 
89      }      }
90      # initialize application      # initialize application
91      my $WebApp = WebApplication->new( { id => 'SeedViewer',      my $WebApp = WebApplication->new( { id => 'SeedViewer',
                                         #dbmaster => $dbmaster,  
92                                          menu     => $menu,                                          menu     => $menu,
93                                          layout   => $layout,                                          layout   => $layout,
94                                          default  => 'Home',                                          default  => 'Home',
95                                        } );                                        } );
96        $WebApp->page_title_prefix('SEED Viewer - ');
97      $WebApp->show_login_user_info(1);      $WebApp->show_login_user_info(1);
98    
99      # run application      # run application

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3