Skip to content

Commit

Permalink
Fix the information bubble above the normal albums (#3833)
Browse files Browse the repository at this point in the history
* Fix the information bubble above the normal albums

* Remove unnecessary context from view and unnecessary messages
  • Loading branch information
T8902 authored Nov 13, 2024
1 parent 2bb6a80 commit 3851a3a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 17 deletions.
9 changes: 0 additions & 9 deletions website/photos/templates/photos/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@
Some of your reference faces have been rejected. <a style="text-decoration: underline; color:white" href="{% url 'facedetection:reference-faces' %}">Please delete them and upload new ones.</a>
</div>
</div>
{% elif has_processing_reference_faces %}
<div class="col-md-12">
{% alert "info" "Some of your reference faces have not been processed yet. Come back later." dismissible=False %}
</div>
{% elif has_reference_faces and not has_processing_reference_faces and not photos %}
<div class="col-md-12">
{% alert "info" "You haven't been recognized on any photos (yet)." dismissible=False %}
</div>
{% else %}
{% endif %}
</div>
<div class="d-flex flex-wrap col-12 search-form form-inline d-flex align-items-center justify-content-space-between gap-3">
Expand Down
8 changes: 0 additions & 8 deletions website/photos/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,6 @@ def get_context_data(self, **kwargs):
context["keywords"] = self.keywords
fetch_thumbnails([x.cover.file for x in context["object_list"] if x.cover])

context[
"has_processing_reference_faces"
] = self.request.member.reference_faces.filter(
status=ReferenceFace.Status.PROCESSING,
marked_for_deletion_at__isnull=True,
).exists()

context[
"has_rejected_reference_faces"
] = self.request.member.reference_faces.filter(
Expand All @@ -64,7 +57,6 @@ def get_context_data(self, **kwargs):
context["has_reference_faces"] = self.request.member.reference_faces.filter(
marked_for_deletion_at__isnull=True
).exists()

return context


Expand Down

0 comments on commit 3851a3a

Please sign in to comment.