summaryrefslogtreecommitdiffstats
path: root/server/api
diff options
context:
space:
mode:
authorJannik Schönartz2019-10-16 21:16:14 +0200
committerJannik Schönartz2019-10-16 21:16:14 +0200
commit4752614c0105b864d00e97179b4b77ccbad89e2d (patch)
tree88f89882295efda36ea71292241e80922694e85e /server/api
parent[documentation] Add more information about the automatic registration & chang... (diff)
downloadbas-4752614c0105b864d00e97179b4b77ccbad89e2d.tar.gz
bas-4752614c0105b864d00e97179b4b77ccbad89e2d.tar.xz
bas-4752614c0105b864d00e97179b4b77ccbad89e2d.zip
[webapp/clients] Add the choice to select backends when deleting clients
[group/clients] Checkbox list of the clients in the permanently delete dialog [server/backendhelper] Only deletes from the selected backends (array with backendids)
Diffstat (limited to 'server/api')
-rw-r--r--server/api/clients.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/api/clients.js b/server/api/clients.js
index a6d151a..d72207b 100644
--- a/server/api/clients.js
+++ b/server/api/clients.js
@@ -29,7 +29,7 @@ router.getAsync('/:id', async (req, res) => {
router.postAsync(['', '/:id'], async (req, res) => {
if (req.query.delete !== undefined && req.query.delete !== 'false') {
if (!Array.isArray(req.body.ids)) return HttpResponse.invalidBodyValue('ids', 'an array').send(res)
- await backendHelper.deleteClients(req.body.ids)
+ await backendHelper.deleteClients(req.body.ids, req.body.backendIds)
const count = await db.client.destroy({ where: { id: req.body.ids } })
HttpResponse.successBatch('deleted', 'client', count).send(res)
} else {