[svn r11894] Improve breadcrumbs in the admin interface

skala
Julian Prud'homme 19 years ago
parent ee3519107f
commit 92310931e2
  1. 28
      main/mySpace/myStudents.php
  2. 10
      main/mySpace/student.php

@ -44,16 +44,27 @@ $csv_content = array();
else else
{ {
$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace')); $interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
if(isset($_GET['id_coach']) && intval($_GET['id_coach'])!=0){
$interbreadcrumb[] = array ("url" => "student.php?id_coach=".$_GET['id_coach'], "name" => get_lang("CoachStudents"));
$interbreadcrumb[] = array ("url" => "myStudents.php?student=".$_GET['student'].'&id_coach='.$_GET['id_coach'], "name" => get_lang("StudentDetails"));
}
else{
$interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang("MyStudents")); $interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang("MyStudents"));
$interbreadcrumb[] = array ("url" => "myStudents.php?student=".$_GET['student'], "name" => get_lang("StudentDetails")); $interbreadcrumb[] = array ("url" => "myStudents.php?student=".$_GET['student'], "name" => get_lang("StudentDetails"));
}
$nameTools=get_lang("DetailsStudentInCourse"); $nameTools=get_lang("DetailsStudentInCourse");
} }
} }
else else
{ {
$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace')); $interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
if(isset($_GET['id_coach']) && intval($_GET['id_coach'])!=0){
$interbreadcrumb[] = array ("url" => "student.php?id_coach=".$_GET['id_coach'], "name" => get_lang("CoachStudents"));
}
else{
$interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang("MyStudents")); $interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang("MyStudents"));
} }
}
api_block_anonymous_users(); api_block_anonymous_users();
Display :: display_header($nameTools); Display :: display_header($nameTools);
@ -770,12 +781,19 @@ if(!empty($_GET['student']))
</td> </td>
<td align="right"> <td align="right">
'.$score.' '.$score.'
</td> </td>';
<td align="center" width="10"> if(isset($_GET['id_coach']) && intval($_GET['id_coach'])!=0){
echo '<td align="center" width="10">
<a href="'.$_SERVER['PHP_SELF'].'?student='.$a_infosUser['user_id'].'&details=true&course='.$course_infos['code'].'&id_coach='.$_GET['id_coach'].'#infosStudent"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a>
</td>';
}
else{
echo '<td align="center" width="10">
<a href="'.$_SERVER['PHP_SELF'].'?student='.$a_infosUser['user_id'].'&details=true&course='.$course_infos['code'].'#infosStudent"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a> <a href="'.$_SERVER['PHP_SELF'].'?student='.$a_infosUser['user_id'].'&details=true&course='.$course_infos['code'].'#infosStudent"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a>
</td> </td>';
</tr> }
'; echo '</tr>';
} }
} }
else else

@ -20,7 +20,12 @@ if($export_csv)
} }
$csv_content = array(); $csv_content = array();
if(isset($_GET['id_coach']) && intval($_GET['id_coach'])!=0){
$nameTools= get_lang("CoachStudents");
}
else{
$nameTools= get_lang("Students"); $nameTools= get_lang("Students");
}
$this_section = "session_my_space"; $this_section = "session_my_space";
@ -166,7 +171,12 @@ if($isCoach || api_is_platform_admin())
$csv_content[] = $row; $csv_content[] = $row;
} }
if(isset($_GET['id_coach']) && intval($_GET['id_coach'])!=0){
$row[] = '<a href="myStudents.php?student='.$student_id.'&id_coach='.$coach_id.'"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a>';
}
else{
$row[] = '<a href="myStudents.php?student='.$student_id.'"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a>'; $row[] = '<a href="myStudents.php?student='.$student_id.'"><img src="'.api_get_path(WEB_IMG_PATH).'2rightarrow.gif" border="0" /></a>';
}
$all_datas[] = $row; $all_datas[] = $row;

Loading…
Cancel
Save