$string['add'] = 'Add';
$string['addplugin'] = 'Add a repository plugin';
$string['activaterep'] = 'Active repositories';
+$string['areabackup'] = 'Backups';
+$string['areacategoryintro'] = 'Category introduction';
+$string['areacourseintro'] = 'Course introduction';
+$string['arearoot'] = 'System';
+$string['areauserdraft'] = 'Drafts';
+$string['areauserpersonal'] = 'Personal';
$string['attachment'] = 'Attachment';
$string['back'] = '< Back';
$string['cacheexpire'] = 'Cache expire';
}
}
$urlbase = $CFG->wwwroot.'/userfile.php';
- // TODO: localise
- return new file_info_stored($this, $context, $storedfile, $urlbase, 'Personal files', false, true, true);
+ return new file_info_stored($this, $context, $storedfile, $urlbase, get_string('areauserpersonal', 'repository'), false, true, true);
} else if ($filearea == 'user_draft') {
if (empty($itemid)) {
return null;
}
}
- // TODO: localise
- return new file_info_stored($this, $context, $storedfile, $urlbase, 'Draft file area', true, true, true);
+ return new file_info_stored($this, $context, $storedfile, $urlbase, get_string('areauserdraft', 'repository'), true, true, true);
}
}
return null;
}
}
- // TODO: localise
- return new file_info_stored($this, $context, $storedfile, $urlbase, 'Category introduction files', false, true, true);
+ return new file_info_stored($this, $context, $storedfile, $urlbase, get_string('areacategoryintro', 'repository'), false, true, true);
}
}
return null;
}
}
- // TODO: localise
- return new file_info_stored($this, $context, $storedfile, $urlbase, 'Course introduction files', false, true, true);
+ return new file_info_stored($this, $context, $storedfile, $urlbase, get_string('areacourseintro', 'repository'), false, true, true);
} else if ($filearea == 'course_backup') {
if (!has_capability('moodle/site:backup', $context) and !has_capability('moodle/site:restore', $context)) {
$downloadable = has_capability('moodle/site:backupdownload', $context);
$uploadable = has_capability('moodle/site:backupupload', $context);
- // TODO: localise
- return new file_info_stored($this, $context, $storedfile, $urlbase, 'Backup files', false, $downloadable, $uploadable);
+ return new file_info_stored($this, $context, $storedfile, $urlbase, get_string('areabackup', 'repository'), false, $downloadable, $uploadable);
} else if ($filearea == 'course_content') {
if (!has_capability('moodle/course:managefiles', $context)) {
public function __construct($browser, $context, $storedfile) {
global $CFG;
$urlbase = $CFG->wwwroot.'/file.php';
- parent::__construct($browser, $context, $storedfile, $urlbase, 'Course files', false, true, true); // TODO: localise
+ parent::__construct($browser, $context, $storedfile, $urlbase, get_string('coursefiles'), false, true, true);
}
public function get_url($forcedownload=false, $https=false) {