core: fix impersonation notice being shown twice
This commit is contained in:
parent
2a50e36027
commit
d97b2bf503
|
@ -1,14 +0,0 @@
|
||||||
{% extends "base/page.html" %}
|
|
||||||
|
|
||||||
{% load static %}
|
|
||||||
{% load i18n %}
|
|
||||||
|
|
||||||
{% load passbook_is_active %}
|
|
||||||
{% load passbook_utils %}
|
|
||||||
|
|
||||||
{% block page_content %}
|
|
||||||
<main role="main" class="pf-c-page__main" tabindex="-1" id="main-content">
|
|
||||||
{% block content %}
|
|
||||||
{% endblock %}
|
|
||||||
</main>
|
|
||||||
{% endblock %}
|
|
|
@ -1,65 +1,53 @@
|
||||||
{% extends "overview/base.html" %}
|
|
||||||
|
|
||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
|
|
||||||
{% block head %}
|
<main role="main" class="pf-c-page__main" tabindex="-1" id="main-content">
|
||||||
{{ block.super }}
|
<section class="pf-c-page__main-section pf-m-light">
|
||||||
<style>
|
<div class="pf-c-content">
|
||||||
img.app-icon {
|
<h1>
|
||||||
max-height: 72px;
|
<i class="pf-icon pf-icon-applications"></i>
|
||||||
width: auto !important;
|
{% trans 'Applications' %}
|
||||||
}
|
</h1>
|
||||||
</style>
|
</div>
|
||||||
{% endblock %}
|
</section>
|
||||||
|
<section class="pf-c-page__main-section">
|
||||||
{% block content %}
|
{% if applications %}
|
||||||
<section class="pf-c-page__main-section pf-m-light">
|
<div class="pf-l-gallery pf-m-gutter">
|
||||||
<div class="pf-c-content">
|
{% for app in applications %}
|
||||||
<h1>
|
<a href="{{ app.get_launch_url }}" class="pf-c-card pf-m-hoverable pf-m-compact">
|
||||||
<i class="pf-icon pf-icon-applications"></i>
|
<div class="pf-c-card__header">
|
||||||
{% trans 'Applications' %}
|
{% if not app.meta_icon_url %}
|
||||||
</h1>
|
<i class="pf-icon pf-icon-arrow"></i>
|
||||||
</div>
|
{% else %}
|
||||||
</section>
|
<img class="app-icon pf-c-avatar" src="{{ app.meta_icon_url }}" alt="{% trans 'Application Icon' %}">
|
||||||
<section class="pf-c-page__main-section">
|
{% endif %}
|
||||||
{% if applications %}
|
</div>
|
||||||
<div class="pf-l-gallery pf-m-gutter">
|
<div class="pf-c-card__title">
|
||||||
{% for app in applications %}
|
<p id="card-1-check-label">{{ app.name }}</p>
|
||||||
<a href="{{ app.get_launch_url }}" class="pf-c-card pf-m-hoverable pf-m-compact">
|
<div class="pf-c-content">
|
||||||
<div class="pf-c-card__header">
|
<small>{{ app.meta_publisher }}</small>
|
||||||
{% if not app.meta_icon_url %}
|
</div>
|
||||||
<i class="pf-icon pf-icon-arrow"></i>
|
</div>
|
||||||
{% else %}
|
<div class="pf-c-card__body">
|
||||||
<img class="app-icon pf-c-avatar" src="{{ app.meta_icon_url }}" alt="{% trans 'Application Icon' %}">
|
{% trans app.meta_description|truncatewords:35 %}
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
{% endfor %}
|
||||||
|
</div>
|
||||||
|
{% else %}
|
||||||
|
<div class="pf-c-empty-state pf-m-full-height">
|
||||||
|
<div class="pf-c-empty-state__content">
|
||||||
|
<i class="fas fa-cubes pf-c-empty-state__icon" aria-hidden="true"></i>
|
||||||
|
<h1 class="pf-c-title pf-m-lg">{% trans 'No Applications available.' %}</h1>
|
||||||
|
<div class="pf-c-empty-state__body">
|
||||||
|
{% trans "Either no applications are defined, or you don't have access to any." %}
|
||||||
|
</div>
|
||||||
|
{% if perms.passbook_core.add_application %}
|
||||||
|
<a href="{% url 'passbook_admin:application-create' %}" class="pf-c-button pf-m-primary" type="button">
|
||||||
|
{% trans 'Create Application' %}
|
||||||
|
</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
<div class="pf-c-card__title">
|
|
||||||
<p id="card-1-check-label">{{ app.name }}</p>
|
|
||||||
<div class="pf-c-content">
|
|
||||||
<small>{{ app.meta_publisher }}</small>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="pf-c-card__body">
|
|
||||||
{% trans app.meta_description|truncatewords:35 %}
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
{% endfor %}
|
|
||||||
</div>
|
|
||||||
{% else %}
|
|
||||||
<div class="pf-c-empty-state pf-m-full-height">
|
|
||||||
<div class="pf-c-empty-state__content">
|
|
||||||
<i class="fas fa-cubes pf-c-empty-state__icon" aria-hidden="true"></i>
|
|
||||||
<h1 class="pf-c-title pf-m-lg">{% trans 'No Applications available.' %}</h1>
|
|
||||||
<div class="pf-c-empty-state__body">
|
|
||||||
{% trans "Either no applications are defined, or you don't have access to any." %}
|
|
||||||
</div>
|
|
||||||
{% if perms.passbook_core.add_application %}
|
|
||||||
<a href="{% url 'passbook_admin:application-create' %}" class="pf-c-button pf-m-primary" type="button">
|
|
||||||
{% trans 'Create Application' %}
|
|
||||||
</a>
|
|
||||||
{% endif %}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
{% endif %}
|
||||||
{% endif %}
|
</section>
|
||||||
</section>
|
</main>
|
||||||
{% endblock %}
|
|
||||||
|
|
Reference in a new issue