Coverage for polar/models/user_notification.py: 100%
8 statements
« prev ^ index » next coverage.py v7.15.2, created at 2026-10-07 12:42 +0000
« prev ^ index » next coverage.py v7.15.2, created at 2026-10-07 12:42 +0000
1from uuid import UUID
3from sqlalchemy import ForeignKey, Uuid
4from sqlalchemy.orm import Mapped, mapped_column
6from polar.kit.db.models import Model
9class UserNotification(Model):
10 __tablename__ = "user_notifications"
12 user_id: Mapped[UUID] = mapped_column(
13 Uuid,
14 ForeignKey("users.id"),
15 nullable=False,
16 primary_key=True,
17 )
19 last_read_notification_id: Mapped[UUID] = mapped_column(
20 Uuid,
21 nullable=True,
22 )