diff --git a/lang/cs/attforblock.php b/lang/cs/attforblock.php index 465345a..4e929ac 100644 --- a/lang/cs/attforblock.php +++ b/lang/cs/attforblock.php @@ -15,7 +15,7 @@ $string['add'] = 'Přidat'; $string['addmultiplesessions'] = 'Přidat více záznamů'; $string['addsession'] = 'Přidat záznam'; $string['allcourses'] = 'Všechny kurzy'; -$string['alltaken'] = 'Všechny proběhlé'; +$string['allpast'] = 'Všechny proběhlé'; $string['attendanceforthecourse'] = 'Docházka pro kurz'; $string['attendancegrade'] = 'Hodnocení docházky'; $string['attendancenotstarted'] = 'Docházka pro tento kurz dosud nebyla zahájena'; diff --git a/lang/en/attforblock.php b/lang/en/attforblock.php index f94e2bc..74e1319 100644 --- a/lang/en/attforblock.php +++ b/lang/en/attforblock.php @@ -16,7 +16,7 @@ $string['addmultiplesessions'] = 'Add multiple sessions'; $string['addsession'] = 'Add session'; $string['allcourses'] = 'All courses'; $string['all'] = 'All'; -$string['alltaken'] = 'All taken'; +$string['allpast'] = 'All past'; $string['attendanceforthecourse'] = 'Attendance for the course'; $string['attendancegrade'] = 'Attendance grade'; $string['attendancenotstarted'] = 'Attendance has not started yet for this course'; diff --git a/lang/es/attforblock.php b/lang/es/attforblock.php index 3953bd1..25ac659 100644 --- a/lang/es/attforblock.php +++ b/lang/es/attforblock.php @@ -16,7 +16,7 @@ $string['add'] = 'Añadir'; $string['addmultiplesessions'] = 'Añadir varias sesiones'; $string['addsession'] = 'Añadir sesión'; $string['allcourses'] = 'Todos los cursos'; -$string['alltaken'] = 'Hasta hoy'; +$string['allpast'] = 'Hasta hoy'; $string['attendanceforthecourse'] = 'Asistencia para el Curso/Asignatura'; $string['attendancegrade'] = 'Puntación Asistencia'; $string['attendancenotstarted'] = 'La Asistencia todavía no ha sido iniciada para este curso'; diff --git a/lang/eu/attforblock.php b/lang/eu/attforblock.php index d6f5826..664b010 100644 --- a/lang/eu/attforblock.php +++ b/lang/eu/attforblock.php @@ -17,7 +17,7 @@ $string['acronym'] = 'Laburdura'; $string['add'] = 'Gehitu'; $string['addmultiplesessions'] = 'Hainbat saio gehitu'; $string['addsession'] = 'Saioa gehitu'; -$string['alltaken'] = 'Erregistro guztiak'; +$string['allpast'] = 'Erregistro guztiak'; $string['attendanceforthecourse'] = 'Ikastaroko asistentzia'; $string['attendancegrade'] = 'Asistentzia-nota'; $string['attendancenotstarted'] = 'Asistentzia ez da abian jarri ikastaro honetan'; diff --git a/lang/fr/attforblock.php b/lang/fr/attforblock.php index 1316646..a94a114 100644 --- a/lang/fr/attforblock.php +++ b/lang/fr/attforblock.php @@ -23,7 +23,7 @@ $string['acronym'] = 'Acronyme'; $string['add'] = 'Ajouter'; $string['addmultiplesessions'] = 'Ajouter plusieurs sessions'; $string['addsession'] = 'Ajouter session'; -$string['alltaken'] = 'Sessions passées'; +$string['allpast'] = 'Sessions passées'; $string['attendanceforthecourse'] = 'Présence pour le cours'; $string['attendancegrade'] = 'Note de présence'; $string['attendancenotstarted'] = 'La prise de présence n\'a pas encore commencé pour ce cours'; diff --git a/lang/it/attforblock.php b/lang/it/attforblock.php index c4ed6d2..14a244b 100644 --- a/lang/it/attforblock.php +++ b/lang/it/attforblock.php @@ -17,7 +17,7 @@ $string['acronym'] = 'Acronimo'; $string['add'] = 'Aggiungi'; $string['addmultiplesessions'] = 'Aggiungi Sesioni Multiple'; $string['addsession'] = 'Aggiungi una Sessione'; -$string['alltaken'] = 'Tutte registrate'; +$string['allpast'] = 'Tutte registrate'; $string['attendanceforthecourse'] = 'Presenze al Corso'; $string['attendancegrade'] = 'Voto di Presenza'; $string['attendancenotstarted'] = 'La registrazione delle Presenze per questo corso non è ancora iniziata'; diff --git a/lang/ja/attforblock.php b/lang/ja/attforblock.php index fd6fe56..8ff48ca 100644 --- a/lang/ja/attforblock.php +++ b/lang/ja/attforblock.php @@ -15,7 +15,7 @@ $string['add'] = '追加'; $string['addmultiplesessions'] = '倍数セッションを追加する'; $string['addsession'] = 'セッションを追加する'; $string['allcourses'] = 'すべてのコース'; -$string['alltaken'] = 'すべて'; +$string['allpast'] = 'すべて'; $string['attendanceforthecourse'] = 'コースの出欠'; $string['attendancegrade'] = '出席点'; $string['attendancenotstarted'] = 'このコースの出欠は、まだ開始されていません。'; diff --git a/lang/ru/attforblock.php b/lang/ru/attforblock.php index 61f0c09..2c07f43 100644 --- a/lang/ru/attforblock.php +++ b/lang/ru/attforblock.php @@ -16,7 +16,7 @@ $string['addmultiplesessions'] = 'Добавить несколько занят $string['addsession'] = 'Добавить занятие'; $string['all'] = 'Все'; $string['allcourses'] = 'Все курсы'; -$string['alltaken'] = 'Все прошедшие'; +$string['allpast'] = 'Все прошедшие'; $string['attendanceforthecourse'] = 'Посещаемость для курса'; $string['attendancegrade'] = 'Оценка за посещаемость'; $string['attendancenotstarted'] = 'Пока нет отметок о посещаемости в данном курсе.'; diff --git a/lang/sk/attforblock.php b/lang/sk/attforblock.php index 743f9e8..835bfd5 100644 --- a/lang/sk/attforblock.php +++ b/lang/sk/attforblock.php @@ -17,7 +17,7 @@ $string['acronym'] = 'Akronym'; $string['add'] = 'Pridať'; $string['addmultiplesessions'] = 'Pridať viaceré termíny'; $string['addsession'] = 'Pridať termíny'; -$string['alltaken'] = 'Všetky termíny'; +$string['allpast'] = 'Všetky termíny'; $string['attendanceforthecourse'] = 'Účasť pre kurz'; $string['attendancegrade'] = 'Účasť Známky'; $string['attendancenotstarted'] = 'Účasť pre tento kurz nebola ešte aktivovaná'; diff --git a/locallib.php b/locallib.php index 61f520a..378051e 100644 --- a/locallib.php +++ b/locallib.php @@ -8,7 +8,7 @@ require_once($CFG->libdir . '/gradelib.php'); define('VIEW_DAYS', 1); define('VIEW_WEEKS', 2); define('VIEW_MONTHS', 3); -define('VIEW_ALLTAKEN', 4); +define('VIEW_ALLPAST', 4); define('VIEW_ALL', 5); define('SORT_LASTNAME', 1); @@ -89,7 +89,6 @@ class attforblock_permissions { require_capability('mod/attforblock:changepreferences', $this->context); } - public function can_export() { if (is_null($this->canexport)) $this->canexport = has_capability('mod/attforblock:export', $this->context); @@ -97,6 +96,10 @@ class attforblock_permissions { return $this->canexport; } + public function require_export_capability() { + require_capability('mod/attforblock:export', $this->context); + } + public function can_be_listed() { if (is_null($this->canbelisted)) $this->canbelisted = has_capability('mod/attforblock:canbelisted', $this->context); @@ -190,7 +193,7 @@ class att_page_with_filter_controls { $this->startdate = make_timestamp($year, $mon); $this->enddate = make_timestamp($year, $mon + 1); break; - case VIEW_ALLTAKEN: + case VIEW_ALLPAST: $this->startdate = 1; $this->enddate = time(); break; diff --git a/renderer.php b/renderer.php index 3828ed6..cef7f6a 100644 --- a/renderer.php +++ b/renderer.php @@ -126,7 +126,7 @@ class mod_attforblock_renderer extends plugin_renderer_base { protected function render_view_controls(attforblock_filter_controls $fcontrols) { $views[VIEW_ALL] = get_string('all', 'attforblock'); - $views[VIEW_ALLTAKEN] = get_string('alltaken', 'attforblock'); + $views[VIEW_ALLPAST] = get_string('allpast', 'attforblock'); $views[VIEW_MONTHS] = get_string('months', 'attforblock'); $views[VIEW_WEEKS] = get_string('weeks', 'attforblock'); $views[VIEW_DAYS] = get_string('days', 'attforblock'); diff --git a/sessions.php b/sessions.php index 2ab3f36..f51ecfc 100644 --- a/sessions.php +++ b/sessions.php @@ -1,5 +1,14 @@