<commit_before>{% extends "base.html" %}
{% load i18n %}
{% load dateconv %}

{% block content %}
    <div class="container">
    {% include "messages.html" %}
        <ul class="breadcrumb">
            <li><a href="{% url "containerview" %}">Containers</a></li>
       </ul> 
    
        <table class="table table-striped">
        
        <thead>
            <tr>
                <th style="width: 1em;" class="hidden-phone"></th>
                <th>{% trans 'Name' %}</th>
                <th style="width: 1em;" class="hidden-phone">{% trans 'Objects' %}</th>
                <th style="width: 5em;" class="hidden-phone">{% trans 'Size' %}</th>
                <th style="width: 1em;">

                <a href="{% url "create_container" %}" class="btn btn-mini btn-danger">
                    <i class="icon-plus icon-white"></i> 
                </a>

                </th>
            </tr>
        </thead>
        <tbody>
        {% for container in containers %}
            <tr>
            <td class="hidden-phone"><i class="icon-inbox"></i></td>
            <td><strong><a href="{% url "objectview" container=container.name %}" class="block">{{container.name}}</a></strong></td>
    	    <td class="hidden-phone">{{container.count}}</td>
    	    <td class="hidden-phone">{{container.bytes|filesizeformat}}</td>

            <td>
                <div class="dropdown pull-right">
                    <a class="dropdown-toggle btn btn-mini btn-danger" data-toggle="dropdown"><i class="icon-chevron-down icon-white"></i></a>
                    <ul class="dropdown-menu">
                        {% url "edit_acl" container=container.name as edit_acl_url %}
                        {% if edit_acl_url %}
                            <li><a href="{{ edit_acl_url }}"><i class="icon-user"></i> {% trans 'Sharing' %}</a></li>
                            <li class="divider" />
                        {% endif %}
 
                        <li>
                            <a href="{% url "containerview" %}?delete={{ container.name }}" onclick="return confirm('{% trans 'Delete container' %} {{container.name}}?');">
                                <i class="icon-trash"></i> {% trans 'Delete container' %}
                            </a>
                        </li>
                    </ul>
                </div>
            </td>

            </tr> 

        {% empty %}
        <tr>
            <td colspan="5">
            <strong><center>{% trans 'There are no containers in this account yet. Create a new container by clicking the red button.' %}<center></strong>
            </td>
        </tr> 
 
        {% endfor %}
        </tbody> 
       
        <tfoot>
            <tr>
                <th colspan="5" class="center">
                    {{account_stat.x_account_bytes_used|filesizeformat}} 
                    {% if account_stat.x_account_meta_quota_bytes %}
                        {% trans 'of' %}
                        {{account_stat.x_account_meta_quota_bytes|filesizeformat}} 
                    {% endif %}
                    {% trans 'used' %}
                </th>
            </tr>
        </tfoot><commit_msg>Fix container deletion<commit_after>{% extends "base.html" %}
{% load i18n %}
{% load dateconv %}

{% block content %}
    <div class="container">
    {% include "messages.html" %}
        <ul class="breadcrumb">
            <li><a href="{% url "containerview" %}">Containers</a></li>
       </ul> 
    
        <table class="table table-striped">
        
        <thead>
            <tr>
                <th style="width: 1em;" class="hidden-phone"></th>
                <th>{% trans 'Name' %}</th>
                <th style="width: 1em;" class="hidden-phone">{% trans 'Objects' %}</th>
                <th style="width: 5em;" class="hidden-phone">{% trans 'Size' %}</th>
                <th style="width: 1em;">

                <a href="{% url "create_container" %}" class="btn btn-mini btn-danger">
                    <i class="icon-plus icon-white"></i> 
                </a>

                </th>
            </tr>
        </thead>
        <tbody>
        {% for container in containers %}
            <tr>
            <td class="hidden-phone"><i class="icon-inbox"></i></td>
            <td><strong><a href="{% url "objectview" container=container.name %}" class="block">{{container.name}}</a></strong></td>
    	    <td class="hidden-phone">{{container.count}}</td>
    	    <td class="hidden-phone">{{container.bytes|filesizeformat}}</td>

            <td>
                <div class="dropdown pull-right">
                    <a class="dropdown-toggle btn btn-mini btn-danger" data-toggle="dropdown"><i class="icon-chevron-down icon-white"></i></a>
                    <ul class="dropdown-menu">
                        {% url "edit_acl" container=container.name as edit_acl_url %}
                        {% if edit_acl_url %}
                            <li><a href="{{ edit_acl_url }}"><i class="icon-user"></i> {% trans 'Sharing' %}</a></li>
                            <li class="divider" />
                        {% endif %}
 
                        <li>
                            <a href="{% url "delete_container" container=container.name %}" onclick="return confirm('{% trans 'Delete container' %} {{container.name}}?');">
                                <i class="icon-trash"></i> {% trans 'Delete container' %}
                            </a>
                        </li>
                    </ul>
                </div>
            </td>

            </tr> 

        {% empty %}
        <tr>
            <td colspan="5">
            <strong><center>{% trans 'There are no containers in this account yet. Create a new container by clicking the red button.' %}<center></strong>
            </td>
        </tr> 
 
        {% endfor %}
        </tbody> 
       
        <tfoot>
            <tr>
                <th colspan="5" class="center">
                    {{account_stat.x_account_bytes_used|filesizeformat}} 
                    {% if account_stat.x_account_meta_quota_bytes %}
                        {% trans 'of' %}
                        {{account_stat.x_account_meta_quota_bytes|filesizeformat}} 
                    {% endif %}
                    {% trans 'used' %}
                </th>
            </tr>
        </tfoot>
{'fraction_non_alphanumeric': 0.16748378934050293, 'fraction_numerical': 0.002530444409299383, 'mean_word_length': 1.4211332312404288, 'pattern_counts': {'":': 0, '<': 165, '<?xml version=': 0, '>': 165, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3858100', 'n_tokens_mistral': 1897, 'n_tokens_neox': 1685, 'n_words': 370}