Course lists do not appear for adms in dashboard.

Course lists do not appear for adms in dashboard.

by Liveon Santos -
Number of replies: 6

Hello, I work in a school and currently it uses version 3.6.4, administrator users are not registered in the courses, but can see all the courses on the dashboard.

After having upgraded to version 3.9.4 on a backup site, they are no longer able to view courses on the dashboard.

We use the Adaptable theme, but we deactivated it and in the same way it hasn't changed at all, I believe that maybe it's some moodle configuration.

Would anyone know how it is possible for Administrators to see the same courses not registered on the dashboard?

Average of ratings: -
In reply to Liveon Santos

Re: Course lists do not appear for adms in dashboard.

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

Can you share a screenshot of the admin's dashboard on the 3.6.4 site? Hide or remove any information you don't want to share on the Internet.

In reply to Leon Stringer

Re: Course lists do not appear for adms in dashboard.

by Liveon Santos -
Right!

Old Version:
print

New Version:
print

Same configuration in frontpagesettings:
print
In reply to Liveon Santos

Re: Course lists do not appear for adms in dashboard.

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

So it looks like this problem is on the front page (https://moodle.example.com/) not the dashboard (https://moodle.example.com/my).

You say this problem occurs with Boost too, is that correct? What's the version of Adaptable on the Moodle 3.9 site? This is shown under Site administration ▸ Plugins ▸ Plugins overview.

Try enabling debugging as shown here – there may be an error causing this. Errors may be displayed in the browser but check the web server error logs too. Check the page source in the browser and make sure this looks correct: nothing in red and ending with:

</body>
</html>

What version of PHP is on the Moodle 3.9 server? This can be found at the top of Site administration ▸ Server ▸ PHP info.

In reply to Leon Stringer

Re: Course lists do not appear for adms in dashboard.

by Liveon Santos -
Correct, I changed the theme of the site and it had no results.
Adaptable - theme_adaptable - 2.2.4 - 2019112608
PHP Version 7.2.34
I activated debugging, but it doesn't give any warning, I looked at the php log and nothing too.
In reply to Liveon Santos

Re: Course lists do not appear for adms in dashboard.

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

I think this is a deliberate change in behaviour between Moodle 3.6 and Moodle 3.7. I think the change is MDL-57636 and it looks like the change is slightly different between versions:

  1. in Moodle 3.6 the change included some backward compatibility so the course list displayed as before, but
  2. in Moodle 3.7 onwards the behaviour changes as you've described.

Basically with Front page items when logged in set to "Enrolled courses" then this is what users, including the admin, sees on the front page. The admin isn't enrolled on the courses so doesn't see the list.

The fact these were seen in Moodle 3.6 was actually a bug, the one fixed in MDL-57636. Maybe changing Front page items when logged in to "List of courses" is the setting you want.

Also, there's a version of Adaptable specifically for Moodle 3.9: version 3.0.5 (2020073106).

In reply to Leon Stringer

Re: Course lists do not appear for adms in dashboard.

by Liveon Santos -
I checked the error / index.php file and contained the following information.
I don't know if any of the errors have to do with the problem.
____________________________________________________________________________________________________________

<?php

    require('../config.php');

    // Form submitted, do not check referer (original page unknown).
    if ($form = data_submitted()) {
        // Only deal with real users.
        if (!isloggedin()) {
            redirect($CFG->wwwroot);
        }

        // Send the message and redirect.
        $eventdata = new \core\message\message();
        $eventdata->courseid         = SITEID;
        $eventdata->component        = 'moodle';
        $eventdata->name             = 'errors';
        $eventdata->userfrom          = $USER;
        $eventdata->userto            = core_user::get_support_user();
        $eventdata->subject           = 'Error: '. $form->referer .' -> '. $form->requested;
        $eventdata->fullmessage       = $form->text;
        $eventdata->fullmessageformat = FORMAT_PLAIN;
        $eventdata->fullmessagehtml   = '';
        $eventdata->smallmessage      = '';
        message_send($eventdata);

        redirect($CFG->wwwroot .'/course/', 'Message sent, thanks', 3);
        exit;
    }

    $site = get_site();
    $redirecturl = empty($_SERVER['REDIRECT_URL']) ? '' : $_SERVER['REDIRECT_URL'];
    $httpreferer = get_local_referer(false);
    $requesturi  = empty($_SERVER['REQUEST_URI'])  ? '' : $_SERVER['REQUEST_URI'];

    header("HTTP/1.0 404 Not Found");
    header("Status: 404 Not Found");

    $PAGE->set_url('/error/');
    $PAGE->set_context(context_system::instance());
    $PAGE->set_title($site->fullname .':Error');
    $PAGE->set_heading($site->fullname .': Error 404');
    $PAGE->navbar->add('Error 404 - File not Found');
    echo $OUTPUT->header();
    echo $OUTPUT->box(get_string('pagenotexist', 'error'). '<br />'.s($requesturi), 'generalbox boxaligncenter');

    if (isloggedin()) {
?>
        <p><?php echo get_string('pleasereport', 'error'); ?>
        <p><form action="<?php echo $CFG->wwwroot ?>/error/index.php" method="post">
           <textarea rows="3" cols="50" name="text" id="text" spellcheck="true"></textarea><br />
           <input type="hidden" name="referer" value="<?php p($httpreferer) ?>">
           <input type="hidden" name="requested" value="<?php p($requesturi) ?>">
           <input type="submit" value="<?php echo get_string('sendmessage', 'error'); ?>">
           </form>
<?php
    } else {
        echo $OUTPUT->continue_button($CFG->wwwroot);
    }
    echo $OUTPUT->footer();
?>