r/list/" class="btn btn-secondary">Cancel</a>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
{% endblock %}

{% block custom_page_scripts %}
<script>
$(document).ready(function() {
    // Prevent selecting the same group for both add and remove
    $('#add_group, #remove_group').on('change', function() {
        var addGroup = $('#add_group').val();
        var removeGroup = $('#remove_group').val();

        if (addGroup