1
0
mirror of https://github.com/moodle/moodle.git synced 2025-05-18 22:20:43 +02:00

2 Commits

Author SHA1 Message Date
Marina Glancy
722e6ba947 MDL-35339 Deprecate add_mod_to_section(), create new function course_add_cm_to_section()
Function add_mod_to_section() has very confusing arguments when object  looks like record from
table course_modules but field ->section refers to relative section number (course_sections.section).
In table course_modules the field section refers to course_sections.id.
Also add_mod_to_section() does not update table course_modules and does not call rebuild_course_cache()
which developer can forget to do afterwards.

- Added function course_add_cm_to_section()
- In the core code add_mod_to_section() is replaced with course_add_cm_to_section()
- Function add_mod_to_section() is deprecated
2012-10-15 14:08:13 +08:00
Petr Skoda
7e7cfe7a03 MDL-32960 refactor phpunit integration to one class per file structure 2012-05-12 20:53:48 +02:00