Skip to content

Commit

Permalink
Merge pull request #82 from OpenLXP/comp_migrations
Browse files Browse the repository at this point in the history
competency migration
  • Loading branch information
KarenAJ authored Oct 28, 2024
2 parents 8c90d36 + 2bb8fd9 commit ec45274
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 4 deletions.
14 changes: 14 additions & 0 deletions app/configurations/migrations/0010_merge_20241026_0049.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Generated by Django 4.2.16 on 2024-10-26 00:49

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('configurations', '0007_courseinformationmapping_course_time_and_more'),
('configurations', '0009_alter_xdsuiconfiguration_ui_logo'),
]

operations = [
]
6 changes: 6 additions & 0 deletions app/es_api/tests/test_views_unit.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,12 @@ def test_search_derived_with_reference(self):

@tag('unit')
class SearchCompetencyTests(APITestCase):

def setUp(self):
settings_manager = override_settings(SECURE_SSL_REDIRECT=False)
settings_manager.enable()
self.addCleanup(settings_manager.disable)

def test_search_competency_no_reference(self):
"""
Test that the /es-api/ endpoint sends an HTTP error when no
Expand Down
27 changes: 23 additions & 4 deletions app/static/admin_interface/css/admin-interface.css
Original file line number Diff line number Diff line change
Expand Up @@ -413,14 +413,19 @@
border-radius: var(--admin-interface-module-border-radius);
}

.admin-interface .module.filtered .changelist-filter-clear-container {
margin: 12px 0;
}

.admin-interface .module.filtered #changelist-filter h3#changelist-filter-clear {
margin-bottom: 0;
margin-top: 5px;
margin-bottom: 10px;
}

.admin-interface .module.filtered #changelist-filter .changelist-filter-clear a {
font-size: 13px;
font-size: 12px;
margin: .3em 0;
padding: 0 15px;
padding: 0 15px 0 32px;
}

.admin-interface .module.filtered #changelist-filter .changelist-filter-clear a:focus,
Expand All @@ -441,7 +446,8 @@
text-decoration: none;
}

.admin-interface.list-filter-highlight .module.filtered #changelist-filter h3.active {
.admin-interface.list-filter-highlight .module.filtered #changelist-filter h3.active,
.admin-interface.list-filter-highlight .module.filtered #changelist-filter summary.active {
font-weight: bold;
}

Expand Down Expand Up @@ -473,6 +479,19 @@
color: var(--admin-interface-generic-link-hover-color);
}

.admin-interface .module.filtered #changelist-filter a,
.admin-interface .module.filtered #changelist-filter a:link,
.admin-interface .module.filtered #changelist-filter a:visited {
color: var(--admin-interface-generic-link-color);
text-decoration: none;
}

.admin-interface .module.filtered #changelist-filter a:hover,
.admin-interface .module.filtered #changelist-filter a:active {
color: var(--admin-interface-generic-link-hover-color);
text-decoration: none;
}

/* begin fix issue #11 - Inline border bottom should not be rounded */
.admin-interface .module h2,
.admin-interface.dashboard .module caption,
Expand Down
3 changes: 3 additions & 0 deletions app/static/admin_interface/css/changelist.css
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,7 @@
.admin-interface #changelist #changelist-form table tbody th,
.admin-interface #changelist #changelist-form table tbody td {
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
max-width: min(400px, 30vw);
}
1 change: 1 addition & 0 deletions app/static/admin_interface/css/list-filter-dropdown.css
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ list-filter-dropdown
}

.admin-interface #changelist-filter h2 + .list-filter-dropdown,
.admin-interface #changelist-filter #changelist-filter-extra-actions + .list-filter-dropdown,
.admin-interface #changelist-filter .list-filter-dropdown + .list-filter-dropdown {
margin-top: 5px;
}
Expand Down
15 changes: 15 additions & 0 deletions app/static/admin_interface/css/list-filter.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@
}
}

.admin-interface .module.filtered #changelist-filter h2#changelist-filter-header {
margin-bottom: 0;
}

.admin-interface .module.filtered #changelist-filter h2#changelist-filter-header + details {
margin-top: 12px;
}

.admin-interface .module.filtered #changelist-filter h2 {
font-size: 11px;
padding: 10px 15px;
Expand All @@ -26,3 +34,10 @@
margin-top: 12px;
margin-bottom: 12px;
}

/* fix summary shift when expanding/collapsing list filter */
.admin-interface .module.filtered #changelist-filter details > summary::before {
display: inline-block;
width: 14px;
text-align: center;
}
9 changes: 9 additions & 0 deletions app/static/admin_interface/css/nav-sidebar.css
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,12 @@
max-width: calc(100% - 360px);
}
}

/* Hide the app element when all its models filtered-out (hidden) by quick-search. */
.admin-interface #nav-sidebar .module[class^="app-"]:has([class^="model-"][style="display: none;"]) {
display: none;
}

.admin-interface #nav-sidebar .module[class^="app-"]:has([class^="model-"]:not([style="display: none;"])) {
display: block !important;
}

0 comments on commit ec45274

Please sign in to comment.