Permalink
Browse files

MDL-22795 guest access icon + lang pack enrol related cleanup

AMOS BEGIN
 MOV [allowguests,core],[allowguests,enrol_guest]
AMOS END
  • Loading branch information...
1 parent bf423bb commit 3ead116af3e2097df4a564c238816f343c93fc97 @skodak skodak committed Aug 18, 2010
View
@@ -273,8 +273,6 @@
$strshow = get_string('show');
$strsummary = get_string('summary');
$strsettings = get_string('settings');
- $strallowguests = get_string('allowguests');
- $strrequireskey = get_string('requireskey');
echo '<form id="movecourses" action="category.php" method="post"><div>';
View
@@ -103,10 +103,6 @@
$table->align = array('center', 'center', 'center', 'center', 'center', 'center', 'center');
$table->head = array('&nbsp;', get_string('shortname'), get_string('fullname'),
get_string('requestedby'), get_string('summary'), get_string('requestreason'), get_string('action'));
- $strrequireskey = get_string('requireskey');
-
- // Loop over requested courses.
- $keyicon = $OUTPUT->pix_icon('i/key', $strrequireskey, 'moodle', array('class'=>'icon'));
foreach ($pending as $course) {
$course = new course_request($course);
@@ -115,8 +111,6 @@
$course->check_shortname_collision();
$row = array();
- // TODO: Show an enrolment key icon in the first column if applicable.
- // Info in the other columns.
$row[] = format_string($course->shortname);
$row[] = format_string($course->fullname);
$row[] = fullname($course->get_requester());
View
@@ -62,8 +62,6 @@ public function __construct(moodle_page $page, $target) {
* @return string
*/
public function course_category_tree(array $structure) {
- $this->strings->allowguests = get_string('allowguests');
- $this->strings->requireskey = get_string('requireskey');
$this->strings->summary = get_string('summary');
// Generate an id and the required JS call to make this a nice widget
@@ -24,6 +24,7 @@
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
+$string['allowguests'] = 'This course allows guest users to enter';
$string['guest:config'] = 'Configure guest access instances';
$string['password'] = 'Password';
$string['password_help'] = 'A password allows guest access to the course to be restricted to only those who know the password. Guests will be required to supply the password each time they access the course.';
View
@@ -31,6 +31,11 @@
class enrol_guest_plugin extends enrol_plugin {
+ public function get_info_icons(array $instances) {
+ //TODO: we need two different guest icons - with and without password
+ return array(new pix_icon('i/guest', get_string('allowguests', 'enrol_guest')));
+ }
+
public function enrol_user(stdClass $instance, $userid, $roleid = null, $timestart = 0, $timeend = 0) {
// no real enrolments here!
return;
View
@@ -26,4 +26,4 @@
defined('MOODLE_INTERNAL') || die();
-$plugin->version = 2010061500;
+$plugin->version = 2010081800;
View
@@ -31,6 +31,11 @@
*/
class enrol_self_plugin extends enrol_plugin {
+ public function get_info_icons(array $instances) {
+ //TODO: we need two different self enrol icons - with and without key
+ return array();
+ }
+
/**
* Returns localised name of enrol instance
*
View
@@ -124,7 +124,6 @@
$string['alllogs'] = 'All logs';
$string['allmods'] = 'All {$a}';
$string['allow'] = 'Allow';
-$string['allowguests'] = 'This course allows guest users to enter';
$string['allowinternal'] = 'Allow internal methods as well';
$string['allownone'] = 'Allow none';
$string['allownot'] = 'Do not allow';
@@ -1337,7 +1336,6 @@
$string['requestedcourses'] = 'Requested courses';
$string['requestreason'] = 'Reason for course request';
$string['required'] = 'Required';
-$string['requireskey'] = 'This course requires an enrolment key';
$string['requirespayment'] = 'This course requires payment for access';
$string['reset'] = 'Reset';
$string['resetcomponent'] = 'Component';

0 comments on commit 3ead116

Please sign in to comment.