[Bio] / FigWebServices / assignments.cgi Repository:
ViewVC logotype

Diff of /FigWebServices/assignments.cgi

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

revision 1.9, Tue May 25 17:27:49 2004 UTC revision 1.12, Mon Oct 18 21:30:35 2004 UTC
# Line 103  Line 103 
103  sub edit_link {  sub edit_link {
104      my($cgi,$set) = @_;      my($cgi,$set) = @_;
105    
106      return "<a href=" . $cgi->self_url() . "&request=edit_set&set=$set&all=0>edit</a>" . "/" .      # modified by RAE so that this can be called from within assignments.cgi and the options can be changed.
107             "<a href=" . $cgi->self_url() . "&request=edit_set&set=$set&all=1>examine</a>";      return "<a href=" . $cgi->url() . "?user=".$cgi->param('user') . "&request=edit_set&set=$set&all=0>edit</a>" . "/" .
108               "<a href=" . $cgi->url() . "?user=".$cgi->param('user') . "&request=edit_set&set=$set&all=1>examine</a>";
109  }  }
110    
111  sub delete_link {  sub delete_link {
112      my($cgi,$set) = @_;      my($cgi,$set) = @_;
113    
114      return "<a href=" . $cgi->self_url() . "&request=delete_set&set=$set>delete</a>";      # modified by RAE so that this can be called from within assignments.cgi and the options can be changed.
115        return "<a href=" . $cgi->url() . "?user=".$cgi->param('user')."&request=delete_set&set=$set>delete</a>";
116        #return "<a href=" . $cgi->self_url() . "&request=delete_set&set=$set>delete</a>";
117  }  }
118    
119  sub accept_link {  sub accept_link {
120      my($cgi,$set) = @_;      my($cgi,$set) = @_;
121    
122      return "<a href=" . $cgi->self_url() . "&request=accept_set&set=$set>accept</a>";      # modified by RAE so that this can be called from within assignments.cgi and the options can be changed.
123        return "<a href=" . $cgi->url() . "?user=".$cgi->param('user')."&request=accept_set&set=$set>accept</a>";
124  }  }
125    
126  sub assignment_sets {  sub assignment_sets {
# Line 191  Line 195 
195                           $cgi->hidden(-name => 'set', -value => $set)                           $cgi->hidden(-name => 'set', -value => $set)
196                   );                   );
197    
198              $col_hdrs = ["delete","PEG","Functions"];              $col_hdrs = ["delete","PEG","Proposed Function", "Current function"];
199              $tab      = [];              $tab      = [];
200              my @keep = ();              my @keep = ();
201              while (defined($line = <SET>))              while (defined($line = <SET>))
# Line 206  Line 210 
210                      push(@$tab,[                      push(@$tab,[
211                                  $cgi->checkbox(-name => 'checked', -value => $peg, -checked => 0,-override => 1),                                  $cgi->checkbox(-name => 'checked', -value => $peg, -checked => 0,-override => 1),
212                                  &HTML::fid_link($cgi,$peg),                                  &HTML::fid_link($cgi,$peg),
213                                  "\@nowrap:$func1<br>$func2"                                  $func1, $func2
214    #                               "\@nowrap:$func1<br>$func2"
215                                 ]                                 ]
216                           );                           );
217                  }                  }
# Line 227  Line 232 
232              {              {
233                  push(@$html,&HTML::make_table($col_hdrs,$tab,""));                  push(@$html,&HTML::make_table($col_hdrs,$tab,""));
234                  push(@$html,$cgi->submit("delete checked entries"));                  push(@$html,$cgi->submit("delete checked entries"));
235                    # modified by RAE to include these links at the bottom of the page so that you can accept after reviewing
236                    push(@$html,"<p><b>", &accept_link($cgi, $set), "/", &edit_link($cgi, $set), " these annotations</b></p>");
237              }              }
238              else              else
239              {              {
# Line 254  Line 261 
261      if (-e "$FIG_Config::data/Assignments/$userR/$set")      if (-e "$FIG_Config::data/Assignments/$userR/$set")
262      {      {
263          unlink("$FIG_Config::data/Assignments/$userR/$set");          unlink("$FIG_Config::data/Assignments/$userR/$set");
264          push(@$html,$cgi->h1("Deleted set $set"));          push(@$html,$cgi->h2("Deleted set $set"));
265            push(@$html,$cgi->h2("<a href=" . $cgi->url() . "?user=".$cgi->param('user').">Return to Assignment Sets</a>"));
266      }      }
267      else      else
268      {      {
# Line 280  Line 288 
288    
289          if (system("$FIG_Config::bin/fig assign_functionF $who $FIG_Config::data/Assignments/$userR/$set > /dev/null") == 0)          if (system("$FIG_Config::bin/fig assign_functionF $who $FIG_Config::data/Assignments/$userR/$set > /dev/null") == 0)
290          {          {
291              push(@$html,$cgi->h1("Made Assignments from $set"));              push(@$html,$cgi->h2("Made Assignments from $set"));
292                my $dellink=&delete_link($cgi,$set);
293                $dellink =~ s/>delete</>Delete</;
294                push(@$html,$cgi->h2("$dellink this Assignment Set from the pending assignments"));
295          }          }
296          else          else
297          {          {

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

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3