I’m interested in building a tag union capability that would mimic how tag intersections are currently implemented (Tag intersections page): essentially the same result as intersections (the default category/Latest view), but doing an OR on multiple tags rather than an AND. I would appreciate any suggestions as a new Discourse developer.
My thoughts (so far) are as follows:
Searching on multiple tags via the search page essentially provides tag-union functionality (Does multiple tag search support AND vs OR?). The problem is that I don’t want the search results view – I want the default category page. Could search results be redirected to accomplish this?
If search results can’t be redirected, I’m open to attempting a /tags/union/ route (and have been looking into how intersection works). I would prefer to do this via plugin, but I am concerned that that is not something that could currently be accomplished via a plugin. Any suggestions here would be appreciated.
If there is sufficient user interest to add a tag-union capability into the Discourse core, I’d be willing to do it and submit a PR, but I’m hoping to find an alternative. Thanks in advance.
La construction de tableaux de paramètres de requête à l’aide de la syntaxe paramName[] est spécifique aux frameworks backend, et je ne pense pas qu’elle soit prise en charge nativement par Ember. Nous pourrions peut-être la faire fonctionner, mais j’ai jeté un coup d’œil rapide à l’implémentation côté serveur du filtre tags et il semble que nous prenions également en charge une liste séparée par des espaces.
C’est très bien. Cependant, la page ne conserve pas les restrictions lorsqu’une catégorie est sélectionnée en haut à gauche. Pour les pages avec des tags uniques, cela fonctionne comme prévu.
Par exemple, si je suis sur /tag/tag1 et que je choisis site-feedback en haut à gauche. Il affiche /tags/c/site-feedback/2/tag1.
Avec /?tags=tag1+tag2, il me redirige simplement vers /c/site-feedback/2.
Est-il possible d’avoir cette fonctionnalité ?
Je suppose que cela a également été demandé dans ces deux sujets :