mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-15 18:25:18 +02:00
feat: Enhance notification model and UI components
- Added an `updated_at` timestamp field to the Notification model for better tracking of notification updates. - Updated the NotificationButton component to change the unread notification badge color for improved visibility. - Adjusted the NotificationPopup component's layout and text handling for better responsiveness and readability.
This commit is contained in:
parent
9d0f5b4249
commit
460dc0dec8
3 changed files with 17 additions and 10 deletions
|
|
@ -728,6 +728,13 @@ class Notification(BaseModel, TimestampMixin):
|
|||
Boolean, nullable=False, default=False, server_default=text("false"), index=True
|
||||
)
|
||||
notification_metadata = Column("metadata", JSONB, nullable=True, default={})
|
||||
updated_at = Column(
|
||||
TIMESTAMP(timezone=True),
|
||||
nullable=True,
|
||||
default=lambda: datetime.now(UTC),
|
||||
onupdate=lambda: datetime.now(UTC),
|
||||
index=True,
|
||||
)
|
||||
|
||||
user = relationship("User", back_populates="notifications")
|
||||
search_space = relationship("SearchSpace", back_populates="notifications")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue