Index: main/waeup.sirp/trunk/src/waeup/sirp/browser/pages.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/browser/pages.py	(revision 7334)
+++ main/waeup.sirp/trunk/src/waeup/sirp/browser/pages.py	(revision 7335)
@@ -1715,4 +1715,6 @@
     tabtwoactions = ['Add course referrer',
                      'Remove selected course referrers','Cancel']
+    tabthreeactions1 = ['Remove selected local roles']
+    tabthreeactions2 = ['Add local role']
 
     @property
@@ -1751,4 +1753,26 @@
         self.redirect(self.url(self.context))
         return
+
+    def getLocalRoles(self):
+        roles = ILocalRolesAssignable(self.context)
+        return roles()
+
+    def getUsers(self):
+        """Get a list of all users.
+        """
+        for key, val in grok.getSite()['users'].items():
+            url = self.url(val)
+            yield(dict(url=url, name=key, val=val))
+
+    def getUsersWithLocalRoles(self):
+        return get_users_with_local_roles(self.context)
+
+    @grok.action('Add local role', validator=NullValidator)
+    def addLocalRole(self, **data):
+        return add_local_role(self, 3, **data)
+
+    @grok.action('Remove selected local roles')
+    def delLocalRoles(self, **data):
+        return del_local_roles(self,3,**data)
 
 
Index: main/waeup.sirp/trunk/src/waeup/sirp/browser/templates/certificatemanagepage.pt
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/browser/templates/certificatemanagepage.pt	(revision 7334)
+++ main/waeup.sirp/trunk/src/waeup/sirp/browser/templates/certificatemanagepage.pt	(revision 7335)
@@ -16,101 +16,149 @@
 
 <div id="tabs">
-<ul>
-  <li><a href="#tab-1"><span>Settings</span></a></li>
-  <li><a href="#tab-2"><span>Course Referrers</span></a></li>
-</ul>
+  <ul>
+    <li><a href="#tab-1"><span>Settings</span></a></li>
+    <li><a href="#tab-2"><span>Course Referrers</span></a></li>
+    <li><a href="#tab-3"><span>Local Roles</span></a></li>
+  </ul>
    
-<div id="tab-1">        
-      <table class="zebra">
+  <div id="tab-1">
+        <table class="zebra">
+        <tbody>
+        <tal:block repeat="widget view/widgets">
+          <tr>
+            <td class="label">
+              <label tal:attributes="for widget/name">
+                <span class="required" tal:condition="widget/required">*</span>
+                <span i18n:translate="" tal:content="widget/label">label</span>:
+              </label>
+            </td>
+            <td class="field">
+              <span class="widget" tal:content="structure widget">
+                <input type="text" />
+              </span>
+              <tal:error tal:condition="widget/error">
+                <span tal:replace="structure widget/error">error</span>
+              </tal:error>
+              <tal:hint tal:condition="widget/hint">
+                <span class="hint" tal:content="structure widget/hint">hint</span>
+              </tal:hint>
+            </td>
+          </tr>
+        </tal:block>
+        </tbody>
+        </table>
+        <div class="actionButtons" tal:condition="view/availableActions">
+          <span tal:repeat="action view/actions"
+                tal:omit-tag="">
+            <input tal:condition="python:action.label in view.taboneactions"
+                   tal:replace="structure action/render"/>
+          </span>
+        </div>
+  </div>
+  <div id="tab-2">
+    <h3>Course Referrers</h3>
+    <table class="display dataTableManage">
+      <thead>
+        <tr>
+          <th>&nbsp;</th><th>Level</th><th>Semester</th><th>Referrer</th><th>Course</th><th>Title</th>
+          <th>Mandatory</th>
+        </tr>
+      </thead>
       <tbody>
-      <tal:block repeat="widget view/widgets">
-        <tr>
-          <td class="label">
-            <label tal:attributes="for widget/name">
-              <span class="required" tal:condition="widget/required">*</span>
-              <span i18n:translate="" tal:content="widget/label">label</span>:
-            </label>
+        <tr tal:repeat="cc context/values">
+           <td>
+            <input type="checkbox"
+      		 name="val_id"
+      		 tal:attributes="value cc/__name__" />
           </td>
-          <td class="field">
-            <span class="widget" tal:content="structure widget">
-              <input type="text" />
+           <td>
+            <span tal:content="cc/level">
+      	   LEVEL
             </span>
-            <tal:error tal:condition="widget/error">
-              <span tal:replace="structure widget/error">error</span>
-            </tal:error>
-            <tal:hint tal:condition="widget/hint">
-              <span class="hint" tal:content="structure widget/hint">hint</span>
-            </tal:hint>
+          </td>
+          <td tal:content="cc/course/semester">SEMESTER</td>
+          <td>
+            <a tal:attributes="href python: view.url(cc)"
+      	     tal:content="cc/__name__">
+          	REFERRER CODE
+            </a>
+          </td>
+          <td>
+            <a tal:attributes="href python:view.url(cc.course)"
+      	     tal:content="cc/course/code">
+          	COURSE CODE
+            </a>
+          </td>
+          <td>
+            <span tal:content="cc/course/title">
+      	   COURSE TITLE
+            </span>
+          </td>
+          <td>
+            <span tal:content="cc/core_or_elective">
+      	   MANDATORY
+            </span>
           </td>
         </tr>
-      </tal:block>
       </tbody>
-      </table>
-      <div class="actionButtons" tal:condition="view/availableActions">
-        <span tal:repeat="action view/actions"
-              tal:omit-tag="">
-          <input tal:condition="python:action.label in view.taboneactions"
-                 tal:replace="structure action/render"/>
-        </span>
-      </div>
-
-</div>    
-    
-<div id="tab-2">
-  <h3>Course Referrers</h3>
-  <table class="display dataTableManage">
-    <thead>
-      <tr>
-        <th>&nbsp;</th><th>Level</th><th>Semester</th><th>Referrer</th><th>Course</th><th>Title</th>
-        <th>Mandatory</th>
+    </table>
+    <div class="actionButtons" tal:condition="view/availableActions">
+      <span tal:repeat="action view/actions"
+            tal:omit-tag="">
+        <input tal:condition="python:action.label in view.tabtwoactions"
+               tal:replace="structure action/render"/>
+      </span>
+    </div>
+  </div>
+  <div id="tab-3"> <br />
+    <table class="display dataTableManage">
+      <thead>
+        <tr>
+          <th>&nbsp;
+          </th>
+          <th>User Id
+          </th>
+          <th>Name
+          </th>
+          <th>Local Role
+          </th>
+        </tr>
+      </thead>
+      <tbody>
+        <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeB"> <td>
+            <input type="checkbox" name="role_id" tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
+          <td tal:content="entry/user_name"> USERNAME </td>
+          <td tal:content="entry/user_title"> USERTITLE </td>
+          <td tal:content="entry/local_role_title"> LOCAL ROLE </td>
+        </tr>
+      </tbody>
+    </table>
+    <div class="actionButtons" tal:condition="view/availableActions">
+      <span tal:repeat="action view/actions" tal:omit-tag="">
+        <input tal:condition="python:action.label in view.tabthreeactions1" tal:replace="structure action/render"/>
+      </span>
+    </div><br /><br />
+    <table class="zebra">
+      <tr> <td>
+          <select id="user" name="user">
+            <option tal:repeat="user view/getUsers" tal:attributes="value user/name">
+            <span tal:replace="user/val/title">USERTITLE
+            </span>
+            </option>
+          </select> </td> <td>
+          <select id="local_role" name="local_role">
+            <option tal:repeat="localrole view/getLocalRoles" tal:attributes="value localrole/name">
+            <span tal:replace="localrole/title">LOCALROLETITLE
+            </span>
+            </option>
+          </select> </td> <td>
+          <div tal:condition="view/availableActions">
+            <span tal:repeat="action view/actions" tal:omit-tag="">
+              <input tal:condition="python:action.label in view.tabthreeactions2" tal:replace="structure action/render"/>
+            </span>
+          </div> </td>
       </tr>
-    </thead>
-    <tbody>
-      <tr tal:repeat="cc context/values">
-         <td>
-          <input type="checkbox"
-    		 name="val_id"
-    		 tal:attributes="value cc/__name__" />
-        </td>
-         <td>
-          <span tal:content="cc/level">
-    	   LEVEL
-          </span>
-        </td>
-        <td tal:content="cc/course/semester">SEMESTER</td>
-        <td>
-          <a tal:attributes="href python: view.url(cc)"
-    	     tal:content="cc/__name__">
-        	REFERRER CODE
-          </a>
-        </td>
-        <td>
-          <a tal:attributes="href python:view.url(cc.course)"
-    	     tal:content="cc/course/code">
-        	COURSE CODE
-          </a>
-        </td>        
-        <td>
-          <span tal:content="cc/course/title">
-    	   COURSE TITLE
-          </span>
-        </td>
-        <td>
-          <span tal:content="cc/core_or_elective">
-    	   MANDATORY
-          </span>
-        </td>                
-      </tr>
-    </tbody>
-  </table>
-  <div class="actionButtons" tal:condition="view/availableActions">
-    <span tal:repeat="action view/actions"
-          tal:omit-tag="">
-      <input tal:condition="python:action.label in view.tabtwoactions"
-             tal:replace="structure action/render"/>
-    </span>
+    </table>
   </div>
-  
-</div>
 </div>
 </form>  
Index: main/waeup.sirp/trunk/src/waeup/sirp/permissions.py
===================================================================
--- main/waeup.sirp/trunk/src/waeup/sirp/permissions.py	(revision 7334)
+++ main/waeup.sirp/trunk/src/waeup/sirp/permissions.py	(revision 7335)
@@ -83,5 +83,5 @@
 
 class CourseAdviser100(grok.Role):
-    """The course adviser role is meant for the
+    """The 100 level course adviser role is meant for the
     assignment of dynamic roles only.
     """
@@ -91,5 +91,5 @@
 
 class CourseAdviser200(grok.Role):
-    """The course adviser role is meant for the
+    """The course 200 level adviser role is meant for the
     assignment of dynamic roles only.
     """
@@ -99,5 +99,5 @@
 
 class CourseAdviser300(grok.Role):
-    """The course adviser role is meant for the
+    """The 300 level course adviser role is meant for the
     assignment of dynamic roles only.
     """
@@ -107,5 +107,5 @@
 
 class CourseAdviser400(grok.Role):
-    """The course adviser role is meant for the
+    """The 400 level course adviser role is meant for the
     assignment of dynamic roles only.
     """
@@ -115,5 +115,5 @@
 
 class CourseAdviser500(grok.Role):
-    """The course adviser role is meant for the
+    """The 500 level course adviser role is meant for the
     assignment of dynamic roles only.
     """
@@ -123,5 +123,5 @@
 
 class CourseAdviser600(grok.Role):
-    """The course adviser role is meant for the
+    """The 600 level course adviser role is meant for the
     assignment of dynamic roles only.
     """
