Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-82418

Allow plugins to extend cohort page navigation

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 4.5
    • Cohorts
    • None
    • MOODLE_405_STABLE

      It would be useful if plugins could easily extend the navigation on the /cohort/index.php page. See screenshot attached.

      The use case for this is if plugins (for example, an alternative method to add/remove users to cohorts via the UI, or add/remove cohorts entirely) want to operate on the cohorts, and do it in the same context the cohorts are stored in (for capability checking, for example). Usually this context is either system or course category context.

      Being able to add a button here to me at least seems to be the easiest and most logic place for the users.

      Currently, these are built here https://github.com/moodle/moodle/blob/7d7a871eddf81cdc1e6f5ea9dda67cf9058dd032/cohort/lib.php#L644 with no option for extension.

      It would probably use the new hooks api https://moodledev.io/docs/4.4/apis/core/hooks as opposed to the older style lib.php callbacks.

       

            Unassigned Unassigned
            matthewhilton Matthew Hilton
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.