ajout de l'affichage du batiment sur les inscriptions
This commit is contained in:
parent
8bb2d40bff
commit
291e1e51c3
@ -44,6 +44,16 @@ class RegistrationController(AuthenticatedBaseController):
|
||||
rooms = Room.get_rooms(self.user, self.user.residence_dn)
|
||||
rooms = sorted(rooms, key=lambda t:t.cn.first())
|
||||
|
||||
areas = Room.get_areas(self.user, self.user.residence_dn)
|
||||
for room in rooms:
|
||||
for area in areas:
|
||||
if area.dn in room.dn:
|
||||
room.area = area
|
||||
break
|
||||
#end if
|
||||
#end for
|
||||
#end for
|
||||
|
||||
now = datetime.now()
|
||||
|
||||
month_names = [
|
||||
|
@ -39,7 +39,7 @@
|
||||
<select name="room_uid">
|
||||
<option value=""><vide></option>
|
||||
<py:for each="target_room in rooms">
|
||||
<option value="${target_room.uid.first()}">${target_room.cn.first()}</option>
|
||||
<option value="${target_room.uid.first()}">${target_room.cn.first()} [BAT-${target_room.area.cn.first()}]</option>
|
||||
</py:for>
|
||||
</select>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user