Suggest Totara Learn features
This forum discussion has been removed
I'd like to +1 this request.
Also it seems completly pointless hiding courses from people but leaving an empty category which learners can then infer the types of courses that are on the system that they are not allowed access to. I would have assumed that if the category doesn't contain any courses that I can see, then I wouldn't see the category.
David
if (audience visibility enabled) { if ($item->audiencevisible == ALL) { // show item
} else if (user_has_manageaudiencevisibility_capability()) {
// show item } else if (user_is_enrolled_in_course()) { // show item } else if (user_viewing_is_in_any_audience_with_this_as_visible_learning($item)) { // show item } else { // hide item } } else { // normal moodle behaviour if ($item->visible) { // show item } else if (has_capability('moodle/course:viewhiddencourses', $itemcontext)) { // show item dimmed } else { // don't show item } }
When creating an audience there is a Context field that allows the selection of the course category .Is it possible that this value could be used for helping decide audience visibility.
I can't see what this context field does as changing this doesn't seem to affect the selection of enrolled or visible learning outside the selected context but assume it has some function.
Audiences in Totara are actually what are called "Cohorts" in Moodle. We have extended them to add the dynamic functionality (in moodle cohorts are manually assigned.
In moodle it is possible to create a cohort either at the site level or in a category context. If a cohort is created in a category context it only appears under that category. See here:
http://docs.moodle.org/25/en/Cohorts#Managing_category_cohorts
One other thing we changed was the cohort list page, and it looks like when we made that change we forgot to filter the list by context, so in Totara currently all cohorts are shown on both the system list (Site Admin > Users > Accounts > Audiences) and on the individual category lists (Go to category then click Admin > [Category Name] > Audiences).
That's a bug and I'll file a ticket.
Hope that clears it up.
Simon
Hi Sam,
It is going through testing right now, as long as there are no issues found it should be in next Tuesday's release of 2.5.10 (18th March). If it doesn't make that for some reason it will be out 2 weeks later, but we could provide a patch file that you could apply in that case.
Simon
A fix for hiding the empty categories issue was included in today's (18 March 2014) release of Totara 2.5.10