--- loncom/homework/grades.pm 2005/04/03 21:41:58 1.255 +++ loncom/homework/grades.pm 2005/04/04 23:56:44 1.256 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # The LON-CAPA Grading handler # -# $Id: grades.pm,v 1.255 2005/04/03 21:41:58 banghart Exp $ +# $Id: grades.pm,v 1.256 2005/04/04 23:56:44 banghart Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2211,6 +2211,12 @@ sub version_portfiles { } } $version++; + my $home_server = &Apache::lonnet::homeserver($stuname,$domain,undef); + $ENV{'form.copy'} = &Apache::lonnet::getfile("/uploaded/$domain/$stuname/$directory$answer_file"); + # $ENV{'form.copy.filename'}=''; + my $copy_result = &Apache::lonnet::finishuserfileupload($stuname,$domain,$home_server,'copy', + '/portfolio'.$directory.$answer_file_parts[0].'.'.$version.'.'.$answer_file_parts[-1]); + &Apache::lonnet::logthis('copy result is '.$copy_result); &Apache::lonnet::logthis('answer file is '.$answer_file. ' becomes '.$answer_file_parts[0].'.'.$version.'.'.$answer_file_parts[-1]); &Apache::lonnet::logthis('from dir list is '.$file_names[0].' has '.@file_name_parts.' parts');