This commit is contained in:
lesion
2023-06-17 09:30:44 +02:00
parent 09d75aad6c
commit acc1d1d4d0
4 changed files with 8 additions and 8 deletions

View File

@@ -131,11 +131,11 @@ const collectionController = {
const collectionId = req.params.collection_id
const filters = await Filter.findAll({ where: { collectionId } })
return res.json(filters)
},
},
async addFilter (req, res) {
const { collectionId, tags, places } = req.body
try {
filter = await Filter.create({ collectionId, tags, places })
return res.json(filter)
@@ -165,4 +165,4 @@ const collectionController = {
}
module.exports = collectionController
module.exports = collectionController