update rooms.py and main.py
This commit is contained in:
+14
-8
@@ -135,11 +135,11 @@ def update_event(
|
||||
description,
|
||||
start_time,
|
||||
end_time,
|
||||
min_people
|
||||
min_people,
|
||||
event_type,
|
||||
visibility,
|
||||
status,
|
||||
):
|
||||
|
||||
from database import execute
|
||||
|
||||
execute(
|
||||
"""
|
||||
UPDATE events
|
||||
@@ -148,7 +148,10 @@ def update_event(
|
||||
description = COALESCE(?, description),
|
||||
start_time = COALESCE(?, start_time),
|
||||
end_time = COALESCE(?, end_time),
|
||||
min_people = COALESCE(?, min_people)
|
||||
min_people = COALESCE(?, min_people),
|
||||
type = COALESCE(?, type),
|
||||
visibility = COALESCE(?, visibility),
|
||||
status = COALESCE(?, status)
|
||||
WHERE id = ?
|
||||
""",
|
||||
(
|
||||
@@ -157,10 +160,13 @@ def update_event(
|
||||
start_time,
|
||||
end_time,
|
||||
min_people,
|
||||
event_id
|
||||
)
|
||||
event_type,
|
||||
visibility,
|
||||
status,
|
||||
event_id,
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
def get_room_events(room_id):
|
||||
|
||||
from database import fetch_all
|
||||
|
||||
Reference in New Issue
Block a user