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

Fix #97: Added delete feature in a story #128

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kailash360
Copy link
Member

@kailash360 kailash360 commented Feb 18, 2022

Issue Number

fixes #97

Describe the changes you've made

I have added the service to make a request of DELETE method, and also modified the apiCall function such that it can accommodate any request method. I have also added a Delete button in the page of a story tha the user can sue to delete a story.

Describe if there is any unusual behavior (Any Warning) of your code(Write NA if there isn't)

NA

Additional context (OPTIONAL)

NA

Test plan (OPTIONAL)

A good test plan should give instructions that someone else can easily follow.

Checklist

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • All new and existing tests passed.
  • The title of my pull request is a short description of the requested changes.

Provide a Deployed link of route/page that needs to review

Preview: Deploy preview link here with the appropriate route

screen-capture.1.mp4

@kailash360 kailash360 changed the title Fix #108: Added delete feature in a a story Fix #97: Added delete feature in a a story Feb 18, 2022
@kailash360 kailash360 changed the title Fix #97: Added delete feature in a a story Fix #97: Added delete feature in a story Feb 18, 2022
@kailash360
Copy link
Member Author

@mharshita
I have created this PR for resolving the editing of a story, as discussed here .

@cyntss
Copy link
Member

cyntss commented Feb 18, 2022

This is a great work, the only thing is that we don't want to allow users to delete a story. We made this decision in the past to consider that stories may have information from other users supporting a request (screenshots, votes, additional information, etc), so only an admin should be able to delete a story either because it is inappropriate or invalid. But a user shouldn't have this option.

What we could do, is that a user reports a story to be deleted and that it triggers on the admin to be reviewed.

What do you think @kailash360 ? Could you change the implementation to go in this direction instead?

@kailash360
Copy link
Member Author

kailash360 commented Feb 18, 2022

@cyntss

Sure, we can replace the Delete feature, with a Report feature. The user who created that story will get an option - Request to Unpublish it, while other users will see a Report option. The functionality of both of them will remain the same.

I have thought of the following approach to this:

  • We can add a separate User-Story-Report model which will contain the username of the person who reported a story, the reason it was reported for, and the link to the story. The admin can visit this User-Story Report collection to see all the reports and take action accordingly by clicking on the link to that story. If the report was not strong enough, the admin can delete the report itself as well.

Kindly suggest if there is any other approach, or if I should start implementing this approach.

@mharshita
Copy link
Member

Report feature sounds good to me.

@cyntss
Copy link
Member

cyntss commented Aug 31, 2022

@kailash360 after the implementation of the Reporting model on Strapi, have you followed up to create a Report feature on the front-end?

Copy link
Member

@cyntss cyntss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We've decided that we will only use Reports, as opposed to delete, since it goes against the use cases of the application to let users delete a story

@kailash360
Copy link
Member Author

@kailash360 after the implementation of the Reporting model on Strapi, have you followed up to create a Report feature on the front-end?

@cyntss
As of now, I have developed the design of the frontend. Link to the design

We can close this PR, and I'll open another one that will add the Report modal displayed above.

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

Successfully merging this pull request may close these issues.

Edit Story Feature not working properly
3 participants