Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CKAN 2.10.1 small bug fixes #6177

Merged
merged 2 commits into from
Jan 6, 2024
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -179,9 +179,11 @@ function checkMfa() {

$(document).ready(function(){
const $loginForm = $('#hdx-login-form');
const $loginFormRequiredFields = $loginForm.find('input, select, textarea').filter('[required]');
$loginForm.submit(checkLockout);
$loginForm.find('input, select, textarea').filter('[required]').on('input change', requiredFieldsFormValidator);
$loginFormRequiredFields.on('input change focus', requiredFieldsFormValidator);
$("#field-login").change(checkMfa);
$loginFormRequiredFields.filter(() => this.value !== '').first().trigger('change');
//check cookies
const loginCookie = $.cookie("hdx_login");
const loginPopup = $("#loginPopup").length > 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,7 @@ $(document).ready(function(){
return false;
});

$recoverForm.find('input, select, textarea').filter('[required]').on('input change', requiredFieldsFormValidator);
const $recoverFormRequiredFields = $recoverForm.find('input, select, textarea').filter('[required]');
$recoverFormRequiredFields.on('input change', requiredFieldsFormValidator);
$recoverFormRequiredFields.filter(() => this.value !== '').first().trigger('change');
});
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@
<form action="" method="post" id="perform-reset-form">
{{ form.input("password1", id="field-password", label=_("Password"), type="password", value='', error='', attrs={'required': 'required', 'autocomplete': 'no', 'class': 'control-medium'}, classes=["mb-3"]) }}
{{ form.input("password2", id="field-confirm-password", label=_("Confirm"), type="password", value='', error='', attrs={'required': 'required', 'autocomplete': 'no', 'class': 'control-medium'}, classes=["mb-3"]) }}
{% for message in h.flash.pop_messages() | list %}
<div class="alert alert-warning fade show {{ message.category }}">
{% for category, message in h.get_flashed_messages(with_categories=true) %}
<div class="alert alert-dismissible fade show {{ category }}" role="alert">
{{ h.literal(message) }}
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
{% endfor %}
<button class="btn btn-primary btn-large" type="submit" disabled name="save">{{ _("Update Password") }}</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@
</div>
</div>
{% block error_section %}
{% for message in h.flash.pop_messages() | list %}
<div class="alert alert-warning fade show {{ message.category }}">
{% for category, message in h.get_flashed_messages(with_categories=true) %}
<div class="alert alert-dismissible fade show {{ category }}" role="alert">
{{ h.literal(message) }}
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
{% endfor %}
<div class="error-message" style="display: none;">
Expand Down
Loading