Skip to content

2105 display name #1486

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

Merged
merged 10 commits into from
Oct 27, 2020
Merged

2105 display name #1486

merged 10 commits into from
Oct 27, 2020

Conversation

Angamanga
Copy link
Collaborator

@Angamanga Angamanga commented Apr 6, 2020

This pull request makes the following changes:

  • Always make the save-button enabled on user-create/user-edit
  • Displays error-messages correctly when clicking on save
  • Adds test for new save-scenario

Testing checklist:

  • Go to settings->users->Add a new user
  • Click save without adding any information
  • The button should not be disabled
  • You should stay on the page
  • Error-labels where information is missing should be visible
  • Add information in the boxes
  • Click on save
  • The button should not be disabled
  • You should get redirected to the users-list
  • The user you added should be saved

-Go to settings->users

  • Click on a random user

  • Empty one or many of the input-fields

  • You should see error labels connected to those fields

  • Click on save

  • The button should not be disabled

  • You should stay on the page

  • Error-labels where information is missing should be visible

  • Add information in the boxes

  • Click on save

  • The button should not be disabled

  • You should get redirected to the users-list

  • The information you changed should be saved

  • I certify that I ran my checklist

Fixes ushahidi/platform#2105 .

Ping @ushahidi/platform

@Angamanga Angamanga requested a review from rowasc April 6, 2020 11:55
@Angamanga
Copy link
Collaborator Author

@rowasc This is ready for review!

@Angamanga
Copy link
Collaborator Author

@rowasc Could you review this one please?

Copy link
Contributor

@rowasc rowasc left a comment

Choose a reason for hiding this comment

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

hey Anna, left two non-blocking comments, lmk and I'll re-review :)

@@ -30,44 +30,50 @@ function (
$rootScope.$emit('setPageTitle', title);
});

$scope.isValid = true;
Copy link
Contributor

Choose a reason for hiding this comment

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

shouldn't isValid start assuming false? Just a question since I'm not sure if the repercusion is that it'll be weird in the UX if we change it

UserEndpoint.saveCache(user).$promise.then(function (response) {
if (response.id) {
Notify.notify('notify.user.save_success', {name: user.realname});
$scope.saving_user = false;
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we could do savingUser instead to keep it similar to the others (userSaveUser etc)

@Angamanga
Copy link
Collaborator Author

@rowasc Have fixed above comments so this is ready for re-review 🎉

Copy link
Contributor

@rowasc rowasc left a comment

Choose a reason for hiding this comment

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

You rock.
@Obadha2 please test. Thanks!

@theobadha theobadha merged commit e121558 into develop Oct 27, 2020
@theobadha
Copy link
Contributor

QA's, passes. 👍

@tuxpiper tuxpiper deleted the 2105-display-name branch March 24, 2021 21:01
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.

No specific UI feedback on "Display name" missing while creating a new user, except for save button being disabled
3 participants