Changeset 7059 for main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py
- Timestamp:
- 9 Nov 2011, 12:40:22 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/students/browser.py
r7056 r7059 1373 1373 return selectBed(available_beds) 1374 1374 1375 # This update method simulates a valid callback und must be 1376 # specified in the customization package. The parameters must be taken 1377 # from the incoming request. 1375 # Relocate student if student parameters have changed or the bed_type 1376 # of the bed has changed 1378 1377 def update(self): 1379 1378 student = self.context.getStudent() 1380 1379 acc_details = self.getAccommodationDetails(student) 1381 if acc_details['bt'] == self.context.bed_type: 1380 if acc_details['bt'] == self.context.bed_type and \ 1381 self.context.bed.bed_type == self.context.bed_type: 1382 1382 self.flash("Bed category hasn't changed. Student can't be relocated.") 1383 1383 return 1384 # Search a bed and exit if no bed is found or if the student 1385 # has already booked a bed 1384 # Search a bed and exit if no bed is found 1386 1385 cat = queryUtility(ICatalog, name='beds_catalog', default=None) 1387 1386 entries = cat.searchResults( … … 1393 1392 % acc_details['bt']) 1394 1393 return 1395 entries = cat.searchResults(1396 owner=(student.student_id,student.student_id))1394 #entries = cat.searchResults( 1395 # owner=(student.student_id,student.student_id)) 1397 1396 # Rlease old bed 1398 1397 try:
Note: See TracChangeset for help on using the changeset viewer.