<?cs include:"util.cs" ?>
 
<?cs ############################################
     # macro that prints error page 
?>
<?cs def:print_one_type_error(title, description, errorname) ?>
  <fieldset>
  <legend class="fieldset_legend"><?cs var:title ?></legend>
   <div><?cs var:description ?></div>
    <ul>
    <?cs each:this = errorname ?>
     <li><?cs var:this.id ?></li>
    <?cs /each ?>
    </ul>
   </fieldset>
<?cs /def ?>




<?cs def:error_page() ?>
<?cs with:lang = lang.grade_upload_error ?>
  <div class="center_msg"><?cs var:lang.page_title ?></div>
  <p class="instructions"><?cs var:lang.skipped_students_description ?></p>
  <div class="center_msg">
    <a href="javascript:openwindow('admin_list_passwd?crs=<?cs var:Query.crs ?>&amp;id=<?cs var:Query.id ?>&amp;open=1','password')" title="<?cs var:lang.view_password_file_link ?>"><?cs var:lang.view_password_file_link ?></a>
  </div>
        
  <?cs if:dup.0.id ?><?cs call:print_one_type_error(lang.duplicate_id_title, lang.duplicate_id_description, dup) ?><?cs /if ?>
  <?cs if:extra.0.id ?><?cs call:print_one_type_error(lang.extra_id_title, lang.extra_id_description, extra) ?><?cs /if ?>
  <?cs if:miss.0.id ?><?cs call:print_one_type_error(lang.missing_id_title, lang.missing_id_description, miss) ?><?cs /if ?>
<?cs /with ?>
<?cs /def ?>





<?cs ###########################
     # HTML starts here
     ###########################
?>

<?cs call:html_heading() ?>
<head>
<title><?cs var:course_no ?> <?cs var:lang.grade_upload_error.page_title ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="StyleSheet" href="<?cs var:image_path ?>common.css" type="text/css"  />
<script type="text/javascript">
function openwindow(some_url,winname)
{
 var new_window = window.open(some_url, winname,'menubar=0,toolbar=0,status=0,scrollbars=yes,resizable=yes,width=650,height=600');
 new_window.focus();
}
</script>


</head>

<?cs call:define_body() ?>
<?cs call:print_course_heading(back_url, lang.admin_main_menu.back_button_title) ?>
<?cs call:error_page() ?>
</body>
</html>
