Issue Details (XML | Word | Printable)

Key: MDL-11529
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Tim Hunt
Reporter: Daniele Cordella
Votes: 0
Watchers: 0
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

When assigning/overriding roles, the dropdown for switching to another role should have a number in brackets

Created: 01/Oct/07 03:02 PM   Updated: 05/Nov/08 05:17 PM
Return to search
Component/s: Administration
Affects Version/s: 1.8.2
Fix Version/s: 2.0

Participants: Daniele Cordella and Tim Hunt
Security Level: None
Resolved date: 05/Nov/08
Affected Branches: MOODLE_18_STABLE
Fixed Branches: MOODLE_20_STABLE


 Description  « Hide
Three steps description:

Step 1.
As not unique admin, sometimes, I need to clean all roles of my colleagues because they are, at the same time, teachers and/or student, at category level and/or course level and/or site level and so on. I usually go to look for their name everywhere but... in the assign role of a course , when I select a role (to let you understand: moodle18/admin/roles/assign.php?contextid=xxx&roleid=2, for instance) I get a page with a drop down menu with ONLY list of roles.

Again, to let you understand, what I get is:

<select id="switchrole_jump" name="jump" onchange="self.location=document.getElementById('switchrole').jump.options[document.getElementById('switchrole').jump.selectedIndex].value;">
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=0">List all roles...</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=1">Administrator</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=2" selected="selected">Course creator</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=3">Teacher</option>

   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=4">Non-editing teacher</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=5">Student</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=6">Guest</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=7">Authenticated user</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=10">Ruolo dei produttori</option>
   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=11">Ruolo dei CAV</option>
</select>
What I would point out is that in each item of the <select> I can only read the name of the role BUT NOT THE NUMEBER OF USER belonging to each role.

Step 2.
On the opposite
If I divide my students into "groups" in the page:
moodle18/group/index.php?id=xx, for instance
what I get is a select in which for each group I can also read the number of users belonging to each group.

To let you understand, what I get is:

<select name="group" id="groups" size="15" class="select" onchange="membersCombo.refreshMembers(this.options[this.selectedIndex].value);"
 onclick="window.status=this.options[this.selectedIndex].title;" onmouseout="window.status='';">
<option value="1" title="produttori azienda A (1)">produttori azienda A (1)</option>
<option value="2" title="produttori azienda B (1)">produttori azienda B (1)</option>
</select>

Step 3.
What I ask is to have in the select of the step 1 the number of user belonging to each role.

This

   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=2" selected="selected">Course creator (3)</option>

instead of

   <option value="http://localhost:8888/moodle18/admin/roles/assign.php?userid=0&amp;courseid=3&amp;contextid=34&amp;roleid=2" selected="selected">Course creator</option>

Sorry for a so long story for a so silly request.
Ciao.


 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Tim Hunt added a comment - 30/Oct/08 11:15 AM
So, on the assign page, the dropdown should have the number of assignments for each role in brakets, and on the override page, it should have the number of overrides for each role.

Tim Hunt made changes - 30/Oct/08 11:15 AM
Field Original Value New Value
Summary Not homogeneous user interface When assigning/overriding roles, the dropdown for switching to another role should have a number in brackets
Tim Hunt made changes - 30/Oct/08 11:16 AM
Fix Version/s 2.0 [ 10122 ]
Assignee Martin Dougiamas [ dougiamas ] Tim Hunt [ timhunt ]
tjhunt committed 11 files to 'Moodle CVS' - 30/Oct/08 07:49 PM
user selection: MDL-16993 Convert the assign roles page to use the new components.

At the same time, I took the opportunity to try to work on some of the usability issues on this page. Note that I have not quite finished! So don't comment until tomorrow.

In the course of doing this, I also did: half of

MDL-11529 Show the number of assignees of each role in the change role dropdown on this page.
MDL-17067 Make it clear in the UI that admins are not allowed to unassign themselves.
MODIFY user/selector/script.js   Rev. 1.7    (+6 -21 lines)
MODIFY lang/en_utf8/error.php   Rev. 1.137    (+2 -1 lines)
MODIFY admin/roles/assign.php   Rev. 1.85    (+160 -231 lines)
MODIFY user/selector/lib.php   Rev. 1.8    (+268 -26 lines)
DEL admin/roles/Attic/assign.html   Rev. 1.37    (+0 -0 lines)
MODIFY lib/accesslib.php   Rev. 1.527    (+30 -2 lines)
MODIFY theme/standard/styles_layout.css   Rev. 1.623    (+58 -16 lines)
MODIFY group/members.php   Rev. 1.17    (+3 -3 lines)
MODIFY user/selector/search.php   Rev. 1.3    (+29 -6 lines)
MODIFY lang/en_utf8/role.php   Rev. 1.69    (+9 -1 lines)
MODIFY admin/roles/roles.js   Rev. 1.2    (+14 -0 lines)
Mitsuhiro Yoshida committed 5 files to 'Lang CVS' - 31/Oct/08 02:04 PM
MDL-11529 Translated a new string for error message.
MDL-16966 Tarnslated new strings for user selection.
MDL-15352 Translated a new string for remote Moodle repository.
MDL-16993 Translated new strings for role.
MODIFY ja_utf8/role.php   Rev. 1.75    (+12 -0 lines)
MODIFY ja_utf8/README   Rev. 1.855    (+1 -1 lines)
MODIFY ja_utf8/repository_remotemoodle.php   Rev. 1.7    (+1 -0 lines)
MODIFY ja_utf8/error.php   Rev. 1.100    (+1 -0 lines)
MODIFY ja_utf8/moodle.php   Rev. 1.320    (+3 -1 lines)
tjhunt committed 13 files to 'Moodle CVS' - 05/Nov/08 05:17 PM
role overrides: MDL-17070 Improve override roles page to match the recent usability improvements on the assign page.

Including:
MDL-11529 When assigning/overriding roles, the dropdown for switching to another role should have a number in brackets

MDL-16549 Should not be able to edit the permission associated with moodle/site:doanything on any role.
MODIFY admin/roles/override.php   Rev. 1.55    (+217 -111 lines)
MODIFY admin/roles/Attic/manage.html   Rev. 1.43    (+2 -2 lines)
MODIFY lib/accesslib.php   Rev. 1.530    (+141 -59 lines)
MODIFY admin/roles/manage.php   Rev. 1.66    (+3 -3 lines)
MODIFY lang/en_utf8/error.php   Rev. 1.141    (+2 -1 lines)
MODIFY lang/en_utf8/role.php   Rev. 1.71    (+23 -21 lines)
MODIFY lib/moodlelib.php   Rev. 1.1127    (+15 -2 lines)
MODIFY lib/weblib.php   Rev. 1.1168    (+13 -7 lines)
DEL admin/roles/Attic/override.html   Rev. 1.25    (+0 -0 lines)
MODIFY lang/en_utf8/admin.php   Rev. 1.237    (+3 -0 lines)
MODIFY admin/roles/tabs.php   Rev. 1.36    (+17 -8 lines)
MODIFY admin/roles/assign.php   Rev. 1.88    (+36 -39 lines)
MODIFY pix/i/risk_dataloss.gif   Rev. 1.1    (+0 -0 lines)
Tim Hunt made changes - 05/Nov/08 05:17 PM
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]