Index: WAeUP_SRP/trunk/Accommodation.py
===================================================================
--- WAeUP_SRP/trunk/Accommodation.py	(revision 1448)
+++ WAeUP_SRP/trunk/Accommodation.py	(revision 1449)
@@ -146,9 +146,4 @@
                 continue
             sid = student.id
-            already = accommodation(student=sid)
-            if already:
-                bed['Error'] = "Student already reserved %s" % already[0].bed
-                no_import.append( format_error % bed)
-                continue
             names = bed.get('name').split()
             n = 0
@@ -197,4 +192,14 @@
                 no_import.append( format_error % bed)
                 continue
+            already = accommodation(student=sid)
+            if already:
+                accommodation.modifyRecord(bed=already[0].bed,student='')
+                student_obj = getattr(students_folder, student.id)
+                acco_id = "accommodation_%s" % self.getSessionId()
+                if acco_id in student_obj.objectIds():
+                    acco_doc = getattr(student_obj, acco_id).getContent()
+                    acco_doc.edit(mapping={'bed': bid})
+                    member = self.portal_membership.getAuthenticatedMember()
+                    logger.info('"%s","changed reserved bed %s for","%s"' % (member,bid,sid))
             accommodation.modifyRecord(bed = bid, student = sid)
             imported.append( format % bed)
@@ -219,4 +224,5 @@
         open("%s/import/%s_not_imported%s.csv" % (i_home,name,current),"a").write(
                                                 '\n'.join(no_import))
+        logger.info('finished loading from %s.csv' % name)
         return self.REQUEST.RESPONSE.redirect("%s" % self.REQUEST.get('URL1'))
 
Index: WAeUP_SRP/trunk/Widgets.py
===================================================================
--- WAeUP_SRP/trunk/Widgets.py	(revision 1448)
+++ WAeUP_SRP/trunk/Widgets.py	(revision 1449)
@@ -278,37 +278,4 @@
 ###)
 
-##class StudentIdWidget(CPSStringWidget): ###(
-##    """ StudentId Widget"""
-##    meta_type = "StudentId Widget"
-##    digits = 8
-##    digits_str = "N"*digits
-##    letters = 2
-##    letters_str = "L"*letters
-##
-##    def validate(self, datastructure, **kw):
-##        """Validate datastructure and update datamodel."""
-##
-##        valid = CPSStringWidget.validate(self, datastructure, **kw)
-##        if not valid:
-##            return 0
-##        else:
-##            widget_id = self.getWidgetId()
-##            value = datastructure[widget_id]
-##            err = 0
-##            if not (len(value) == self.digits + self.letters and value[:self.digits].isdigit() and value[self.digits:].isalpha()):
-##                err = 'Invalid Registration Number in the format: %s%s with N = Number, L = Letter' % (self.digits_str,self.letters_str)
-##            if err:
-##                datastructure.setError(widget_id, err)
-##            else:
-##                datamodel = datastructure.getDataModel()
-##                datamodel[self.fields[0]] = value
-##
-##            return not err
-##
-##InitializeClass(StudentIdWidget)
-##widgetRegistry.register(StudentIdWidget)
-##
-#####)
-
 class JambRegNoWidget(CPSStringWidget): ###(
     """ JambRegNo Widget"""
@@ -478,5 +445,5 @@
             err = 'Invalid StudentId String %s.' % value
             logger.info('"%s","invalid StudentId String"' % value)
-            datastructure['student'] = res
+            datastructure['student'] = None
         else:
             value = value.upper()
Index: WAeUP_SRP/trunk/doc/srp_documentation.mm
===================================================================
--- WAeUP_SRP/trunk/doc/srp_documentation.mm	(revision 1448)
+++ WAeUP_SRP/trunk/doc/srp_documentation.mm	(revision 1449)
@@ -10,5 +10,5 @@
 <node CREATED="1170079621592" ID="Freemind_Link_1297017754" MODIFIED="1170079640872" POSITION="right" TEXT="Campus">
 <node CREATED="1171710559043" ID="Freemind_Link_1592396213" MODIFIED="1171710565212" TEXT="Id: campus"/>
-<node CREATED="1170079643589" FOLDED="true" ID="Freemind_Link_1231068129" MODIFIED="1171710686426" TEXT="Academic Section">
+<node CREATED="1170079643589" ID="Freemind_Link_1231068129" MODIFIED="1171710686426" TEXT="Academic Section">
 <node CREATED="1171710577379" ID="Freemind_Link_1444831124" MODIFIED="1171710589887" TEXT="Id: academics"/>
 <node CREATED="1170080366716" ID="Freemind_Link_415048819" MODIFIED="1171709591652" TEXT="{Faculties}">
@@ -18,5 +18,5 @@
 <node CREATED="1170080406892" ID="Freemind_Link_1983042340" MODIFIED="1171709620984" TEXT="{Departments}">
 <node CREATED="1171125049973" ID="Freemind_Link_734335561" LINK="../profiles/default/types/Department.xml" MODIFIED="1171125103478" TEXT="Type: Department"/>
-<node CREATED="1171125108968" ID="Freemind_Link_553285905" LINK="../profiles/default/schemas/department.xml" MODIFIED="1171125232838" TEXT="Schema: department"/>
+<node CREATED="1171125108968" ID="Freemind_Link_553285905" LINK="../profiles/default/schemas/department.xml" MODIFIED="1172001385770" TEXT="Schema: department"/>
 <node CREATED="1171125727127" ID="Freemind_Link_481382280" LINK="../profiles/default/layouts/department.xml" MODIFIED="1171125762591" TEXT="Layout: department"/>
 <node CREATED="1170080420252" ID="Freemind_Link_290613406" MODIFIED="1171710340659" TEXT="Courses">
@@ -46,5 +46,5 @@
 </node>
 </node>
-<node CREATED="1170082138244" ID="Freemind_Link_1354366927" MODIFIED="1171710679266" TEXT="Student Section">
+<node CREATED="1170082138244" FOLDED="true" ID="Freemind_Link_1354366927" MODIFIED="1171710679266" TEXT="Student Section">
 <node CREATED="1171709784119" ID="_" MODIFIED="1171709937449" TEXT="Type: StudentsFolder" VSHIFT="104"/>
 <node CREATED="1171710545564" ID="Freemind_Link_221165828" MODIFIED="1171710551332" TEXT="Id: students"/>
@@ -117,5 +117,5 @@
 </node>
 </node>
-<node CREATED="1170082502675" ID="Freemind_Link_1051871348" MODIFIED="1171710707226" TEXT="Accommodation Section">
+<node CREATED="1170082502675" FOLDED="true" ID="Freemind_Link_1051871348" MODIFIED="1171710707226" TEXT="Accommodation Section">
 <node CREATED="1171710631948" ID="Freemind_Link_161316738" MODIFIED="1171710638848" TEXT="Id: accommodation"/>
 <node CREATED="1171114205479" ID="Freemind_Link_685193459" LINK="../profiles/default/types/AccoFolder.xml" MODIFIED="1171360542032" TEXT="Type: AccoFolder"/>
@@ -164,4 +164,12 @@
 <node CREATED="1171712154817" ID="Freemind_Link_1307066201" MODIFIED="1171712169348" TEXT="PUME/PDE Resuts Table"/>
 </node>
+<node CREATED="1172001308558" ID="Freemind_Link_1997267023" MODIFIED="1172001322577" POSITION="right" TEXT="profiles">
+<node CREATED="1172001324877" ID="Freemind_Link_1866579033" MODIFIED="1172001330846" TEXT="default">
+<node CREATED="1172001340812" ID="Freemind_Link_274105864" LINK="../profiles/default/directories.xml" MODIFIED="1172001465313" TEXT="portal_directories"/>
+<node CREATED="1172001340812" ID="Freemind_Link_1612370167" LINK="../profiles/default/layouts.xml" MODIFIED="1172001506077" TEXT="portal_layouts"/>
+<node CREATED="1172001340812" ID="Freemind_Link_7840481" LINK="../profiles/default/schemas.xml" MODIFIED="1172001572800" TEXT="portal_schemas"/>
+<node CREATED="1172001340812" ID="Freemind_Link_1164818739" LINK="../profiles/default/types.xml" MODIFIED="1172001612293" TEXT="portal_types"/>
+</node>
+</node>
 </node>
 </map>
Index: WAeUP_SRP/trunk/profiles/default/content.xsl
===================================================================
--- WAeUP_SRP/trunk/profiles/default/content.xsl	(revision 1449)
+++ WAeUP_SRP/trunk/profiles/default/content.xsl	(revision 1449)
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+  <xsl:output method="html"/>
+  <xsl:template match="/">
+    <html>
+      <head>
+        <title>
+          <xsl:value-of select="object/name"/>
+        </title>
+        <link rel="stylesheet" type="text/css" media="all"
+              href="../xsl.css" />      
+      </head>
+      <body>
+        <xsl:for-each select="object">
+          <h2>
+            <xsl:value-of select="@name"/> : <xsl:value-of select="@meta_type"/>
+          </h2> 
+          <h1>Objects</h1>
+          <table>
+            <xsl:variable name="path">
+              <xsl:choose>
+                <xsl:when test="@name='portal_directories'">
+                  <xsl:text>directories</xsl:text>
+                </xsl:when>
+                <xsl:when test="@name='portal_layouts'">
+                  <xsl:text>layouts</xsl:text>
+                </xsl:when>
+                <xsl:when test="@name='portal_schemas'">
+                  <xsl:text>schemas</xsl:text>
+                </xsl:when>
+                <xsl:when test="@name='portal_types'">
+                  <xsl:text>types</xsl:text>
+                </xsl:when>
+                <xsl:when test="@name='portal_vocabularies'">
+                  <xsl:text>vocabularies</xsl:text>
+                </xsl:when>
+                <xsl:when test="@name='portal_workflows'">
+                  <xsl:text>workflows</xsl:text>
+                </xsl:when>
+                <xsl:otherwise>
+                  <xsl:text>xxxxxx</xsl:text>
+                </xsl:otherwise>
+              </xsl:choose>
+            </xsl:variable>
+          <xsl:for-each select="object">
+            <xsl:sort select="@name"
+                      order="ascending" />
+            <xsl:variable name="color">
+              <xsl:choose>
+                <xsl:when test="position() mod 2 = 0">
+                  <xsl:text>#ffffff</xsl:text>
+                </xsl:when>
+                <xsl:otherwise>
+                  <xsl:text>#eeeeee</xsl:text>
+                </xsl:otherwise>
+              </xsl:choose>
+            </xsl:variable>
+            <tr style="background-color:{$color}">
+              <td colspan="">
+                <xsl:value-of select="@name"/>
+              </td>
+              <td colspan="">
+                <a href="{$path}/{@name}.xml"><xsl:value-of select="@name"/></a>
+              </td>
+              <td colspan="">
+                <xsl:value-of select="@meta_type"/>
+              </td>
+            </tr>
+          </xsl:for-each>
+        </table>
+        </xsl:for-each>
+      </body>
+    </html>
+  </xsl:template>
+</xsl:stylesheet>
Index: WAeUP_SRP/trunk/profiles/default/directories.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/directories.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/directories.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_directories" meta_type="CPS Directory Tool">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts.xml	(revision 1449)
@@ -1,41 +1,42 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_layouts" meta_type="CPS Layouts Tool">
- <property name="title"></property>
- <object name="acco_hall" meta_type="CPS Layout"/>
- <object name="acco_bed_booking" meta_type="CPS Layout"/>
- <object name="academics_search" meta_type="CPS Layout"/>
- <object name="certificate" meta_type="CPS Layout"/>
- <object name="certificate_course" meta_type="CPS Layout"/>
- <object name="course" meta_type="CPS Layout"/>
- <object name="department" meta_type="CPS Layout"/>
- <object name="faculty" meta_type="CPS Layout"/>
- <object name="members" meta_type="CPS Layout"/>
- <object name="members_search" meta_type="CPS Layout"/>
- <object name="payment" meta_type="CPS Layout"/>
- <object name="student" meta_type="CPS Layout"/>
- <object name="scratch_card_batch" meta_type="CPS Layout"/>
- <object name="scratch_card_search" meta_type="CPS Layout"/>
- <object name="student_accommodation" meta_type="CPS Layout"/>
- <object name="student_accommodation_fe" meta_type="CPS Layout"/>
- <object name="student_application" meta_type="CPS Layout"/>
- <object name="student_application_fe" meta_type="CPS Layout"/>
- <object name="student_application_search" meta_type="CPS Layout"/>
- <object name="student_session_results_search" meta_type="CPS Layout"/>
- <object name="student_clearance" meta_type="CPS Layout"/>
- <object name="student_clearance_fe" meta_type="CPS Layout"/>
- <object name="student_course_result" meta_type="CPS Layout"/>
- <object name="student_create" meta_type="CPS Layout"/>
- <object name="student_personal" meta_type="CPS Layout"/>
- <object name="student_personal_fe" meta_type="CPS Layout"/>
- <object name="student_password" meta_type="CPS Layout"/>
- <object name="student_pume" meta_type="CPS Layout"/>
- <object name="student_pume_fe" meta_type="CPS Layout"/>
- <object name="student_schoolfee" meta_type="CPS Layout"/>
- <object name="student_search" meta_type="CPS Layout"/>
- <object name="student_study_level" meta_type="CPS Layout"/>
- <object name="student_study_course" meta_type="CPS Layout"/>
- <object name="student_transfer" meta_type="CPS Layout"/>
- <object name="study_level" meta_type="CPS Layout"/>
- <object name="university" meta_type="CPS Layout"/>
- <object name="waeup_common" meta_type="CPS Layout"/>
+  <property name="title">layouts</property>
+  <object name="acco_hall" meta_type="CPS Layout"/>
+  <object name="acco_bed_booking" meta_type="CPS Layout"/>
+  <object name="academics_search" meta_type="CPS Layout"/>
+  <object name="certificate" meta_type="CPS Layout"/>
+  <object name="certificate_course" meta_type="CPS Layout"/>
+  <object name="course" meta_type="CPS Layout"/>
+  <object name="department" meta_type="CPS Layout"/>
+  <object name="faculty" meta_type="CPS Layout"/>
+  <object name="members" meta_type="CPS Layout"/>
+  <object name="members_search" meta_type="CPS Layout"/>
+  <object name="payment" meta_type="CPS Layout"/>
+  <object name="student" meta_type="CPS Layout"/>
+  <object name="scratch_card_batch" meta_type="CPS Layout"/>
+  <object name="scratch_card_search" meta_type="CPS Layout"/>
+  <object name="student_accommodation" meta_type="CPS Layout"/>
+  <object name="student_accommodation_fe" meta_type="CPS Layout"/>
+  <object name="student_application" meta_type="CPS Layout"/>
+  <object name="student_application_fe" meta_type="CPS Layout"/>
+  <object name="student_application_search" meta_type="CPS Layout"/>
+  <object name="student_session_results_search" meta_type="CPS Layout"/>
+  <object name="student_clearance" meta_type="CPS Layout"/>
+  <object name="student_clearance_fe" meta_type="CPS Layout"/>
+  <object name="student_course_result" meta_type="CPS Layout"/>
+  <object name="student_create" meta_type="CPS Layout"/>
+  <object name="student_personal" meta_type="CPS Layout"/>
+  <object name="student_personal_fe" meta_type="CPS Layout"/>
+  <object name="student_password" meta_type="CPS Layout"/>
+  <object name="student_pume" meta_type="CPS Layout"/>
+  <object name="student_pume_fe" meta_type="CPS Layout"/>
+  <object name="student_schoolfee" meta_type="CPS Layout"/>
+  <object name="student_search" meta_type="CPS Layout"/>
+  <object name="student_study_level" meta_type="CPS Layout"/>
+  <object name="student_study_course" meta_type="CPS Layout"/>
+  <object name="student_transfer" meta_type="CPS Layout"/>
+  <object name="study_level" meta_type="CPS Layout"/>
+  <object name="university" meta_type="CPS Layout"/>
+  <object name="waeup_common" meta_type="CPS Layout"/>
 </object>
Index: WAeUP_SRP/trunk/profiles/default/layouts/academics_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/academics_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/academics_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/common.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/common.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/common.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="common" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/course.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/course.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/course.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="course" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/department.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/department.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/department.xml	(revision 1449)
@@ -1,4 +1,4 @@
 <?xml version="1.0"?>
-<?xml-stylesheet type="text/xsl" href="types.xsl"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="department" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/faculty.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/faculty.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/faculty.xml	(revision 1449)
@@ -1,4 +1,4 @@
 <?xml version="1.0"?>
-<?xml-stylesheet type="text/xsl" href="types.xsl"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="faculty" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/members.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/members.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/members.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="members" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/members_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/members_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/members_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="members_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/payment.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/payment.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/payment.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="payment" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_batch.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_batch.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_batch.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="scratch_card_batch" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/scratch_card_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="scratch_card_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_accommodation" meta_type="CPS Layout">
  <property name="layout_create_method">layout_enter_access_code</property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation_fe.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation_fe.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_accommodation_fe.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_accommodation_fe" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_application_fe.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_application_fe.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_application_fe.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_application_fe" meta_type="CPS Layout">
  <property name="layout_create_method">layout_enter_access_code</property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_application_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_application_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_application_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_application_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_clearance_fe.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_clearance_fe.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_clearance_fe.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_clearance_fe" meta_type="CPS Layout">
  <property name="layout_create_method">layout_enter_access_code</property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_course_result.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_course_result.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_course_result.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="course_results" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_password.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_password.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_password.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_password" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_personal.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_personal.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_personal.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_personal" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_personal_fe.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_personal_fe.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_personal_fe.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_personal_fe" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_pume.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_pume.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_pume.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_pume" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_pume_fe.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_pume_fe.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_pume_fe.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_pume" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_schoolfee.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_schoolfee.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_schoolfee.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_schoolfee" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_session_results_search.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_session_results_search.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_session_results_search.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_session_results_search" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/student_transfer.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/student_transfer.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/student_transfer.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="student_transfer" meta_type="CPS Layout">
   <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/study_level.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/study_level.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/study_level.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="study_level" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/university.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/university.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/university.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="university" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/layouts/waeup_common.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/layouts/waeup_common.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/layouts/waeup_common.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="layout.xsl"?>
 <object name="waeup_common" meta_type="CPS Layout">
  <property name="layout_create_method"></property>
Index: WAeUP_SRP/trunk/profiles/default/schemas.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/schemas.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/schemas.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_schemas" meta_type="CPS Schemas Tool">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/types.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_types" meta_type="CMF Types Tool">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/types/AcademicsFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/AcademicsFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/AcademicsFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="AcademicsFolder" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/CertificatesFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/CertificatesFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/CertificatesFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="CertificatesFolder" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/CoursesFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/CoursesFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/CoursesFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="CoursesFolder" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/Payment.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/Payment.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/Payment.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="Payment" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/PaymentsFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/PaymentsFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/PaymentsFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="PaymentsFolder" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatch.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatch.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatch.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="ScratchCardBatch" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatchesFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatchesFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/ScratchCardBatchesFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="ScratchCardBatchesFolder"
    meta_type="CPS Flexible Type Information"
Index: WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentAccommodation.xml	(revision 1449)
@@ -44,3 +44,9 @@
   <permission value="Modify portal content"/>
  </action>
+ <action title="Release Bed" action_id="release_bed" category="object"
+         condition_expr="" 
+         url_expr="string:${object_url}/release_bed"
+         visible="True">
+  <permission value="Modify portal content"/>
+ </action>
 </object>
Index: WAeUP_SRP/trunk/profiles/default/types/StudentCourseResult.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentCourseResult.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentCourseResult.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="StudentCourseResult" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentPume.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="StudentPume" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/StudentsFolder.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudentsFolder.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/StudentsFolder.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="StudentsFolder" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/StudyLevel.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/StudyLevel.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/StudyLevel.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="StudyLevel" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/types/University.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/types/University.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/types/University.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="types.xsl"?>
 <object name="University" meta_type="CPS Flexible Type Information"
    xmlns:i18n="http://xml.zope.org/namespaces/i18n">
Index: WAeUP_SRP/trunk/profiles/default/vocabularies.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_vocabularies" meta_type="CPS Vocabularies Tool">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/academics_search_mode.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/academics_search_mode.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/academics_search_mode.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="search_mode_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/acco_special_handling.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/acco_special_handling.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/acco_special_handling.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="acco_special_handling" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/courselevel.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/courselevel.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/courselevel.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="courselevel" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/exam_grades.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/exam_grades.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/exam_grades.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="high_grade" meta_type="CPS Vocabulary">
   <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/exam_subjects.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/exam_subjects.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/exam_subjects.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="high_grade" meta_type="CPS Vocabulary">
   <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/exam_types.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/exam_types.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/exam_types.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="exam_types" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/get_departments_voc.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/get_departments_voc.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/get_departments_voc.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="get_departments_voc" meta_type="CPS Method Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/get_faculties_voc.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/get_faculties_voc.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/get_faculties_voc.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="get_faculties_voc" meta_type="CPS Method Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/get_searchable_student_states.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/get_searchable_student_states.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/get_searchable_student_states.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="get_searchable_student_states" meta_type="CPS Method Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/global_roles.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/global_roles.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/global_roles.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="global_roles" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/high_grade.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/high_grade.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/high_grade.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="high_grade" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/high_qual.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/high_qual.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/high_qual.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="high_qual" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/institution_types_voc.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/institution_types_voc.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/institution_types_voc.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="institute_types_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/local_gov_areas.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/local_gov_areas.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/local_gov_areas.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="local_gov_areas" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/nigerian_states.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/nigerian_states.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/nigerian_states.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="nigerian_states" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/pin_prefixes.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/pin_prefixes.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/pin_prefixes.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="pin_prefixes" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/religion.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/religion.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/religion.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="religion" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/scratch_card_search_mode.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/scratch_card_search_mode.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/scratch_card_search_mode.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="search_mode_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_academics_states.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_academics_states.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_academics_states.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="searchable_review_states_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_student_states.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_student_states.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_student_states.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="searchable_student_states_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/semester_voc.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/semester_voc.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/semester_voc.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="courselevel" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/states.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/states.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/states.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="states" meta_type="CPS Vocabulary">
     <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/student_search_mode.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/student_search_mode.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/student_search_mode.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="search_mode_voc" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_bed_letters.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_bed_letters.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_bed_letters.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="waeup_bed_letters" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_block_letters.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_block_letters.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/vocabularies/waeup_block_letters.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="vocabulary.xsl"?>
 <object name="waeup_bed_letters" meta_type="CPS Vocabulary">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/profiles/default/workflows.xml
===================================================================
--- WAeUP_SRP/trunk/profiles/default/workflows.xml	(revision 1448)
+++ WAeUP_SRP/trunk/profiles/default/workflows.xml	(revision 1449)
@@ -1,3 +1,4 @@
 <?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="content.xsl"?>
 <object name="portal_workflow" meta_type="CPS Workflow Tool">
  <property name="title"></property>
Index: WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed.py	(revision 1448)
+++ WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed.py	(revision 1449)
@@ -15,5 +15,6 @@
 logger = logging.getLogger('Accommodation.BookReservedBed')
 
-change = REQUEST.has_key("reserve_and_change")
+#change = REQUEST.has_key("reserve_and_change")
+change = False
 release = REQUEST.has_key("release")
 reserve = REQUEST.has_key("reserve")
@@ -61,4 +62,7 @@
 res = acco_cat(bed = bid)
 psm = ''
+students = context.portal_url.getPortalObject().campus.students
+student_obj = getattr(students,sid)
+acco_id = "accommodation_%s" % context.getSessionId()
 while True:
     if not res:
@@ -81,4 +85,9 @@
             break
     if release:
+        if acco_id in student_obj.objectIds():
+            acco_doc = getattr(student_obj, acco_id).getContent()
+            if acco_doc.bed == bid:
+                psm = "Student %s has not reserved bed" % (sid, bid)
+                break
         if not already:
             psm = "Student %s already has no reserved beds" % (sid, already[0].bed)
@@ -104,7 +113,4 @@
         acco_cat.modifyRecord(bed=bed.bed,student='')
 
-students = context.portal_url.getPortalObject().campus.students
-student_obj = getattr(students,sid)
-acco_id = "accommodation_%s" % context.getSessionId()
 if reserve or change:
     acco_cat.modifyRecord(bed = bid, student = sid)
@@ -115,12 +121,10 @@
     psm = "Bed reserved for %s %s" % (sid,student.name)
 elif release:
-    acco_cat.modifyRecord(bed=bid,student='')
     if acco_id in student_obj.objectIds():
         acco_doc = getattr(student_obj, acco_id).getContent()
-        if acco_doc.bed == bid:
-            acco_doc.edit(mapping={'bed':bid + " (reservation cancelled by %s!)" % member})
+        if acco_doc.bed != bid:
+            acco_cat.modifyRecord(bed=bid,student='')
     logger.info('"%s","cancelled reservation %s by","%s"' % (member,bid,sid))
     psm = "%s removed from %s" % (student.name,bid)
-
 mode = 'view'
 return context.book_reserved_bed_form(rendered = "",
Index: WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed_form.pt
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed_form.pt	(revision 1448)
+++ WAeUP_SRP/trunk/skins/waeup_accommodation/book_reserved_bed_form.pt	(revision 1449)
@@ -23,5 +23,5 @@
                  tal:attributes="value options/button"
                  tal:condition="not:creation" />
-          <input type="submit" tal:condition="python:mode !='view'"
+          <input type="submit" tal:condition="python:0 and mode !='view'"
                  class="standalone" 
                  name="reserve_and_change"
Index: WAeUP_SRP/trunk/skins/waeup_accommodation/change_bed.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_accommodation/change_bed.py	(revision 1448)
+++ WAeUP_SRP/trunk/skins/waeup_accommodation/change_bed.py	(revision 1449)
@@ -57,5 +57,12 @@
         acco_doc.edit(mapping=d)
         return redirect("%s/%s/%s" % (students.absolute_url(),student,info['acco_id']))
+    student_obj = getattr(students,student_id)
+    acco_id = "accommodation_%s" % context.getSessionId()
+    if acco_id in student_obj.objectIds():
+        acco_doc = getattr(student_obj, acco_id).getContent()
+        if acco_doc.bed == bed:
+            acco_doc.edit(mapping={'bed':bed + " (cancelled by change bed %s!)" % member})
     logger.info('"%s", "new bed allocation failed","%s"' % (student_id,code))
+    logger.info('"%s","cancelled booking of %s"' % (member,bed,sid))
     redirect("%s/%s/%s" % (students.absolute_url(),student,info['acco_id']))
 
Index: WAeUP_SRP/trunk/skins/waeup_accommodation/release_bed.py
===================================================================
--- WAeUP_SRP/trunk/skins/waeup_accommodation/release_bed.py	(revision 1449)
+++ WAeUP_SRP/trunk/skins/waeup_accommodation/release_bed.py	(revision 1449)
@@ -0,0 +1,43 @@
+## Script (Python) "change_bed"
+##bind container=container
+##bind context=context
+##bind namespace=
+##bind script=script
+##bind subpath=traverse_subpath
+##parameters=
+##title=
+##
+# $Id$
+"""
+release an allocated bed
+"""
+import logging
+logger = logging.getLogger('Student.Accommodation.release_bed')
+
+request = context.REQUEST
+redirect = request.RESPONSE.redirect
+mtool = context.portal_membership
+wf = context.portal_workflow
+member = mtool.getAuthenticatedMember()
+member_id = str(member)
+path_info = request.get('PATH_INFO').split('/')
+
+if mtool.isAnonymousUser():
+    return None
+students = context.portal_url.getPortalObject().campus.students
+acco_cat = context.portal_accommodation
+#stud_cat = context.students_catalog
+student_id = context.getStudentId()
+
+if student_id is not None:
+    logger.info('"%s", "requests bed_release for", "%s"' % (member_id,student_id))
+    res = acco_cat(student=student_id)
+    if len(res) == 0:
+        logger.info('"%s", "no bed found"' % (student_id))
+        redirect("%s/%s" % (students.absolute_url(),student_id))
+    allocated_bed = res[0]
+    acco_cat.modifyRecord(bed=allocated_bed.bed,student='')
+    acco_doc = context.getContent()
+    acco_doc.edit(mapping={'bed':acco_doc.bed + " (cancelled by release bed %s!)" % member})
+    redirect("%s" % (context.absolute_url()))
+
