Closed mnods closed 3 years ago
Hi Troy, happy to be wrong but we found that role assignments in a course were not getting picked up in the dialogue "People to send to field" no matter what we did with receive capabilities.
line 60 - list($esql, $eparams) = get_enrolled_sql($context, 'mod/dialogue:receive', null, true);
it seems gets enrolled users only and role assignments are not included (as far as i can see) as enrolled users, but are in moodle terms "other users".
So what we did was create a role for users to have a role assignment across a wide range of courses and give that role the receiveother capability. they now show up in the dialogue people field for a course in which they have a role assignment. one issue is that with the displayed user list it doesn't get included in the "displaying x of x" notice in the drop down.
Ok, makes sense now. Label is determined by $results, $matches, $pagesize returned https://github.com/troywilliams/moodle-mod_dialogue/blob/a644b5cfbd8c1597449b5ca4147ac7c4406b5c3d/locallib.php#L133
closing this off as it conflicts now that we are using the core autocomplete field - it may be easier to achieve what you were trying to do previously so feel free to submit another pull request against the latest version and I'd be happy to take a look! - thanks.
Hi,
Can you please give an explanation of what you are trying to achieve? The code looks identical to current functionality. You can define other roles as receivers at site admin > users > permissions > define roles or configure for particular dialogue activity by overriding the role. You go to dialogue then admin > permissions and give the receive capability to role that what.
Regards,
Troy