Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow visitors to create posts with tags #1211

Open
MercierMateo opened this issue Sep 24, 2024 · 3 comments
Open

Allow visitors to create posts with tags #1211

MercierMateo opened this issue Sep 24, 2024 · 3 comments

Comments

@MercierMateo
Copy link

Posts can be sorted with tags, but theses tags can only be added and modified by administrators and collaborators.

Users (with visitor role) might already know the necessary tags. It would make administration with tags a lot easier if visitors could specify tags while creating posts.

It would also help with automation. For example to send an email or a message to different contacts depending on which tag is used.

Solution proposal

Front-End

The post creation form could be extended to look like this model :

screen fider

This new field could be automatically filled with the tags specified in the URL through the tag filter search or an external link. It would help placing links on different web apps or physically through QR codes.

API

Should the tagging and untagging permissions be given to the creator of the post after creation ?

  • If this is the case the tagging and untagging routes would have to be made accessible to the creator :

(Un)Tag a Post

  • Authentication: Required
  • Required Role: Collaborator or Administrator
  • Allow post creator to use

Some other routes (like post editing) allow the post's creators to use them but it is not documented

POST /api/v1/posts/{number}/tags/{slug}

...

  • Else in the route used to create posts POST /api/v1/posts the payload could be extended to include tags :

Create a Post

  • Authentication: Required
POST /api/v1/posts
Parameters
Name Type Description
title string Required. The title of the post.
description string The description of the post.
tags list The list of tags to create the post with
Example
POST <baseURL>/api/v1/posts
---
{
  "title": "Allow users to edit any comment",
  "description": "This is useful to fix some minor typos or introduce more details"
  "tags": ["feature"]
}

Both these solutions would allow visitors to specify tags while creating posts.

Feature enabling

Should this feature be behind a feature flag ? Or should it be enabled for everybody ?

@MercierCorentin
Copy link

This feature request is quite important for us as we use Fider as a global feedback plateforme for our university projects, with @MercierMateo with your approval, we are ready to develop this feature !

It is part of an educational projet, I'm supervising the project.

@mattwoberts
Copy link
Contributor

Hey there.

Thanks very much for this. What you're proposing sounds like a nice addition to the app.

We're more than happy for you to take this on, here are some thoughts / comments from us:

UI

I'm not sure if this is what you're proposing, but yes we think it's OK to allow the tags to be selected when you're adding the post - use the same UI / components that we currently use for tagging posts when you're an admin.

Allowing users to change tags once it's been added.

First I was going to suggest that you should be able to change tags, since you can do so when you create posts. But, after some thought and discussions, we've changed our mind on that one. It gets very complicated since you wouldn't want tags that have been assigned from admins to be edited from the post creators. So for now, we think it would be better to only allow tags to be created when you create the post?

Feature enabling

I think it might be a good idea if you develop this with a feature switch so that if some people don't want it, they can turn it off. You can add something to the config to support this.

@MercierMateo
Copy link
Author

Hey,

Thanks for your reponse, I will start working on these improvements. I agree with the choices you suggest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants