from django.shortcuts import render # Create your views here. from webgui.settings import APPLICATION_NAME from .models import ChannelSettings from .forms import ChannelSettingsForm def channel_settings(request, channel_id): initial_data = { "interact": ChannelSettings.objects.get(channel=channel_id).interact } context = { 'title': 'Channel settings', 'icon': 'screwdriver', 'description': 'Modify channel settings for ' + APPLICATION_NAME, 'keywords': 'settigns, channel', 'form': ChannelSettingsForm(initial=initial_data), } return render(request, 'config/channel_settings.html', context)