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

Eliminate DB queries in mod/glossary/settings.php

    XMLWordPrintable

Details

    • MOODLE_20_STABLE, MOODLE_311_STABLE, MOODLE_33_STABLE
    • MOODLE_311_STABLE
    • MDL-27193_glossaryDB
    • Hide
      1. Visit /admin/settings.php?section=modsettingglossary You should see 7 formats under "Display formats setup" listed in alphabetical order.
      2. Verify clicking on one of the format visibility icons should cause the eye to toggle open/closed.
      3. Verify clicking one of the format settings icons should take you to a page of settings for that specific glossary format.
      4. Verify clicking on 'site administration' and searching for something related to glossary display formats (eg dictionary) results in the respective display format being returned in the search results.
      Show
      Visit /admin/settings.php?section=modsettingglossary You should see 7 formats under "Display formats setup" listed in alphabetical order. Verify clicking on one of the format visibility icons should cause the eye to toggle open/closed. Verify clicking one of the format settings icons should take you to a page of settings for that specific glossary format. Verify clicking on 'site administration' and searching for something related to glossary display formats (eg dictionary) results in the respective display format being returned in the search results.

    Description

      This is an extension of MDL-27123.

      Someone needs to do a search for $DB in all settings.php files, and all files in admin/settings, and get rid of them all.

      The normal trick for doing this is as in this change: https://github.com/timhunt/moodle/commit/7351b54e86a408354e66f885c1561b8cb904032b. Use the lazy-loading facility provided by admin_setting_configselect so that the database query is only done when necessary.

      Attachments

        Activity

          People

            andyjdavis Andrew Davis
            timhunt Tim Hunt
            Jake Dallimore Jake Dallimore
            Anna Carissa Sadia Anna Carissa Sadia
            Ilya Tregubov, Kevin Percy, Mathew May, Mihail Geshoski, Shamim Rezaie
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              17/May/21

              Time Tracking

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 20 minutes
                2h 20m