Coverage for app/logic/createLogs.py: 100%

10 statements  

« prev     ^ index     » next       coverage.py v7.2.7, created at 2024-07-31 16:31 +0000

1from flask import g 

2from datetime import datetime 

3from app.models.activityLog import ActivityLog 

4from app.models.eventRsvpLog import EventRsvpLog 

5 

6def createRsvpLog(eventId, content): 

7 date = datetime.now() 

8 EventRsvpLog.create(createdBy=g.current_user,createdOn=date,rsvpLogContent=content,event_id=eventId) 

9 

10 

11def createActivityLog(content): 

12 date = datetime.now() 

13 ActivityLog.create(createdBy=g.current_user,createdOn=date,logContent=content)