diff --git a/__pycache__/app.cpython-313.pyc b/__pycache__/app.cpython-313.pyc index 6aa07ec..2e4e59d 100644 Binary files a/__pycache__/app.cpython-313.pyc and b/__pycache__/app.cpython-313.pyc differ diff --git a/migrations/versions/add_mindmap_shares_table.py b/migrations/versions/add_mindmap_shares_table.py new file mode 100644 index 0000000..4aa52dc --- /dev/null +++ b/migrations/versions/add_mindmap_shares_table.py @@ -0,0 +1,38 @@ +"""add mindmap shares table + +Revision ID: add_mindmap_shares +Revises: add_missing_user_fields +Create Date: 2025-05-10 23:20:00.000000 + +""" +from alembic import op +import sqlalchemy as sa +from sqlalchemy.dialects import sqlite + +# revision identifiers, used by Alembic. +revision = 'add_mindmap_shares' +down_revision = 'add_missing_user_fields' +branch_labels = None +depends_on = None + + +def upgrade(): + # Erstelle PermissionType Enum + op.create_table('mindmap_share', + sa.Column('id', sa.Integer(), nullable=False), + sa.Column('mindmap_id', sa.Integer(), nullable=False), + sa.Column('shared_by_id', sa.Integer(), nullable=False), + sa.Column('shared_with_id', sa.Integer(), nullable=False), + sa.Column('permission_type', sa.String(20), nullable=False), + sa.Column('created_at', sa.DateTime(), nullable=True), + sa.Column('last_accessed', sa.DateTime(), nullable=True), + sa.ForeignKeyConstraint(['mindmap_id'], ['user_mindmap.id'], ), + sa.ForeignKeyConstraint(['shared_by_id'], ['user.id'], ), + sa.ForeignKeyConstraint(['shared_with_id'], ['user.id'], ), + sa.PrimaryKeyConstraint('id'), + sa.UniqueConstraint('mindmap_id', 'shared_with_id', name='unique_mindmap_share') + ) + + +def downgrade(): + op.drop_table('mindmap_share') \ No newline at end of file diff --git a/templates/errors/400.html b/templates/errors/400.html index 7bd28df..87ccf67 100644 --- a/templates/errors/400.html +++ b/templates/errors/400.html @@ -3,36 +3,46 @@ {% block title %}400 - Ungültige Anfrage{% endblock %} {% block content %} -
-
-
-
-
-

400

-
- +
+
+
+
400
+

Ungültige Anfrage

+

Die Anfrage konnte nicht verarbeitet werden.

+
+ +
+
+
+ + + +
+
+

Fehlerbeschreibung

+
+ {% if error %} +

{{ error }}

+ {% else %} +

Die Anfrage enthält ungültige oder fehlerhafte Daten und konnte nicht verarbeitet werden.

+ {% endif %}
-

Ungültige Anfrage

-

Die Anfrage konnte nicht verarbeitet werden. Bitte überprüfen Sie Ihre Eingaben und versuchen Sie es erneut.

- {% if error %} -
- {{ error }} -
- {% endif %} -
-
-
-

Benötigen Sie Hilfe? Kontaktieren Sie uns

+ +
+

Hier sind einige Dinge, die Sie versuchen können:

+
    +
  • Überprüfen Sie Ihre Eingaben auf Fehler.
  • +
  • Stellen Sie sicher, dass Sie die richtigen Daten übermittelt haben.
  • +
  • Versuchen Sie, die Seite neu zu laden.
  • +
  • Kehren Sie zur Startseite zurück und versuchen Sie es erneut.
  • +
+ + Zurück zur Startseite + +
{% endblock %} \ No newline at end of file