Files
project-managment/templates/pages/finance/invoice_list.html
T
sankalp 001e6fac48 feat(templates): add core UItemplates for authentication and ticket management
New Features
- Added `templates/base.html` with Tailwind, HTMX, and project management title block.
- Introduced `templates/base/base.html` as a minimal fallback layout.
- Created `templates/components/navbar.html` with authenticated navigation menu.
- Implemented `templates/pages/accounts/login.html` for user authentication.
- Developed ticket management templates:
  - `templates/pages/tickets/ticket_list.html` for displaying tickets.
  - `templates/pages/tickets/ticket_form.html` for creating/editing tickets.

Enhancements
- Structured all new templates to inherit from the shared base layout.
- Integrated Tailwind CSS and HTMX via CDN for consistent styling and interactivity.
- Provided placeholder blocks for extra head and scripts to allow future extensions.

Bug Fixes- No bug fixes included in this commit.
2026-05-27 23:32:54 +05:45

32 lines
1.3 KiB
HTML

{% extends "base.html" %}
{% block title %}Invoices{% endblock %}
{% block content %}
<div class="flex justify-between items-center mb-4">
<h1 class="text-3xl font-bold">Invoices</h1>
{% if user.is_admin %}
<a href="{% url 'invoice_create' %}" class="btn btn-primary">New Invoice</a>
{% endif %}
</div>
<div class="overflow-x-auto">
<table class="table table-zebra">
<thead>
<tr><th>#</th><th>Project</th><th>Amount</th><th>Due Date</th><th>Status</th><th></th></tr>
</thead>
<tbody>
{% for invoice in invoices %}
<tr>
<td>{{ invoice.id }}</td>
<td>{{ invoice.project.name }}</td>
<td>${{ invoice.amount }}</td>
<td>{{ invoice.due_date }}</td>
<td><span class="badge badge-{% if invoice.status == 'paid' %}success{% elif invoice.status == 'overdue' %}error{% else %}warning{% endif %}">{{ invoice.get_status_display }}</span></td>
<td><a href="{% url 'invoice_detail' invoice.pk %}" class="btn btn-sm btn-ghost">View</a></td>
</tr>
{% empty %}
<tr><td colspan="6" class="text-center">No invoices.</td></tr>
{% endfor %}
</tbody>
</table>
</div>
{% endblock %}