Skip to content

Commit 295f8e9

Browse files
committed
Cleanup unnecessary files
1 parent 93c09aa commit 295f8e9

File tree

7 files changed

+42
-509
lines changed

7 files changed

+42
-509
lines changed

sde_collections/views.py

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -634,55 +634,6 @@ def get(self, request, *args, **kwargs):
634634
return render(request, "sde_collections/titles_and_errors_list.html", context)
635635

636636

637-
class BaseAffectedURLsListView(LoginRequiredMixin, ListView):
638-
"""
639-
Base view for displaying a list of URLs affected by a match pattern
640-
"""
641-
642-
template_name = "sde_collections/affected_urls.html"
643-
context_object_name = "affected_urls"
644-
pattern_model = None
645-
pattern_type = None
646-
647-
def get_queryset(self):
648-
self.pattern = self.pattern_model.objects.get(id=self.kwargs["id"])
649-
if self.kwargs["url_type"] == "delta":
650-
queryset = self.pattern.get_matching_delta_urls()
651-
elif self.kwargs["url_type"] == "curated":
652-
queryset = self.pattern.get_matching_curated_urls()
653-
return queryset
654-
655-
def get_context_data(self, **kwargs):
656-
context = super().get_context_data(**kwargs)
657-
context["pattern"] = self.pattern
658-
context["pattern_id"] = self.kwargs["id"]
659-
context["url_count"] = self.get_queryset().count()
660-
context["collection"] = self.pattern.collection
661-
context["pattern_type"] = self.pattern_type
662-
context["url_type"] = self.kwargs["url_type"]
663-
return context
664-
665-
666-
class ExcludePatternAffectedURLsListView(BaseAffectedURLsListView):
667-
pattern_model = DeltaExcludePattern
668-
pattern_type = "Exclude"
669-
670-
671-
class IncludePatternAffectedURLsListView(BaseAffectedURLsListView):
672-
pattern_model = DeltaIncludePattern
673-
pattern_type = "Include"
674-
675-
676-
class TitlePatternAffectedURLsListView(BaseAffectedURLsListView):
677-
pattern_model = DeltaTitlePattern
678-
pattern_type = "Title"
679-
680-
681-
class DocumentTypePatternAffectedURLsListView(BaseAffectedURLsListView):
682-
pattern_model = DeltaDocumentTypePattern
683-
pattern_type = "Document Type"
684-
685-
686637
class BaseAffectedURLsViewSet(CollectionFilterMixin, viewsets.ModelViewSet):
687638

688639
pattern_model = None

sde_indexing_helper/static/css/affected_urls.css

Lines changed: 0 additions & 275 deletions
This file was deleted.

sde_indexing_helper/static/css/delta_url_list.css

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,21 +453,42 @@ div.dt-container div.dt-paging ul.pagination {
453453
}
454454

455455
/* Specific styling for affected URLs modal only */
456+
#affectedURLsModal {
457+
padding: 0 !important;
458+
}
459+
456460
#affectedURLsModal .modal-dialog {
457461
max-width: 90%;
462+
height: auto;
458463
margin: 1.75rem auto;
459464
}
460465

461466
#affectedURLsModal .modal-content {
462467
background-color: #15232E;
463468
color: white;
464469
width: 100%;
470+
height: auto;
471+
max-height: 80vh;
472+
display: flex;
473+
flex-direction: column;
465474
}
466475

467476
#affectedURLsModal .modal-header {
468477
border-bottom: 1px solid #3F4A58;
478+
margin-bottom: 0px;
479+
}
480+
481+
#affectedURLsModal .modal-body {
482+
flex: 0 1 auto;
483+
overflow: auto;
484+
padding: 1rem;
469485
}
470486

471487
#affectedURLsModal .close {
472488
color: white;
473489
}
490+
491+
#affectedURLsModal .dataTables_wrapper {
492+
display: flex;
493+
flex-direction: column;
494+
}

0 commit comments

Comments
 (0)