
{% extends 'base.html' %}

{% block content %}
<h1>Update Channel Status </h1>
<br />
<div>
    channel : <span class="font-weight-bold">{{channel_name}}</span>
</div>
<form id="update_status" method="POST">
    {{ form.hidden_tag() }}
    <fieldset>
        <div class="row mb-3 ">
            <div class="col-12">
            {{ form.status.label(class="col-sm-2 col-form-label") }}
            <div class="col-sm-10">
                {% if form.status.errors %}
                {{ form.status(class="form-control is-invalid") }}
                <div class="invalid-feedback">
                    {% for error in form.status.errors %}
                    <span>{{ error }}</span>
                    {% endfor %}
                </div>
                {% else %}

                {{ form.status(class="col-sm-7 form-control") }}
    
                {% endif %}
            </div>
        
        </div> 
        <div class="row gx-2">
            <div class="col-5">
                <button type="submit" class="btn btn-primary" >
                    <i class="bi bi-plus-circle-fill"></i>
                    {{ submit_text }}
                </button>
                <div class="col-5">
  
                    <button type="button" class="btn btn-block btn-secondary" onclick="javascript: history.back()">
                        <i class="bi bi-box-arrow-in-left"></i>
                        Cancel
                    </button>
                </div>
            </div>
        </div>
      
    </div>
    </fieldset>
</form>
{% endblock %}