Deprioritize closed
This commit is contained in:
parent
2cc5bc7765
commit
b8cc05e0ab
3 changed files with 13 additions and 6 deletions
|
@ -55,7 +55,7 @@ def index():
|
|||
break
|
||||
|
||||
# Sort inquiries - unread first, then by original position (recency)
|
||||
inquiries_with_data.sort(key=lambda x: (0 if x['is_unread'] else 1, x['position']))
|
||||
inquiries_with_data.sort(key=lambda x: (1 if x['inquiry'].is_closed else 0, 0 if x['is_unread'] else 1, x['position']))
|
||||
|
||||
return render_template('create_inquiry.html', recent_inquiries=inquiries_with_data)
|
||||
|
||||
|
|
|
@ -10,7 +10,6 @@ body {
|
|||
a {
|
||||
color: #6da8ff;
|
||||
text-decoration: none;
|
||||
transition: color 0.2s ease;
|
||||
}
|
||||
a:hover {
|
||||
color: #8fc0ff;
|
||||
|
@ -137,7 +136,6 @@ th {
|
|||
text-decoration: none;
|
||||
display: inline-block;
|
||||
font-weight: bold;
|
||||
transition: background-color 0.3s;
|
||||
}
|
||||
.btn-primary:hover {
|
||||
background-color: #2d6c30;
|
||||
|
@ -200,8 +198,17 @@ th {
|
|||
padding: 1rem;
|
||||
background-color: #333;
|
||||
border-radius: 4px;
|
||||
transition: background-color 0.2s ease;
|
||||
border-left: 3px solid transparent;
|
||||
border-left: 3px solid #070;
|
||||
}
|
||||
|
||||
/* Closed inquiry styling */
|
||||
.inquiry-item.closed {
|
||||
filter: grayscale(70%);
|
||||
background-color: #2a2a2a;
|
||||
}
|
||||
|
||||
.inquiry-item.closed:hover {
|
||||
background-color: #303030;
|
||||
}
|
||||
|
||||
.inquiry-item:hover {
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
{% for item in recent_inquiries %}
|
||||
<li>
|
||||
<a href="{{ url_for('inquiry', inquiry_id=item.inquiry.id) }}">
|
||||
<div class="inquiry-item {% if item.is_unread %}unread{% endif %}">
|
||||
<div class="inquiry-item {% if item.is_unread %}unread{% endif %} {% if item.inquiry.is_closed %}closed{% endif %}">
|
||||
<div class="inquiry-header">
|
||||
<span class="inquiry-id">Inquiry #{{ item.inquiry.id[:8] }}</span>
|
||||
<span class="inquiry-status {% if item.inquiry.is_closed %}closed{% else %}open{% endif %}">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue