Skip to content

Commit 170271d

Browse files
committed
Added WebEx room resource name, query method and template logic to show WebEx room resources.
- Legacy-Id: 17437
1 parent 04d93a8 commit 170271d

3 files changed

Lines changed: 30 additions & 8 deletions

File tree

ietf/meeting/models.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright The IETF Trust 2007-2019, All Rights Reserved
1+
# Copyright The IETF Trust 2007-2020, All Rights Reserved
22
# -*- coding: utf-8 -*-
33
from __future__ import absolute_import, print_function, unicode_literals
44

@@ -399,6 +399,9 @@ def audio_stream_url(self):
399399
def video_stream_url(self):
400400
urlresource = self.urlresource_set.filter(name_id__in=['meetecho', ]).first()
401401
return urlresource.url if urlresource else None
402+
def webex_url(self):
403+
urlresource = self.urlresource_set.filter(name_id__in=['webex', ]).first()
404+
return urlresource.url if urlresource else None
402405
#
403406
class Meta:
404407
ordering = ["-id"]

ietf/name/fixtures/names.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11461,6 +11461,16 @@
1146111461
"model": "name.roomresourcename",
1146211462
"pk": "u-shape"
1146311463
},
11464+
{
11465+
"fields": {
11466+
"desc": "WebEx support",
11467+
"name": "WebEx session",
11468+
"order": 0,
11469+
"used": true
11470+
},
11471+
"model": "name.roomresourcename",
11472+
"pk": "webex"
11473+
},
1146411474
{
1146511475
"fields": {
1146611476
"desc": "",

ietf/templates/meeting/session_buttons_include.html

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,7 @@
2424
href="xmpp:{{item.session.jabber_room_name}}@jabber.ietf.org?join"
2525
title="Jabber room for {{item.session.jabber_room_name}}"><span class="fa fa-lightbulb-o"></span>
2626
</a>
27-
{% if "https://ietf.webex.com" in item.session.agenda_note|first_url %}
28-
<a class="btn btn-default btn-xs"
29-
href="{{ item.session.agenda_note|first_url }}"
30-
title="Webex session"><span class="fa fa-phone"></span>
31-
</a>
32-
{% else %}
27+
3328
<!-- Video stream (meetecho) -->
3429
{% if item.timeslot.location.video_stream_url %}
3530
<a class="btn btn-default btn-xs"
@@ -44,7 +39,21 @@
4439
title="Audio stream"><span class="glyphicon glyphicon-headphones"></span>
4540
</a>
4641
{% endif %}
47-
{% endif %}
42+
<!-- WebEx -->
43+
{% if "https://ietf.webex.com" in item.session.agenda_note|first_url %}
44+
<a class="btn btn-default btn-xs"
45+
href="{{ item.session.agenda_note|first_url }}"
46+
title="Webex session"><span class="fa fa-phone"></span>
47+
</a>
48+
{% else %}
49+
{% if item.timeslot.location.webex_url %}
50+
<a class="btn btn-default btn-xs"
51+
href="{{item.timeslot.location.webex_url|format:item.session }}"
52+
title="Webex session"><span class="fa fa-phone"></span>
53+
</a>
54+
{% endif %}
55+
{% endif %}
56+
4857
{% else %}
4958

5059
<!-- Jabber logs -->

0 commit comments

Comments
 (0)