Skip to content

Commit

Permalink
Merge branch 'master' into stable/3.0.x
Browse files Browse the repository at this point in the history
  • Loading branch information
sehmaschine committed Mar 13, 2024
2 parents 24fe279 + 976506b commit 15393d4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion grappelli/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
# SWITCH_USER_ORIGINAL: Defines if a user is a valid target.
# Gets a user object and returns True/False.
SWITCH_USER_TARGET = getattr(settings, "GRAPPELLI_SWITCH_USER_TARGET", lambda original_user, user: user.is_staff and not user.is_superuser)
SWITCH_USER_REGEX = getattr(settings, "GRAPPELLI_SWITCH_USER_REGEX", "\d+")
SWITCH_USER_REGEX = getattr(settings, "GRAPPELLI_SWITCH_USER_REGEX", r"\d+")

# CLEAN INPUT TYPES
# Replaces input types: search, email, url, tel, number, range, date
Expand Down
1 change: 1 addition & 0 deletions grappelli/static/admin/js/admin/RelatedObjectLookups.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
}
// GRAPPELLI CUSTOM: element focus
elem.focus();
$(elem).trigger('change');
win.close();
}

Expand Down
4 changes: 2 additions & 2 deletions grappelli/templates/admin/delete_confirmation.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ <h2>{% blocktrans with escaped_object=object %}Are you sure you want to delete t
<div class="grp-module grp-submit-row grp-fixed-footer">
<ul>
{% url opts|admin_urlname:'change' object.pk|admin_urlquote as object_url %}
<li class="grp-float-left"><a href="{% add_preserved_filters object_url %}" class="grp-button grp-cancel-link">{% trans "Cancel" %}</a></li>
<li><input type="submit" value="{% trans "Yes, I'm sure" %}" class="grp-button grp-default" /></li>
<li class="grp-float-left"><a href="{% add_preserved_filters object_url %}" class="grp-button grp-cancel-link">{% trans "No, take me back" %}</a></li>
<li><input type="submit" value="{% trans "Yes, Im sure" %}" class="grp-button grp-default" /></li>
</ul>
<input type="hidden" name="post" value="yes" />
{% if is_popup %}<input type="hidden" name="{{ is_popup_var }}" value="1" />{% endif %}
Expand Down

0 comments on commit 15393d4

Please sign in to comment.