Namespace filtering when create/edit campaigns

This commit is contained in:
Carlos 2019-03-14 16:15:37 +01:00
parent 7b08e2e97b
commit 74fe5e73e2
6 changed files with 752 additions and 9 deletions

View file

@ -12,7 +12,7 @@ router.postAsync('/lists-table', passport.loggedIn, async (req, res) => {
});
router.postAsync('/users-table-byNamespace/:namespaceId', passport.loggedIn, async (req, res) => {
return res.json(await lists.listDTAjax(req.context, 1));
return res.json(await lists.listByNamespaceDTAjax(req.context, castToInteger(req.params.namespaceId), req.body));
});
router.postAsync('/lists-with-segment-by-campaign-table/:campaignId', passport.loggedIn, async (req, res) => {

View file

@ -40,6 +40,10 @@ router.postAsync('/send-configurations-table', passport.loggedIn, async (req, re
return res.json(await sendConfigurations.listDTAjax(req.context, req.body));
});
router.postAsync('/send-configurations-table-byNamespace/:namespaceId', passport.loggedIn, async (req, res) => {
return res.json(await sendConfigurations.listDTAjaxByNamespace(req.context, castToInteger(req.params.namespaceId), req.body));
});
router.postAsync('/send-configurations-with-send-permission-table', passport.loggedIn, async (req, res) => {
return res.json(await sendConfigurations.listWithSendPermissionDTAjax(req.context, req.body));
});