salvagedb_web/templates/database.html

85 lines
2.9 KiB
HTML

{% extends "head.html" %}
{% block content %}
<div class="container">
<div class="hero-unit">
<h1>Buying a Used Car? Check it!</h1>
<br>
<p><a href="https://www.salvagedb.com/" title="Salvagedb.com" rel="nofollow">Salvagedb.com</a> provides
information about salvage or junk vehicles; damage from hail, flood or fire; mileage discrepancies or
odometer rollback; and gray market vehicles. We do not claim that the car got in our databank has salvage
title, but the fact that it has been damaged for sure. Our site helps people avoid buying a damaged vehicle
in the past.
</p>
</div>
<br><br>
<div class="table-container" style="display: flex; justify-content: center;">
<table id="hor-minimalist-a" summary="Salvage cars;Database page 1">
<thead>
<tr>
<th>VIN</th>
<th>Make</th>
<th>Model</th>
<th>Year</th>
</tr>
</thead>
<tbody>
{% for row in pg %}
<tr>
<td><a href="/detail/{{ row[1] }}.html">{{ row[1] }}</a></td>
<td>{{ row[2] }}</td>
<td>{{ row[3] }}</td>
<td>{{ row[4] }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<br><br>
<div class="pagination-container">
<div class="pagination">
{% if cur_page > 1 %}
<a class="btn" href="/database/page1.html">First</a>
<a class="btn" href="/database/page{{cur_page-1}}.html">Prev</a>
{% endif %}
{% if cur_page > 3 %}
<span class="btn disabled">...</span>
{% endif %}
{% set start_page = cur_page - 2 %}
{% if start_page < 1 %}
{% set start_page = 1 %}
{% endif %}
{% set end_page = cur_page + 2 %}
{% if end_page > max_page %}
{% set end_page = max_page %}
{% endif %}
{% for page in range(start_page, end_page + 1) %}
{% if page == cur_page %}
<button class="btn active">{{page}}</button>
{% else %}
<a class="btn" href="/database/page{{page}}.html">{{page}}</a>
{% endif %}
{% endfor %}
{% if cur_page < max_page-2 %}
<span class="btn disabled">...</span>
{% endif %}
{% if cur_page < max_page %}
<a class="btn" href="/database/page{{cur_page+1}}.html">Next</a>
<a class="btn" href="/database/page{{max_page}}.html">Last</a>
{% endif %}
</div>
</div>
</div>
<br>
<hr>
{% endblock %}