Changing functionality "coursetags" in 3.0, please object before it's too late.
As part of MDL-50851 I'm changing some functions in Tag API and have discovered one of "easter egg" Moodle functionality called course tags. There are so many things wrong with it and so many bugs that migrating on the new API is impossible without either fixing or dropping it. I have not found a single bug in the tracker regarding this and I assume nobody knows about it / uses it.
First of all, what is wrong:
- This functionality can be enabled only in the settings of the block "Tags" by checking "Show course tags" ($CFG->block_tags_showcoursetags). When enabled block "Tags" can no longer be used for displaying tag cloud and is used to allow users to tag the current course with some tags.
- Every tag added to the course via this block "belongs" to the user who added it. So no manager can change the set of tags for the course if they were added by another user. Courses can be searched by the tags using "Site pages > Tags" search box just as well as user interests and blog posts tags. Obviously bad tag words can be removed or flagged as inappropriate but nothing can be done with valid tag words that are irrelevant.
- BUG: When course is backed up and then restored the information about the user is lost and nobody at all can change it any more
- BUG: When course is being deleted function coursetag_delete_course_tags() is called that deletes tags instead of deleting tag instances. This means that if the deleted course has been tagged with "moodle", the tag "moodle" is removed from any user's interests, any blog post, etc.
- BUG: If instance of block "Tags" is configured to show official only tags, and user is trying to add a tag it will disappear without any explanation because newly added tags are not official
- UI of course tags (again, accessible only via block) is so terrible, it makes me want to vomit. There are some minor bugs there as well.
- It is impossible to use "Tags" block to display tagcloud when $CFG->block_tags_showcoursetags is on
and so on
What I would like to do:
- remove all "coursetags" functionality such as block setting, pages to add/edit "my" course tags
- during upgrade automatically convert all existing course tags into proper user-less tags
- add a field in course edit form that will allow teacher/manager to set or change course tags similar as one can set user interests, blog tags, question tags, wiki pages tags, etc.
- everybody will still be able to search for tagged courses using /tag/search.php
If you do use the coursetag functionality in it's current form, please tell us why it is good and we should not drop it.
If you don't but would like to tag courses - vote for MDL-51132