feat: allow tag editing from topic tools

closes #7536
closes #7465
closes #11538
This commit is contained in:
Barış Soner Uşaklı
2023-04-30 21:17:25 -04:00
parent 0391876822
commit e3551d80d7
16 changed files with 257 additions and 20 deletions

View File

@@ -100,13 +100,21 @@ Topics.unfollow = async (req, res) => {
helpers.formatApiResponse(200, res);
};
Topics.updateTags = async (req, res) => {
const payload = await api.topics.updateTags(req, {
tid: req.params.tid,
tags: req.body.tags,
});
helpers.formatApiResponse(200, res, payload);
};
Topics.addTags = async (req, res) => {
await api.topics.addTags(req, {
const payload = await api.topics.addTags(req, {
tid: req.params.tid,
tags: req.body.tags,
});
helpers.formatApiResponse(200, res);
helpers.formatApiResponse(200, res, payload);
};
Topics.deleteTags = async (req, res) => {