Index: /main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/utils.py
===================================================================
--- /main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/utils.py	(revision 16891)
+++ /main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/utils.py	(revision 16892)
@@ -162,2 +162,23 @@
         payment.p_combi = combi
         return None, payment
+
+    def getAccommodationDetails(self, student):
+        """Determine the accommodation data of a student.
+        """
+        d = {}
+        d['error'] = u''
+        hostels = grok.getSite()['hostels']
+        d['booking_session'] = hostels.accommodation_session
+        d['allowed_states'] = hostels.accommodation_states
+        d['startdate'] = hostels.startdate
+        d['enddate'] = hostels.enddate
+        d['expired'] = hostels.expired
+        # Determine bed type
+        bt = 'all'
+        if student.sex == 'f':
+            sex = 'female'
+        else:
+            sex = 'male'
+        special_handling = 'regular'
+        d['bt'] = u'%s_%s_%s' % (special_handling,sex,bt)
+        return d
