Development:Categories editing interface improvment: различия между версиями

Материал из База знаний Центра ПУСК МФТИ
1>Oasychev
м Add wiki markup
 
м 1 версия импортирована
 
(нет различий)

Текущая версия от 08:51, 21 октября 2024

Moodle have quite good interface for editing of long lists in topic/weekly course format. However, category editing interface sadly missing this. In particular, moving categories around is very awkward. So the idea is to implement in category list editing interface similar to that of topic/weekly course format.


Implementation

Here are the probable changes to remove this issue: Changes in moodle_list class from listlib.php:

  1. mark method process_actions($left, $right, $moveup, $movedown) as obsolete;
  2. create new method process_action($action, $value) which will handle all moodle_list actions. $action can be:
    • move at the first place in context,
    • move at the place after any category,
    • move into category as first sub-categoty;
  3. make the same changes in question_category_list class (child of moodle_list);
  4. create property "moving" which will signals that list elements can be moved.


It will be displayed like:

Файл:Before moove categories editing.jpg

After pushing button "move" Файл:Moving categories editing.jpg