2 Commits

Author SHA1 Message Date
fda5655533 added extra log 2025-05-31 22:19:59 +02:00
ac49c842b8 Update base.html 2025-05-31 19:17:58 +02:00
6 changed files with 16 additions and 5 deletions

Binary file not shown.

View File

@@ -85,6 +85,22 @@ def create_conversation():
db.session.add(conversation)
db.session.commit()
# Create notifications for all members except the creator
for member in conversation.members:
if member.id != current_user.id:
create_notification(
notif_type='conversation_invite',
user_id=member.id,
sender_id=current_user.id,
details={
'message': f'You have been added to conversation "{conversation.name}"',
'conversation_id': conversation.id,
'conversation_name': conversation.name,
'invited_by': f"{current_user.username} {current_user.last_name}",
'timestamp': datetime.utcnow().isoformat()
}
)
# Log conversation creation
log_event(
event_type='conversation_create',

View File

@@ -35,11 +35,6 @@
<a class="nav-link text-white" href="{{ url_for('main.notifications') }}">
<i class="fas fa-bell text-xl" style="width: 2rem; height: 2rem; display: flex; align-items: center; justify-content: center;"></i>
</a>
{% if current_user.is_admin %}
<a class="nav-link text-white" href="{{ url_for('main.settings') }}">
<i class="fas fa-cog text-xl" style="width: 2rem; height: 2rem; display: flex; align-items: center; justify-content: center;"></i>
</a>
{% endif %}
</div>
<div class="dropdown">
<a class="nav-link d-flex align-items-center gap-2 d-lg-none" href="{{ url_for('main.profile') }}">