Adding in the delete api and the delete and create UI.
This commit is contained in:
parent
43063272bb
commit
97d644d95d
12 changed files with 277 additions and 12 deletions
|
@ -11,3 +11,9 @@ def create(messages):
|
|||
for message in messages:
|
||||
inserted.append(Messages.create(content=message['content']))
|
||||
return inserted
|
||||
|
||||
def delete_message(uuids):
|
||||
"""Delete message from the database"""
|
||||
if not uuids:
|
||||
return
|
||||
Messages.delete().where(Messages.uuid << uuids).execute()
|
||||
|
|
Reference in a new issue