Score:0

Report comments / Workflow

kp flag

I am trying to implement a functionality that would allow authenticated users to report comments on a forum post. My first thought was to do it using workflows but comments dont have a workflow functionality by default. I am working in a restricted environment so I am not allowed to use external modules.

My current approach is to have a Taxonomy field on comments which can be set to report. And then deciding on the twig file whether or not reported comments should be shown. However I'm having trouble setting the taxonomy term on a comment to report when a link/button is pressed. I've tried to use ajax to call a php function, but that seems to break all the menus on the site.

Does anybody have any ideas on how I can implement this?

Hodba Khalaf avatar
eg flag
You sound like you are trying to replicate the flag module https://www.drupal.org/project/flag If I was in your position, I would have a look at the flag module and try to replicate its functionality as you can't download external modules
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.