82 lines
3.7 KiB
HTML
82 lines
3.7 KiB
HTML
{% extends 'base.html' %}
|
|
{% block title %}Homepage{% endblock title %}
|
|
|
|
{% block content %}
|
|
<main>
|
|
<div class="container mt-5">
|
|
{% if files %}
|
|
<div class="card">
|
|
<div class="card-header bg-primary text-white">
|
|
File available in static folder for upload
|
|
</div>
|
|
<div class="card-body">
|
|
<div class="table-responsive">
|
|
<table class="table table-bordered">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">Filename</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for file in files %}
|
|
<tr>
|
|
<th scope="row"><a href="{{url_for('upload_file', filename=file)}}">{{file}}</a></th>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% else %}
|
|
<div class="card">
|
|
<div class="card-header bg-primary text-white">
|
|
No files in the upload folder
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
<div class="card">
|
|
<div class="card-header bg-primary text-white">
|
|
Line Items
|
|
</div>
|
|
<div class="card-body">
|
|
<div class="table-responsive">
|
|
<table class="table table-bordered">
|
|
<thead>
|
|
<tr>
|
|
<th scope="col">ID</th>
|
|
<th scope="col">Parent LineItem ID</th>
|
|
<th scope="col">Amount</th>
|
|
<th scope="col">Currency Type</th>
|
|
<th scope="col">Vendor</th>
|
|
<th scope="col">Date</th>
|
|
<th scope="col">Confirmation Code</th>
|
|
<th scope="col">Note</th>
|
|
<th scope="col">Reassign Vendor</th>
|
|
<th scope="col">Split Line?</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for li in last_month_lines %}
|
|
<tr id="{{li[0].id}}-row">
|
|
<th scope="row">{{li[0].id}}</th>
|
|
<th scope="row">{{li[0].parent_line_item_id}}</th>
|
|
<th scope="row">{{li[0].amount}}</th>
|
|
<th scope="row">{{li[0].currency_type}}</th>
|
|
<th scope="row" id="vendor-line-{{li[0].id}}">{{li[0].get_vendor()[0]}}</th>
|
|
<th scope="row">{{li[0].date}}</th>
|
|
<th scope="row">{{li[0].confirmation_code}}</th>
|
|
<th scope="row">{{li[0].note}}</th>
|
|
<th scope="row"><button id="{{li[0].id}}" class="btn btn-primary reassign-button">Click to reassign vendor</button></th>
|
|
<th scope="row"><a class="btn btn-primary" href="#">Click to split line</a></th>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</main>
|
|
<script src="{{url_for('.static', filename='homepage.js')}}"></script>
|
|
{% endblock content %}
|