Compare commits
No commits in common. "b6e82256c0c9b14c56778dd8421611b095b23589" and "1c84db947c0b82356c701005de350f5fa82762d5" have entirely different histories.
b6e82256c0
...
1c84db947c
|
@ -291,12 +291,6 @@ def get_transaction_documents(transaction_id):
|
||||||
|
|
||||||
@app.route('/transaction/<int:id>')
|
@app.route('/transaction/<int:id>')
|
||||||
def view_transaction(id):
|
def view_transaction(id):
|
||||||
"""
|
|
||||||
Get Source (Either homepage or pending page)
|
|
||||||
"""
|
|
||||||
|
|
||||||
source = request.args.get("src")
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
View a transaction
|
View a transaction
|
||||||
"""
|
"""
|
||||||
|
@ -337,7 +331,7 @@ def view_transaction(id):
|
||||||
if transaction is None:
|
if transaction is None:
|
||||||
abort(404)
|
abort(404)
|
||||||
|
|
||||||
return render_template('view_transaction.html', transaction=transaction, documents=documents, prev_id=prev_id, next_id=next_id, version=VERSION, source = source)
|
return render_template('view_transaction.html', transaction=transaction, documents=documents, prev_id=prev_id, next_id=next_id, version=VERSION)
|
||||||
|
|
||||||
@app.route('/document/<int:document_id>')
|
@app.route('/document/<int:document_id>')
|
||||||
def view_document(document_id):
|
def view_document(document_id):
|
||||||
|
|
|
@ -3,6 +3,8 @@
|
||||||
/* System font stack */
|
/* System font stack */
|
||||||
body {
|
body {
|
||||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
||||||
|
padding-top: 20px;
|
||||||
|
padding-bottom: 20px;
|
||||||
color: #333333; /* Improved text contrast */
|
color: #333333; /* Improved text contrast */
|
||||||
line-height: 1.5; /* Improved readability */
|
line-height: 1.5; /* Improved readability */
|
||||||
font-size: 16px; /* Base font size for better readability */
|
font-size: 16px; /* Base font size for better readability */
|
||||||
|
@ -27,16 +29,8 @@ body {
|
||||||
|
|
||||||
/* Header styles */
|
/* Header styles */
|
||||||
.header {
|
.header {
|
||||||
margin-left: -50vw;
|
|
||||||
margin-right: -50vw;
|
|
||||||
border-bottom: 1px solid #d0d0d0;
|
border-bottom: 1px solid #d0d0d0;
|
||||||
margin-bottom: 30px;
|
margin-bottom: 30px;
|
||||||
background-color: var(--ploughshares-blue) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header > div {
|
|
||||||
max-width: 1320px;
|
|
||||||
margin: auto;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.header h3 {
|
.header h3 {
|
||||||
|
@ -64,10 +58,6 @@ body {
|
||||||
box-shadow: 0 0 0 0.2rem rgba(74, 122, 171, 0.25);
|
box-shadow: 0 0 0 0.2rem rgba(74, 122, 171, 0.25);
|
||||||
}
|
}
|
||||||
|
|
||||||
#pending-count-btn {
|
|
||||||
margin-left: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Improved form labels for accessibility */
|
/* Improved form labels for accessibility */
|
||||||
label {
|
label {
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
@ -94,18 +84,15 @@ label {
|
||||||
/* Logo styles */
|
/* Logo styles */
|
||||||
.logo-container {
|
.logo-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo-container div {
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-brand img {
|
.navbar-brand img {
|
||||||
max-height: 60px;
|
max-height: 40px;
|
||||||
width: auto;
|
width: auto;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
|
/* Improved logo contrast with background */
|
||||||
|
background-color: white;
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
|
@ -216,16 +203,7 @@ a:focus, button:focus, input:focus, select:focus, textarea:focus, [tabindex]:foc
|
||||||
/* Navbar styles */
|
/* Navbar styles */
|
||||||
.navbar {
|
.navbar {
|
||||||
background-color: var(--ploughshares-blue) !important;
|
background-color: var(--ploughshares-blue) !important;
|
||||||
padding: 20px 10px 20px 10px;
|
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-brand {
|
|
||||||
transition: opacity 0.5s ease-in-out ;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-brand:hover {
|
|
||||||
text-decoration: none;
|
|
||||||
opacity: 80%;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar-light .navbar-brand {
|
.navbar-light .navbar-brand {
|
||||||
|
@ -276,8 +254,9 @@ a:focus, button:focus, input:focus, select:focus, textarea:focus, [tabindex]:foc
|
||||||
}
|
}
|
||||||
|
|
||||||
.table th {
|
.table th {
|
||||||
|
background-color: var(--ploughshares-blue);
|
||||||
|
color: white;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 18px;
|
|
||||||
border-bottom: 2px solid var(--ploughshares-dark-blue);
|
border-bottom: 2px solid var(--ploughshares-dark-blue);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 438 KiB |
|
@ -12,13 +12,13 @@
|
||||||
<link rel="stylesheet" href="{{ url_for('static', filename='css/custom.css') }}">
|
<link rel="stylesheet" href="{{ url_for('static', filename='css/custom.css') }}">
|
||||||
<link rel="stylesheet" href="{{ url_for('static', filename='css/hotkeys.css') }}">
|
<link rel="stylesheet" href="{{ url_for('static', filename='css/hotkeys.css') }}">
|
||||||
<style>
|
<style>
|
||||||
.container {
|
.navbar-brand img {
|
||||||
display: flex;
|
max-height: 40px;
|
||||||
flex-direction: column;
|
margin-right: 10px;
|
||||||
min-height: 100vh;
|
|
||||||
}
|
}
|
||||||
.content {
|
.logo-container {
|
||||||
flex: 1;
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
@ -28,47 +28,46 @@
|
||||||
|
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<header class="header clearfix">
|
<header class="header clearfix">
|
||||||
<div>
|
<nav class="navbar navbar-expand-lg navbar-light bg-light">
|
||||||
<nav class="navbar navbar-expand-lg navbar-light bg-light">
|
<div class="container-fluid">
|
||||||
<div class="container-fluid">
|
<a class="navbar-brand" href="{{ url_for('index') }}" aria-label="Project Ploughshares Home">
|
||||||
<a class="navbar-brand" href="{{ url_for('index') }}" aria-label="Project Ploughshares Home">
|
<div class="logo-container">
|
||||||
<div class="logo-container">
|
<img src="{{ url_for('static', filename='img/logo.png') }}" alt="Project Ploughshares Logo" width="180" height="40">
|
||||||
<img src="{{ url_for('static', filename='img/logo-light.png') }}" alt="Project Ploughshares Logo">
|
<span class="d-none d-md-inline">Transaction Management System</span>
|
||||||
<div class="d-none d-md-inline">Transaction Management System</div>
|
</div>
|
||||||
</div>
|
</a>
|
||||||
</a>
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
<span class="navbar-toggler-icon"></span>
|
||||||
<span class="navbar-toggler-icon"></span>
|
</button>
|
||||||
</button>
|
<div class="collapse navbar-collapse" id="navbarNav">
|
||||||
<div class="collapse navbar-collapse" id="navbarNav">
|
<ul class="navbar-nav ms-auto">
|
||||||
<ul class="navbar-nav ms-auto">
|
<li class="nav-item">
|
||||||
<li class="nav-item">
|
<a class="nav-link" href="{{ url_for('index') }}" aria-current="{% if request.endpoint == 'index' %}page{% endif %}">
|
||||||
<a class="nav-link" href="{{ url_for('index') }}" aria-current="{% if request.endpoint == 'index' %}page{% endif %}">
|
<i class="bi bi-house-door" aria-hidden="true"></i> Home
|
||||||
<i class="bi bi-house-door" aria-hidden="true"></i> Home
|
</a>
|
||||||
</a>
|
</li>
|
||||||
</li>
|
<li class="nav-item">
|
||||||
<li class="nav-item">
|
<a class="nav-link" href="{{ url_for('create_transaction') }}" aria-current="{% if request.endpoint == 'create_transaction' %}page{% endif %}">
|
||||||
<a class="nav-link" href="{{ url_for('create_transaction') }}" aria-current="{% if request.endpoint == 'create_transaction' %}page{% endif %}">
|
<i class="bi bi-plus-circle" aria-hidden="true"></i> New Transaction
|
||||||
<i class="bi bi-plus-circle" aria-hidden="true"></i> New Transaction
|
</a>
|
||||||
</a>
|
</li>
|
||||||
</li>
|
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link" href="{{ url_for('pending_approval') }}" aria-current="{% if request.endpoint == 'pending_approval' %}page{% endif %}">
|
<a class="nav-link" href="{{ url_for('pending_approval') }}" aria-current="{% if request.endpoint == 'pending_approval' %}page{% endif %}">
|
||||||
<i class="bi bi-clock-history" aria-hidden="true"></i> Pending
|
<i class="bi bi-clock-history" aria-hidden="true"></i> Pending Approval
|
||||||
<span class="badge bg-warning rounded-pill" id="pending-count"></span>
|
<span class="badge bg-warning rounded-pill" id="pending-count"></span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link" href="{{ url_for('api_docs') }}" aria-current="{% if request.endpoint == 'api_docs' %}page{% endif %}">
|
<a class="nav-link" href="{{ url_for('api_docs') }}" aria-current="{% if request.endpoint == 'api_docs' %}page{% endif %}">
|
||||||
<i class="bi bi-file-earmark-text" aria-hidden="true"></i> API Docs
|
<i class="bi bi-file-earmark-text" aria-hidden="true"></i> API Documentation
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</div>
|
||||||
</div>
|
</nav>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
{% with messages = get_flashed_messages(with_categories=true) %}
|
{% with messages = get_flashed_messages(with_categories=true) %}
|
||||||
{% if messages %}
|
{% if messages %}
|
||||||
<div class="alert-container" role="alert">
|
<div class="alert-container" role="alert">
|
||||||
|
|
|
@ -7,18 +7,18 @@
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="card-header d-flex justify-content-between align-items-center">
|
<div class="card-header d-flex justify-content-between align-items-center">
|
||||||
<h2>Transactions</h2>
|
<h2>Transactions</h2>
|
||||||
<div class="d-flex gap-2 align-items-center">
|
<div class="d-flex gap-2">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
<input type="text" id="searchInput" class="form-control" placeholder="Search transactions..." aria-label="Search transactions">
|
<input type="text" id="searchInput" class="form-control" placeholder="Search transactions..." aria-label="Search transactions">
|
||||||
<button class="btn btn-outline-secondary" type="button" id="searchButton" title="Search (F)">
|
<button class="btn btn-outline-secondary" type="button" id="searchButton" title="Search (F)">
|
||||||
<i class="bi bi-search"></i>
|
<i class="bi bi-search"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<a href="{{ url_for('pending_approval') }}" class="btn btn-warning d-flex" title="Pending Approval (P)">
|
<a href="{{ url_for('pending_approval') }}" class="btn btn-warning" title="Pending Approval (P)">
|
||||||
<i class="bi bi-clock-history"></i> <span class="badge bg-light text-dark" id="pending-count-btn"></span>
|
<i class="bi bi-clock-history"></i> <span class="d-none d-md-inline">Pending</span> <span class="badge bg-light text-dark" id="pending-count-btn"></span>
|
||||||
</a>
|
</a>
|
||||||
<a href="{{ url_for('create_transaction') }}" class="btn btn-success" title="New Transaction (N)">
|
<a href="{{ url_for('create_transaction') }}" class="btn btn-success" title="New Transaction (N)">
|
||||||
<i class="bi bi-plus-lg"></i> <span class="d-md-none">New</span>
|
<i class="bi bi-plus-lg"></i> <span class="d-none d-md-inline">New Transaction</span> <span class="d-md-none">New</span> <span class="d-none d-md-inline">(N)</span>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<div class="btn-group" role="group">
|
<div class="btn-group" role="group">
|
||||||
<a href="{{ url_for('view_transaction', id=transaction['id'], src='pending') }}" class="btn btn-sm btn-info" aria-label="View transaction {{ transaction['id'] }}" title="View ({{ loop.index if loop.index < 10 else '' }})">
|
<a href="{{ url_for('view_transaction', id=transaction['id']) }}" class="btn btn-sm btn-info" aria-label="View transaction {{ transaction['id'] }}" title="View ({{ loop.index if loop.index < 10 else '' }})">
|
||||||
<i class="bi bi-eye"></i>{% if loop.index < 10 %} <span class="badge bg-light text-dark">{{ loop.index }}</span>{% endif %}
|
<i class="bi bi-eye"></i>{% if loop.index < 10 %} <span class="badge bg-light text-dark">{{ loop.index }}</span>{% endif %}
|
||||||
</a>
|
</a>
|
||||||
<a href="{{ url_for('update_transaction', id=transaction['id']) }}" class="btn btn-sm btn-warning" aria-label="Edit transaction {{ transaction['id'] }}">
|
<a href="{{ url_for('update_transaction', id=transaction['id']) }}" class="btn btn-sm btn-warning" aria-label="Edit transaction {{ transaction['id'] }}">
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
<a href="{{ url_for('update_transaction', id=transaction['id']) }}" class="btn btn-warning" title="Edit Transaction (E)">
|
<a href="{{ url_for('update_transaction', id=transaction['id']) }}" class="btn btn-warning" title="Edit Transaction (E)">
|
||||||
<i class="bi bi-pencil"></i> Edit <span class="d-none d-md-inline">(E)</span>
|
<i class="bi bi-pencil"></i> Edit <span class="d-none d-md-inline">(E)</span>
|
||||||
</a>
|
</a>
|
||||||
<a href="{{ url_for('pending_approval') if (source == 'pending') else url_for('index') }}" class="btn btn-secondary" title="Back to List (B)">
|
<a href="{{ url_for('index') }}" class="btn btn-secondary" title="Back to List (B)">
|
||||||
<i class="bi bi-arrow-left"></i> Back to List <span class="d-none d-md-inline">(B)</span>
|
<i class="bi bi-arrow-left"></i> Back to List <span class="d-none d-md-inline">(B)</span>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue