{% extends "users/base.html" %}
{% block title %}List of Database user{% endblock title %}
{% block content %}

<div class="card card-default">
      <div class="card-header">
        <h2>List of Database user</h2>
		
        

      </div>
    
   <div class="card-body">
   <div class="row">
  

	</div>
<div class="table-responsive">
    <table class="table table-bordered">
        <thead class="thead-light">
             <tr>
                <th>User</th>
                <th>Actions</th>
            </tr>
        </thead>
        <tbody id="domainTable">
            {% for userlist in userlists %}
            <tr>
                <td>{{ userlist }}</td>
                <td>
				<form action="{% url 'database_userlist' %}" method="post" style="display:inline;">
                        {% csrf_token %}
						<input type="hidden" id="dbuser" name="dbuser" class="form-control" value="{{ userlist }}">
                        <button type="submit" class="btn btn-danger btn-sm" onclick="return confirm('Are you sure you want to delete this user?');">Delete</button>
                    </form>
					<a href="{% url 'db_user_edit' userlist %}" class="btn btn-primary btn-sm">Manage</a>

                    
                </td>
            </tr>
            {% empty %}
            <tr>
                <td colspan="4" class="text-center">No domains found.</td>
            </tr>
            {% endfor %}
        </tbody>
    </table>
</div>
    <!-- No Results Message -->
    <div id="noResults" class="text-center text-danger" style="display:none;">No results found.</div>

</div>
</div>




{% endblock content %}

{% include "users/footer.html" %}