Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Blocks 2.0.3 UI

From MoodleDocs
Revision as of 02:21, 9 March 2011 by Dongsheng Cai (talk | contribs)

This page specs some refinements to the blocks config UI for Moodle 2.0.3. See MDL-26105 for details.

Home context

Indicate where the "home" context is for this block. The place it was created.

Reduce page types

Reduce the number of page type options using a callback so that all components can exactly specify what they support. If the component doesn't have a callback then fallback to the calculated list we have now.

Upgrade block_instances->page_patterns

All of the existing instances need to be upgraded to remove any settings that are no longer appearing in the UI. This will have to be implemented with an upgrade block in each module, added at the same time as the callback.

Sub-page types

Instead of showing "This specific page (Page 13)" (the sub page id)

  • Remove the "Page 13" completely
  • Make the navbar show the page name: Sitename -> Site pages -> Tags -> My funky tag -> XXX Block -> Configuration


User blocks

Blocks created on user pages ie the My Moodle page or profile pages (including those that were copied from the default blocks the first time the user tries to customise the page) just need to show the page types menu to select between:

  • Public user profile page (user-profile)
  • Private "My Moodle" page (my-index)
  • All pages (*)

This list will come from a callback function in /user/lib.php

Module blocks

Blocks should looking for page pattern from module callback which comes from /mod/$mod/lib.php

Blocks' page types should be limited to module context only, module will decide what types will be available.