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

[Outreachy Task Submission] - Added confirmation messages and a complete button when posts are added to collections #888

Merged
merged 5 commits into from
Apr 26, 2024

Conversation

felabel
Copy link

@felabel felabel commented Mar 15, 2024

This PR fixes the issue raised here - ushahidi/platform#4830 @Angamanga

When a post is added or removed from a collection, there is no confirmation message for this processes. Also after selecting a collection, there is no done or finish button for better user interactivity.

Steps to reproduce;

  1. On the dashboard select your survey to view the posts in them
  2. Click on the 3 dots on a post and select add to collection

Actual Behaviour
A collection modal pops up, select your collection and no confirmation message or a done button

Expected Behaviour;
There should be a snackbar notification showing the success of adding or removing a post from a collection.

What I did;
I added confirmation messages to show when a post is added or removed from a collection -including the collection name
I added a done button for better user interactivity and accessibility. Below are the screenshots to show

Screenshot 2024-03-15 at 04 49 47 Filters Post removed from the New collection

@Angamanga Angamanga self-requested a review March 15, 2024 14:08
Copy link
Contributor

@Angamanga Angamanga left a comment

Choose a reason for hiding this comment

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

Thank you for your contributions, this is a very needed addition :) I have a few change requests, see my comments in the code.

Is there any specific reason you created the alert-service? You can look at https://github.com/ushahidi/platform-client-mzima/blob/development/apps/web-mzima-client/src/app/post/post-edit/post-edit.component.ts#L640 to see how the message is displayed when successfully adding a post. Maybe you can use something from there to show the message directly without having to go via the alert-service :)

@@ -113,25 +113,69 @@ export class GeneralComponent implements OnInit {
.pipe(
mergeMap((newImage: any) => {
this.siteConfig.image_header = newImage.result.original_file_url;
console.log(newImage.result.original_file_url);
console.log(this.updateSettings());
return this.updateSettings();
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove the console.logs here

Copy link
Contributor

Choose a reason for hiding this comment

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

Is the changes in this file part of this PR? If not, remove the commits to only include changes for the specific issue you are solving :)

Copy link
Contributor

Choose a reason for hiding this comment

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

Is the changes in this file part of this PR? If not, remove the commits to only include changes for the specific issue you are solving :)

@Angamanga Angamanga changed the base branch from development to USH-416 April 26, 2024 13:22
@Angamanga Angamanga merged commit b6133df into ushahidi:USH-416 Apr 26, 2024
3 of 4 checks passed
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.

2 participants