Compare commits

..

No commits in common. "3c6d52ed280720c320701f2f355ac140e2e6ca4d" and "93e6b9a0d3a3abe539f504186a11601bb07a924b" have entirely different histories.

10 changed files with 68 additions and 68 deletions

View file

@ -1,12 +1,13 @@
{ {
"fr": { "fr": {
"easter": "Pâques", "welcome": "Bienvenue à {0}!",
"easter-date-calc": "Calculer la date de Pâques",
"homepage": "Page de démarrage", "homepage": "Page de démarrage",
"latest-notes": "Dernières notes", "latest-notes": "Dernières notes",
"latest-uploads": "Derniers téléchargements", "latest-uploads": "Derniers téléchargements",
"new-note": "Créer un page", "new-note": "Créer un note",
"other-dates": "Autres dates", "upload-file": "Télécharger une image",
"welcome": "Bienvenue à {0}!" "easter-date-calc": "Calculer la date de Pâques",
"easter": "Pâques",
"other-dates": "Autres dates"
} }
} }

View file

@ -1,72 +1,71 @@
{ {
"it": { "it": {
"access-denied": "Accesso negato", "welcome": "Benvenuti in {0}!",
"access-denied-text": "Non hai il permesso per accedere a questa risorsa",
"action-edit": "Modifica",
"action-history": "Cronologia",
"action-view-source": "Visualizza sorgente",
"already-have-account": "Hai già un account?",
"back-to": "Torna a",
"backlinks": "Collegamenti in entrata",
"backlinks-empty": "Nessuna altra pagina punta qui. Questa pagina è orfana?",
"calculate": "Calcola",
"calendar": "Calendario",
"confirm-password": "Conferma password",
"easter-date-calc": "Calcolo della data di Pasqua",
"easter": "Pasqua",
"email": "E-mail",
"groups-count": "Numero di gruppi utente",
"have-read-terms": "Ho letto i {0} e la {1}",
"homepage": "Pagina iniziale", "homepage": "Pagina iniziale",
"include-tags": "Includi etichette",
"input-tags": "Etichette (separate da virgola)",
"jump-to-actions": "Salta alle azioni",
"just-now": "poco fa",
"last-changed": "Ultima modifica",
"latest-notes": "Pagine pi\u00f9 recenti", "latest-notes": "Pagine pi\u00f9 recenti",
"latest-uploads": "Caricamenti pi\u00f9 recenti", "latest-uploads": "Caricamenti pi\u00f9 recenti",
"login": "Entra", "new-note": "Crea nota",
"logged-in-as": "Autenticato come", "upload-file": "Carica immagine",
"easter-date-calc": "Calcolo della data di Pasqua",
"easter": "Pasqua",
"other-dates": "Altre date",
"jump-to-actions": "Salta alle azioni",
"last-changed": "Ultima modifica",
"page-id": "ID pagina",
"action-edit": "Modifica",
"action-view-source": "Visualizza sorgente",
"action-history": "Cronologia",
"tags": "Etichette",
"old-revision-notice": "\u00c8 mostrata una revisione vecchia della pagina, risalente al",
"notes-tagged": "Pagine con etichetta",
"include-tags": "Includi etichette",
"notes-tagged-empty": "Non c\u2019\u00e8 nulla :(",
"search-no-results": "Nessun risultato per",
"random-page": "Pagina casuale",
"search": "Cerca",
"year": "Anno",
"month": "Mese", "month": "Mese",
"calculate": "Calcola",
"show-all": "Mostra tutto",
"just-now": "poco fa",
"n-minutes-ago": "{0} minuti fa", "n-minutes-ago": "{0} minuti fa",
"n-hours-ago": "{0} ore fa", "n-hours-ago": "{0} ore fa",
"n-days-ago": "{0} giorni fa", "n-days-ago": "{0} giorni fa",
"new-note": "Crea nota", "backlinks": "Collegamenti in entrata",
"backlinks-empty": "Nessuna altra pagina punta qui. Questa pagina è orfana?",
"back-to": "Torna a",
"login": "Entra",
"username": "Nome utente",
"password": "Password",
"no-account-sign-up": "Non hai un account?", "no-account-sign-up": "Non hai un account?",
"no-tags": "Nessuna etichetta", "sign-up": "Registrati",
"not-found": "Non trovato", "not-found": "Non trovato",
"not-found-text": "La pagina con url {0} non esiste",
"not-found-text-1": "La pagina con url", "not-found-text-1": "La pagina con url",
"not-found-text-2": "non esiste", "not-found-text-2": "non esiste",
"not-logged-in": "Non autenticato", "not-found-text": "La pagina con url {0} non esiste",
"note-history": "Cronologia della pagina", "access-denied": "Accesso negato",
"access-denied-text": "Non hai il permesso per accedere a questa risorsa",
"users-count": "Numero di utenti",
"notes-count": "Numero di pagine", "notes-count": "Numero di pagine",
"notes-count-with-url": "Numero di pagine con URL impostato", "notes-count-with-url": "Numero di pagine con URL impostato",
"notes-month-empty": "Non c\u2019\u00e8 nulla :(",
"notes-tagged": "Pagine con etichetta",
"notes-tagged-empty": "Non c\u2019\u00e8 nulla :(",
"old-revision-notice": "\u00c8 mostrata una revisione vecchia della pagina, risalente al",
"optional": "opzionale",
"other-dates": "Altre date",
"page-created": "Pagina creata",
"owner": "Proprietario",
"page-id": "ID pagina",
"password": "Password",
"privacy-policy": "Politica sulla riservatezza",
"random-page": "Pagina casuale",
"remember-me-for": "Ricordami per",
"revision-count": "Numero di revisioni", "revision-count": "Numero di revisioni",
"revision-count-per-page": "Media di revisioni per pagina", "revision-count-per-page": "Media di revisioni per pagina",
"search": "Cerca", "remember-me-for": "Ricordami per",
"search-no-results": "Nessun risultato per", "confirm-password": "Conferma password",
"show-all": "Mostra tutto", "email": "E-mail",
"sign-up": "Registrati", "optional": "opzionale",
"tags": "Etichette", "have-read-terms": "Ho letto i {0} e la {1}",
"terms-of-service": "Termini di Servizio", "terms-of-service": "Termini di Servizio",
"username": "Nome utente", "privacy-policy": "Politica sulla riservatezza",
"users-count": "Numero di utenti", "already-have-account": "Hai già un account?",
"welcome": "Benvenuti in {0}!", "logged-in-as": "Autenticato come",
"not-logged-in": "Non autenticato",
"owner": "Proprietario",
"write-a-comment": "Scrivi un commento…", "write-a-comment": "Scrivi un commento…",
"year": "Anno" "input-tags": "Etichette (separate da virgola)",
"no-tags": "Nessuna etichetta",
"notes-month-empty": "Non c\u2019\u00e8 nulla :(",
"calendar": "Calendario",
"groups-count": "Numero di gruppi utente"
} }
} }

View file

@ -1,6 +1,5 @@
{ {
"ru":{ "ru":{
"new-note": "Новая страница",
"welcome": "Добро пожаловать в {0}!" "welcome": "Добро пожаловать в {0}!"
} }
} }

View file

@ -15,7 +15,7 @@ dependencies = [
"Flask-WTF", "Flask-WTF",
"python-dotenv>=1.0.0", "python-dotenv>=1.0.0",
"pymysql", "pymysql",
"sakuragasaki46-suou>=0.6.0" "sakuragasaki46-suou>=0.5.0"
] ]
requires-python = ">=3.10" requires-python = ">=3.10"
classifiers = [ classifiers = [

View file

@ -8,7 +8,7 @@ Pages are stored in SQLite/MySQL databases.
Markdown is used for text formatting. Markdown is used for text formatting.
''' '''
__version__ = '1.0.0' __version__ = '1.0.0-dev35'
from flask import ( from flask import (
Flask, abort, flash, g, jsonify, make_response, redirect, Flask, abort, flash, g, jsonify, make_response, redirect,

View file

@ -644,8 +644,8 @@ def create_first_user():
permissions = int(default_permissions) permissions = int(default_permissions)
).returning(UserGroup)).scalar() ).returning(UserGroup)).scalar()
db.session.execute(insert(UserGroupMembership).values( db.session.execute(insert(UserGroupMembership).values(
user_id = ua.id, user = ua,
group_id = ug.id group = ug
)) ))
db.session.commit() db.session.commit()
print('Installed successfully!') print('Installed successfully!')

View file

@ -78,8 +78,8 @@ def register():
join_date = datetime.datetime.now() join_date = datetime.datetime.now()
).returning(User)).scalar() ).returning(User)).scalar()
db.session.execute(insert(UserGroupMembership).values( db.session.execute(insert(UserGroupMembership).values(
user_id = u.id, user = u,
group_id = UserGroup.get_default().id group = UserGroup.get_default()
)) ))
db.session.commit() db.session.commit()

View file

@ -1,7 +1,8 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="{{ g.lang }}"> <html lang="{{ g.lang }}">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
{% block title %} {% block title %}
<title>{{ app_name }}</title> <title>{{ app_name }}</title>

View file

@ -10,8 +10,8 @@
<div class="preview-subtitle">{{ T('notes-tagged') }}</div> <div class="preview-subtitle">{{ T('notes-tagged') }}</div>
<div class="inner-content"> <div class="inner-content">
{% if tagged_notes.total > 0 %} {% if total_count > 0 %}
{{ nl_list(tagged_notes, hl_tags=(tagname,), other_url='tags/' + tagname) }} {{ nl_list(tagged_notes, page_n=page_n, total_count=total_count, hl_tags=(tagname,), other_url='tags/' + tagname) }}
{% else %} {% else %}
<p class="nl-placeholder">{{ T('notes-tagged-empty') }}</p> <p class="nl-placeholder">{{ T('notes-tagged-empty') }}</p>
{% endif %} {% endif %}

View file

@ -16,7 +16,7 @@
{% if not is_main %} {% if not is_main %}
<p class="nl-pagination"> <p class="nl-pagination">
Showing results <strong>{{ page_n * 20 - 19 }}</strong> to <strong>{{ min(page_n * 20, total_count) }}</strong> Showing results <strong>{{ page_n * 20 - 19 }}</strong> to <strong>{{ min(page_n * 20, total_count) }}</strong>
of <strong>{{ l.total }}</strong> total.</p> of <strong>{{ total_count }}</strong> total.</p>
{% endif %} {% endif %}
<ul class="nl-list"> <ul class="nl-list">
@ -62,7 +62,7 @@
{% if is_main %} {% if is_main %}
<li class="nl-next"><a href="/{{ other_url }}/">{{ T('show-all') }}</a></li> <li class="nl-next"><a href="/{{ other_url }}/">{{ T('show-all') }}</a></li>
{% elif page_n <= (l.total - 1) // 20 %} {% elif page_n <= (total_count - 1) // 20 %}
<li class="nl-next"><a href="/{{ other_url }}/?page={{ page_n + 1 }}">Next page &raquo;</a></li> <li class="nl-next"><a href="/{{ other_url }}/?page={{ page_n + 1 }}">Next page &raquo;</a></li>
{% endif %} {% endif %}
</ul> </ul>