diff --git a/views/previoussubmissionslist.php b/views/previoussubmissionslist.php index c08d9d85b6695dff81f94d4ec6eb3df9773e9f17..46296648553239430cc11f55834f5cd6222a2ce3 100644 --- a/views/previoussubmissionslist.php +++ b/views/previoussubmissionslist.php @@ -58,11 +58,13 @@ if ($detailed) { $vpl->print_header( get_string( 'previoussubmissionslist', VPL ) ); $vpl->print_view_tabs( basename( __FILE__ ) ); -$grapher = new vpl_grapher($vpl, $userid); -$grapher->draw_files_evolution_graph(); -$grapher->draw_working_periods_graph(); -$grapher->draw_files_evolution_graph(true); -$grapher->draw_daily_activity_graph(); +if ($vpl->has_capability(VPL_GRADE_CAPABILITY)) { + $grapher = new vpl_grapher($vpl, $userid); + $grapher->draw_files_evolution_graph(); + $grapher->draw_working_periods_graph(); + $grapher->draw_files_evolution_graph(true); + $grapher->draw_daily_activity_graph(); +} $table = new html_table(); $table->head = array (