Skip to content

Commit 129d62e

Browse files
committed
Added 'remote_instructions' as an editable field for misc. sessions in the secretariat app, in order to be able to set remote access URLs.
- Legacy-Id: 18118
1 parent ae5de75 commit 129d62e

3 files changed

Lines changed: 8 additions & 1 deletion

File tree

ietf/secr/meetings/forms.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ class MiscSessionForm(TimeSlotForm):
166166
Plenary = IETF''',
167167
required=False)
168168
location = forms.ModelChoiceField(queryset=Room.objects, required=False)
169+
remote_instructions = forms.CharField(max_length=255)
169170
show_location = forms.BooleanField(required=False)
170171

171172
def __init__(self,*args,**kwargs):

ietf/secr/meetings/tests.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,7 @@ def test_meetings_misc_session_add_valid(self):
289289
'type':'reg',
290290
'group':group.pk,
291291
'location': room.pk,
292+
'remote_instructions': 'http://webex.com/foobar',
292293
})
293294
self.assertRedirects(response, url)
294295
session = Session.objects.filter(meeting=meeting, name='Testing').first()
@@ -332,6 +333,7 @@ def test_meetings_misc_session_edit(self):
332333
'duration':'01:00',
333334
'day':'2',
334335
'type':'other',
336+
'remote_instructions': 'http://webex.com/foobar',
335337
})
336338
self.assertRedirects(response, redirect_url)
337339
timeslot = session.official_timeslotassignment().timeslot

ietf/secr/meetings/views.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,7 @@ def misc_session_edit(request, meeting_id, schedule_name, slot_id):
523523
duration = form.cleaned_data['duration']
524524
slot_type = form.cleaned_data['type']
525525
show_location = form.cleaned_data['show_location']
526+
remote_instructions = form.cleaned_data['remote_instructions']
526527
time = get_timeslot_time(form, meeting)
527528
slot.location = location
528529
slot.name = name
@@ -535,6 +536,7 @@ def misc_session_edit(request, meeting_id, schedule_name, slot_id):
535536
session.group = group
536537
session.name = name
537538
session.short = short
539+
session.remote_instructions = remote_instructions
538540
session.save()
539541

540542
messages.success(request, 'Location saved')
@@ -552,7 +554,9 @@ def misc_session_edit(request, meeting_id, schedule_name, slot_id):
552554
'time':slot.time.strftime('%H:%M'),
553555
'duration':duration_string(slot.duration),
554556
'show_location':slot.show_location,
555-
'type':slot.type}
557+
'type':slot.type,
558+
'remote_instructions': session.remote_instructions,
559+
}
556560
form = MiscSessionForm(initial=initial, meeting=meeting, session=session)
557561

558562
return render(request, 'meetings/misc_session_edit.html', {

0 commit comments

Comments
 (0)