diff options
Diffstat (limited to 'app/dispatch/templates')
| -rw-r--r-- | app/dispatch/templates/dispatch/drivers/detail.html | 50 | ||||
| -rw-r--r-- | app/dispatch/templates/dispatch/nav.html | 1 |
2 files changed, 39 insertions, 12 deletions
diff --git a/app/dispatch/templates/dispatch/drivers/detail.html b/app/dispatch/templates/dispatch/drivers/detail.html index 21d2432..fc197b5 100644 --- a/app/dispatch/templates/dispatch/drivers/detail.html +++ b/app/dispatch/templates/dispatch/drivers/detail.html @@ -12,40 +12,66 @@ <div class="row"> <div class="col s12"> + <div class="right-align"> + <a class="btn orange" href="{% url 'invoice_generate' object.pk%}?date={{week_dates.start_date|date:"m/d/Y"}}">Generate Invoice For Listing</a> + </div> + </div> +</div> + +{% if not request.user.is_superuser %} +<div class="row"> + <div class="col s12"> <table> <thead> <tr> - <td>Number of Loads</td> - <td>Total Load cost</td> - <td>Average Load cost</td> + <td>Date</td> + <td>Description</td> + <td>Total</td> + <td></td> </tr> </thead> - <tr> - <td>{{stats.count}}</td> - <td>${{stats.sum}}</td> - <td>${{stats.average|stringformat:".3f"}}</td> - </tr> + <tbody> + {% for load in loads_nosplit %} + <tr> + <td>{{load.date}}</td> + <td>{{load.description}}</td> + <td>{{load.amount}}</td> + <td class="right-align"> + <a href="{% url 'load_detail' load.id %}" class="btn green"> + View + </a> + </td> + </tr> + {% endfor %} + </tbody> </table> </div> </div> - +{% endif %} <div class="row"> <div class="col s12"> <table> <thead> <tr> - <td>Date</td> - <td>Description</td> - <td>Total</td> + <td>Number of Loads</td> + <td>Average Load cost</td> + <td>Total Load cost</td> </tr> </thead> + <tr> + <td>{{stats.count}}</td> + <td>${{stats.average|stringformat:".3f"}}</td> + <td>${{stats.sum}}</td> + </tr> </table> </div> </div> + + <div class="row"> <div class="col s6 left-align"> <a href="{% url 'driver_detail' object.id %}?date={{week_dates.previous_week|date:"m/d/Y"}}" class="btn blue"><i class="material-icons left">arrow_back</i> Prev</a> diff --git a/app/dispatch/templates/dispatch/nav.html b/app/dispatch/templates/dispatch/nav.html index 20a2e83..532b2a9 100644 --- a/app/dispatch/templates/dispatch/nav.html +++ b/app/dispatch/templates/dispatch/nav.html @@ -3,6 +3,7 @@ {% if request.user.is_superuser %} <li><a href="{% url 'driver_list' %}">Drivers</a></li> <li><a href="{% url 'customer_list' %}">Customers</a></li> + <li><a href="{% url 'invoice_list' %}">Invoices</a></li> {% else %} <li><a href="{% url 'driver_detail' request.user.id %}">Summary</a> <li><a href="{% url 'driver_edit' request.user.id %}">My Account</a></li> |
