The second half of the superadministrator's job: not just who may do things, but
what they get to do that nobody else does.
**Identidad** is everything that used to be frozen in config.yaml — the name and
the one-line tagline in all three languages, the association's accounts
elsewhere, a public email, a city and street, a share picture and the footer
line. It commits data/site.yaml the way Marca commits data/brand.yaml.
Hugo cannot have config.yaml overridden by a data file, so the name and tagline
are read through two new partials that prefer the data file and fall back to the
config; every template showing either calls one, so they cannot drift. A site
with no data/site.yaml builds byte-for-byte what it built before — asserted by
building both ways and diffing with the stylesheet fingerprint normalised.
The contact fields are not decoration: they become ContactPoint and
PostalAddress in the Organization schema, which is what puts an association in a
local result rather than only a web one, and the social links become sameAs,
which is how an engine knows an Instagram account and this site are one body.
**Marca** grows a typeface and a roundness. Four system stacks — nothing
downloaded, which is deliberate and a GDPR matter — or an uploaded .woff2,
sniffed by its wOF2 signature, capped at 400 KB, named ahead of the old stack so
a font that fails to load leaves a readable site. The fold-out warning covers
missing accented glyphs, file size, synthesised bold, and licensing: a font is
software, a desktop licence is not a webfont licence, and that liability follows
the platform to every organisation it is installed for. SIL OFL and Apache-2.0
are named, with seven places to find them.
**Three tools.** Estado del sistema exercises the content token against the
repository rather than checking it is non-empty — "present" was never the
problem, a wrong scope broke publishing for three phases while looking fine —
and reports mail, backups, disk and every documented setting the container does
not have. It changes nothing on purpose. Registro de actividad records the dozen
acts that change who can do what; the actor is cleared and not cascaded on
erasure, and log() never raises, because an administrator who could not be
appointed because the note about it could not be saved is worse than a gap in
the notes. Biblioteca de medios lists every picture with the posts that use it
and, finally, shows the orphans — a picture whose post was deleted has stayed in
the repository, deployed and unreferenced, for the life of this site with no way
to see one.
Two bugs found by looking at the rendered pages rather than at the tests:
**Gestión had disappeared from the superadministrator's own navigation.**
base.html asked `g.member.role in ('owner', 'admin')`, right until a role
appeared above both. 622 tests passed while it was broken, because every one of
them signed in as an admin or below. The templates now call the same
`is_at_least` the handlers do, and test_navigation.py covers the tier above
admin — verified by reintroducing the tuple and watching it fail.
And the status screen counted the tombstone as a suspended member.
Migration 8 is plain ADD COLUMNs; `activity` and `site` are new tables, so
CREATE TABLE IF NOT EXISTS covers them with no step at all. The erase guard
caught both the moment they existed, which is that test doing its job.
627 tests pass. Hugo builds clean with the pipeline's flags, both with and
without the two data files.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NizVpJ2dwzCbjCrTLCjeHn
130 lines
4.2 KiB
HTML
130 lines
4.2 KiB
HTML
{% extends "base.html" %}
|
|
{% block title %}Gestión{% endblock %}
|
|
|
|
{% block main %}
|
|
<div class="feed-head">
|
|
<h1>Gestión</h1>
|
|
</div>
|
|
|
|
<p class="muted">
|
|
Lo que sólo hace la administración. Todo lo demás — el muro, los privados,
|
|
las publicaciones — está en las otras secciones y funciona igual para ti que
|
|
para cualquier miembro.
|
|
</p>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Miembros</h2>
|
|
<a class="linkish" href="{{ url_for('members.new') }}">Dar de alta</a>
|
|
</div>
|
|
<p class="panel__row">
|
|
{{ counts.members }} en total · {{ counts.moderators }} pueden moderar
|
|
{% if counts.suspended %} · {{ counts.suspended }} suspendido{{ '' if counts.suspended == 1 else 's' }}{% endif %}
|
|
</p>
|
|
<p class="muted small">
|
|
El directorio está en <a href="{{ url_for('members.index') }}">Miembros</a>,
|
|
que ahora es una sección como las demás. Invitar de nuevo, cambiar el rol,
|
|
suspender y eliminar están en la ficha de cada persona.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Artículos publicados</h2>
|
|
<a class="linkish" href="{{ url_for('content.index', collection='post') }}">Abrir</a>
|
|
</div>
|
|
<p class="muted small">
|
|
Lo que ya está en vienalatina.com: editar, corregir o retirar. Para
|
|
publicar algo nuevo, o para revisar lo que proponen los miembros, está
|
|
<a href="{{ url_for('submissions.index') }}">Publicaciones</a>.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Páginas del sitio</h2>
|
|
<a class="linkish" href="{{ url_for('content.index', collection='page') }}">Abrir</a>
|
|
</div>
|
|
<p class="muted small">
|
|
Acerca de, contacto y las demás páginas fijas de vienalatina.com. Las
|
|
publicaciones no están aquí: eso es
|
|
<a href="{{ url_for('submissions.index') }}">Publicaciones</a>, que los
|
|
moderadores comparten contigo.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Biblioteca de medios</h2>
|
|
<a class="linkish" href="{{ url_for('media.index') }}">Abrir</a>
|
|
</div>
|
|
<p class="muted small">
|
|
Todas las imágenes del sitio público y qué artículo usa cada una. Las que
|
|
no usa nadie —de artículos que se borraron— se pueden quitar desde ahí.
|
|
</p>
|
|
</section>
|
|
|
|
{% if g.member.role == 'superadmin' %}
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Marca</h2>
|
|
<a class="linkish" href="{{ url_for('brand.edit') }}">Abrir</a>
|
|
</div>
|
|
{% if brand.updated_at and not brand.published_at %}
|
|
<p class="panel__row">Hay cambios guardados que no han llegado al sitio público.</p>
|
|
{% endif %}
|
|
<p class="muted small">
|
|
Los colores, el logotipo y el icono de la pestaña, para las dos mitades del
|
|
sitio. Con un apartado avanzado para quien sepa CSS, y un botón para
|
|
volver a lo de fábrica.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Identidad</h2>
|
|
<a class="linkish" href="{{ url_for('identity.edit') }}">Abrir</a>
|
|
</div>
|
|
{% set site = identity() %}{% if site.updated_at and not site.published_at %}
|
|
<p class="panel__row">Hay cambios guardados que no han llegado al sitio público.</p>
|
|
{% endif %}
|
|
<p class="muted small">
|
|
El nombre y el lema en los tres idiomas, los perfiles de la asociación en
|
|
otros sitios, el contacto y el pie de página.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Estado del sistema</h2>
|
|
<a class="linkish" href="{{ url_for('status.index') }}">Abrir</a>
|
|
</div>
|
|
<p class="muted small">
|
|
Si el token para publicar funciona de verdad, si el correo sale, cuándo fue
|
|
la última copia de seguridad y cuánto disco queda. No cambia nada: responde.
|
|
</p>
|
|
</section>
|
|
|
|
<section class="panel">
|
|
<div class="panel__head">
|
|
<h2>Registro de actividad</h2>
|
|
<a class="linkish" href="{{ url_for('activity.index') }}">Abrir</a>
|
|
</div>
|
|
<p class="muted small">
|
|
Quién cambió un rol, aprobó una publicación, tocó el aspecto del sitio o
|
|
eliminó a alguien.
|
|
</p>
|
|
</section>
|
|
{% endif %}
|
|
|
|
{% if counts.pending %}
|
|
<section class="panel panel--attention">
|
|
<div class="panel__head">
|
|
<h2>Pendiente de revisar</h2>
|
|
<a class="linkish" href="{{ url_for('submissions.index') }}">Ver</a>
|
|
</div>
|
|
<p class="panel__row">{{ counts.pending }} propuesta{{ '' if counts.pending == 1 else 's' }} esperando a un moderador.</p>
|
|
</section>
|
|
{% endif %}
|
|
{% endblock %}
|