- Correctie reset password en confirm email adress by adapting the prefixed_url_for to use config setting

- Adaptation of DPA and T&Cs
- Refer to privacy statement as DPA, not a privacy statement
- Startup of enforcing signed DPA and T&Cs
- Adaptation of eveai_chat_client to ensure we retrieve correct DPA & T&Cs
This commit is contained in:
Josako
2025-10-13 14:28:09 +02:00
parent 83272a4e2a
commit 37819cd7e5
35 changed files with 5350 additions and 241 deletions

View File

@@ -0,0 +1,51 @@
"""TenantConsent model creation
Revision ID: 411f5593460e
Revises: 057fb975f0e3
Create Date: 2025-10-09 07:32:04.598209
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '411f5593460e'
down_revision = '057fb975f0e3'
branch_labels = None
depends_on = None
def upgrade():
op.create_table('tenant_consent',
sa.Column('id', sa.Integer(), nullable=False),
sa.Column('tenant_id', sa.Integer(), nullable=False),
sa.Column('partner_id', sa.Integer(), nullable=False),
sa.Column('partner_service_id', sa.Integer(), nullable=False),
sa.Column('user_id', sa.Integer(), nullable=False),
sa.Column('consent_type', sa.String(length=50), nullable=False),
sa.Column('consent_date', sa.DateTime(), server_default=sa.text('now()'), nullable=False),
sa.Column('consent_dpa_version', sa.String(length=20), nullable=False),
sa.Column('consent_t_c_version', sa.String(length=20), nullable=False),
sa.Column('consent_data', sa.JSON(), nullable=False),
sa.Column('created_at', sa.DateTime(), server_default=sa.text('now()'), nullable=False),
sa.Column('created_by', sa.Integer(), nullable=True),
sa.Column('updated_at', sa.DateTime(), server_default=sa.text('now()'), nullable=False),
sa.Column('updated_by', sa.Integer(), nullable=True),
sa.ForeignKeyConstraint(['created_by'], ['public.user.id'], ),
sa.ForeignKeyConstraint(['partner_id'], ['public.partner.id'], ),
sa.ForeignKeyConstraint(['partner_service_id'], ['public.partner_service.id'], ),
sa.ForeignKeyConstraint(['tenant_id'], ['public.tenant.id'], ),
sa.ForeignKeyConstraint(['updated_by'], ['public.user.id'], ),
sa.ForeignKeyConstraint(['user_id'], ['public.user.id'], ),
sa.PrimaryKeyConstraint('id'),
schema='public'
)
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_table('tenant_consent', schema='public')
# ### end Alembic commands ###

View File

@@ -0,0 +1,36 @@
"""Add ConsentVersion model
Revision ID: 8bfd440079a5
Revises: 411f5593460e
Create Date: 2025-10-09 14:12:41.318538
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '8bfd440079a5'
down_revision = '411f5593460e'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.create_table('consent_version',
sa.Column('id', sa.Integer(), nullable=False),
sa.Column('consent_type', sa.String(length=50), nullable=False),
sa.Column('consent_version', sa.String(length=20), nullable=False),
sa.Column('consent_valid_from', sa.DateTime(), server_default=sa.text('now()'), nullable=False),
sa.Column('consent_valid_to', sa.DateTime(), nullable=True),
sa.PrimaryKeyConstraint('id'),
schema='public'
)
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_table('consent_version', schema='public')
# ### end Alembic commands ###

View File

@@ -0,0 +1,37 @@
"""Adding Tracking information to ConsentVersion
Revision ID: f5f1a8b8e238
Revises: 8bfd440079a5
Create Date: 2025-10-09 15:30:00.046174
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = 'f5f1a8b8e238'
down_revision = '8bfd440079a5'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('consent_version', schema=None) as batch_op:
batch_op.add_column(sa.Column('created_at', sa.DateTime(), server_default=sa.text('now()'), nullable=False))
batch_op.add_column(sa.Column('created_by', sa.Integer(), nullable=True))
batch_op.add_column(sa.Column('updated_at', sa.DateTime(), server_default=sa.text('now()'), nullable=False))
batch_op.add_column(sa.Column('updated_by', sa.Integer(), nullable=True))
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('consent_version', schema=None) as batch_op:
batch_op.drop_column('updated_by')
batch_op.drop_column('updated_at')
batch_op.drop_column('created_by')
batch_op.drop_column('created_at')
# ### end Alembic commands ###