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

Improve toolbar in change list if django-import-export is not installed #116

Closed
dellsystem opened this issue Dec 24, 2024 · 1 comment · Fixed by #117
Closed

Improve toolbar in change list if django-import-export is not installed #116

dellsystem opened this issue Dec 24, 2024 · 1 comment · Fixed by #117

Comments

@dellsystem
Copy link

dellsystem commented Dec 24, 2024

This might be a niche case, but I'm using django-semantic-admin alongside django-reversion, and there's a minor cosmetic issue that occurs in the toolbar at the top of the change list page, because of these lines in semantic_admin/templates/admin/change_list.html:

      {% if not has_import_permission %}
        <div class="two wide field" style="margin-bottom: 0;"></div>
      {% endif %}
      {% if not has_export_permission %}
        <div class="two wide field" style="margin-bottom: 0;"></div>
      {% endif %}

What this ends up doing for my setup is it takes up space that can't be used by other buttons, as in the screenshot below:

image

I wonder if there's a way to not have those empty fields show up, especially if the library isn't installed? I was able to find a workaround by overriding the template file with my own version that just cuts out those lines, but it would be nice if this was built in!

Here's what I want it to look like:

image

Thanks @globophobe!

@globophobe
Copy link
Owner

Thankx for the bug report. Will fix next release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants