Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cypress/e2e/sign-in.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

describe('Sign-In Stories', function() {
beforeEach(() => {
cy.visit('/accounts/logout/?next=/');
cy.get('.user-auth--logout').click();
cy.clearCookies();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/support/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
// Cypress.Commands.overwrite("visit", (originalFn, url, options) => { ... })

Cypress.Commands.add('login', (username, password) => {
cy.visit('/accounts/logout/?next=/');
cy.get('.user-auth--logout').click();
cy.clearCookies();

cy.visit('http://localhost:8000/dashboard/');
Expand All @@ -52,4 +52,4 @@ Cypress.Commands.add('login_workspace', (userName) => {
// Navigate to the Sandbox Workspace
cy.get('[data-cy="workspace-title-link"]').click();
cy.title().should('equal', 'Sandbox Workspace – Locus Tempus');
});
});
26 changes: 16 additions & 10 deletions locustempus/templates/base.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@

<!DOCTYPE html>

<html lang="en">
<head>
<title>{% block title %}{% endblock %}{{ flatpage.title }} – Locus Tempus</title>
<title>{% block title %}{% endblock %}{{ flatpage.title }} – Locus Tempus</title>

<!-- Required meta tags -->
<meta charset="utf-8" />
Expand Down Expand Up @@ -165,11 +164,18 @@
</li>
{% endif %}
<li class="lt-list-item lt-list-item--caution border-top">
<a href="/accounts/logout/?next=/" class="d-flex align-items-center justify-content-start lt-list-item__link"
data-cy="sign-out">
<span class='lt-icons lt-list-item__icon' aria-hidden="true"><img src="{{STATIC_URL}}img/icon-sign-out.svg" alt="" /></span>
<span class="lt-list-item__primary-text"><b>Sign out</b></span>
</a>

<form action="/accounts/logout/?next=/" method="post">
{% csrf_token %}
<button
type="submit"
class="user-auth--logout d-flex align-items-center justify-content-start lt-list-item__link"
data-cy="sign-out">
<span class='lt-icons lt-list-item__icon' aria-hidden="true"><img src="{{STATIC_URL}}img/icon-sign-out.svg" alt="" /></span>
<span class="lt-list-item__primary-text"><strong>Sign out</strong></span>
</button>
</form>

</li>
</ul>
</div>
Expand Down Expand Up @@ -211,7 +217,7 @@
{% endif %}
{% endblock %}

<!-- Dashboard breadcrumb and navigation bar -->
<!-- Dashboard breadcrumb and navigation bar -->
{% if breadcrumb %}
<div class="nav-dashboard">
<div class="lt-breadcrumb">
Expand All @@ -230,7 +236,7 @@
{% block page_actions %}{% endblock %}
</div>
{% endif %}
<!-- End Dashboard breadcrumb and navigation bar -->
<!-- End Dashboard breadcrumb and navigation bar -->

<!-- Begin content block -->
{% block content %}{% endblock %}
Expand All @@ -251,7 +257,7 @@
<a href="/contact/" title="Contact us">Contact Us</a>
</li>
</ul>

<p class="lt-license">Locus Tempus open-source code is on <a itemprop="license" rel="license noopener noreferrer" href="https://github.com/ccnmtl/locustempus">Github</a> with <a itemprop="license" rel="license noopener noreferrer" href="https://www.gnu.org/licenses/gpl-3.0.en.html">GNU GPLv3</a> license.</p>


Expand Down
7 changes: 6 additions & 1 deletion locustempus/templates/base_design.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,12 @@
{% if request.user.is_anonymous %}
<a href="/accounts/login/?next=/" class="user-auth--login">Log in</a>
{% else %}
<a href="/accounts/logout/?next=/" class="user-auth--logout">Log out</a>
<form action="/accounts/logout/?next=/" method="post">
{% csrf_token %}
<button type="submit" class="user-auth--logout" title="Log out">
Log out
</button>
</form>
{% endif %}
{% endblock %}
</nav>
Expand Down
14 changes: 7 additions & 7 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Django>=4.2.14,<5
psycopg[binary]==3.3.0
Django>=5.2,<6
psycopg[binary]==3.3.2
backports.zoneinfo;python_version<"3.9"
asgiref==3.11.0
django-s3sign==0.5.1
Expand All @@ -23,7 +23,7 @@ beautifulsoup4==4.14.2
cssselect==1.3.0
lxml==6.0.0
fuzzywuzzy==0.18.0
sure==2.0.0
sure==3.0a2
pyasn1==0.6.0
cffi==2.0.0
cryptography<46.0.4 # pyOpenSSL
Expand Down Expand Up @@ -72,12 +72,12 @@ django-impersonate==1.9.1
gunicorn==23.0.0
django-infranil==1.1.0
django-flatblocks==1.0.0
django-storages==1.14.2
django-storages==1.14.6

djangorestframework==3.16.0
rest-framework-generic-relations==2.2.0

ctlsettings==0.4.2
ctlsettings==0.4.5

django-reversion==6.0.0
text_unidecode==1.3
Expand All @@ -94,7 +94,7 @@ pyparsing==3.2.1
edtf==5.0.0 # pyup: <4.0.0

pbr==7.0.0 # bandit
pyyaml==6.0.1 # bandit
pyyaml==6.0.3 # bandit
stevedore==5.6.0 # bandit
rich==14.2.0 # bandit
bandit==1.9.1
Expand All @@ -117,4 +117,4 @@ distro==1.9.0
webencodings==0.5.1 # django-markdownify
tinycss2==1.5.0 # django-markdownify
bleach==6.3.0 # django-markdownify
django-markdownify==0.9.3
django-markdownify==0.9.6
Loading