Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MDL-25459 removing option to set picture and tags in admin profile se…

…tup form, we can use these only after setup is finished
  • Loading branch information...
commit de2d81fad50654a8cfb2321a91d03e4225864599 1 parent de8a84e
@skodak skodak authored
View
4 user/editadvanced.php
@@ -176,12 +176,12 @@
useredit_update_user_preference($usernew);
// update tags
- if (!empty($CFG->usetags)) {
+ if (!empty($CFG->usetags) and empty($USER->newadminuser)) {
useredit_update_interests($usernew, $usernew->interests);
}
//update user picture
- if (!empty($CFG->gdversion)) {
+ if (!empty($CFG->gdversion) and empty($USER->newadminuser)) {
useredit_update_picture($usernew, $userform);
}
View
2  user/editadvanced_form.php
@@ -100,7 +100,7 @@ function definition_after_data() {
}
// print picture
- if (!empty($CFG->gdversion)) {
+ if (!empty($CFG->gdversion) and empty($USER->newadminuser)) {
$image_el =& $mform->getElement('currentpicture');
if ($user and $user->picture) {
$image_el->setValue($OUTPUT->user_picture($user, array('courseid'=>SITEID)));
View
4 user/editlib.php
@@ -232,7 +232,7 @@ function useredit_shared_definition(&$mform, $editoroptions = null) {
$mform->setType('description_editor', PARAM_CLEANHTML);
$mform->addHelpButton('description_editor', 'userdescription');
- if (!empty($CFG->gdversion)) {
+ if (!empty($CFG->gdversion) and empty($USER->newadminuser)) {
$mform->addElement('header', 'moodle_picture', get_string('pictureofuser'));
$mform->addElement('static', 'currentpicture', get_string('currentpicture'));
@@ -248,7 +248,7 @@ function useredit_shared_definition(&$mform, $editoroptions = null) {
}
- if (!empty($CFG->usetags)) {
+ if (!empty($CFG->usetags) and empty($USER->newadminuser)) {
$mform->addElement('header', 'moodle_interests', get_string('interests'));
$mform->addElement('tags', 'interests', get_string('interestslist'), array('display' => 'noofficial'));
$mform->addHelpButton('interests', 'interestslist');
Please sign in to comment.
Something went wrong with that request. Please try again.