Skip to content

Commit 38245c6

Browse files
committed
Fixed the javascript code in the floor-plan template that adds room links. It didn't handle rooms without assinged floor-plans well.
- Legacy-Id: 12192
1 parent 27cd211 commit 38245c6

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

ietf/templates/meeting/floor-plan.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,11 +102,11 @@ <h3>{{ floor.name }}</h3>
102102
var left = 0, top = 0, right = 0, bottom = 0, floor="", width=0;
103103

104104
if (0) { }
105-
{% for room in meeting.room_set.all %}
106-
else if (nm == '{{room.name|xslugify}}') { left = {{room.left}}; top = {{room.top}}; right = {{room.right}}; bottom = {{room.bottom}}; floor='{{room.floorplan.name|xslugify}}'; width={{room.floorplan.image.width}}; }{% endfor %}
105+
{% for room in meeting.room_set.all %}{% if room.floorplan %}
106+
else if (nm == '{{room.name|xslugify}}') { left = {{room.left}}; top = {{room.top}}; right = {{room.right}}; bottom = {{room.bottom}}; floor='{{room.floorplan.name|xslugify}}'; width={{room.floorplan.image.width}}; }{% endif %}{% endfor %}
107107

108-
{% for room in meeting.room_set.all %}{% if room.functional_display_name %}
109-
else if (nm == '{{room.functional_name|xslugify}}') { left = {{room.left}}; top = {{room.top}}; right = {{room.right}}; bottom = {{room.bottom}}; floor='{{room.floorplan.name|xslugify}}'; width={{room.floorplan.image.width}}; }{% endif %}{% endfor %}
108+
{% for room in meeting.room_set.all %}{% if room.functional_display_name %}{% if room.floorplan %}
109+
else if (nm == '{{room.functional_name|xslugify}}') { left = {{room.left}}; top = {{room.top}}; right = {{room.right}}; bottom = {{room.bottom}}; floor='{{room.floorplan.name|xslugify}}'; width={{room.floorplan.image.width}}; }{% endif %}{% endif %}{% endfor %}
110110

111111
else return null;
112112

0 commit comments

Comments
 (0)