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

Fixes #10250: When trying to create a new API account that has the same name as an existing acocunt, nothing happen #1522

Conversation

RaphaelGauthier
Copy link
Member

@@ -118,7 +118,15 @@ <h1 id="title" style="color: #000; wrap-word:break-word;">{{formTitle(myNewAccou
<div class="simplemodal-bottom">
<div class="popupButton" style="width: 98%;border-top: 1px solid #9A9A9A;margin-top: 10px;">
<span>
<input type="submit" class="btn-primary" style="float:right;" value="Save" ng-disabled="newAccount.$pristine || newAccount.$invalid" ng-click="checkAndSaveAccount(myNewAccount,myNewAccount.index,newAccount);newAccount.$setPristine();" />
<button
Copy link
Member

Choose a reason for hiding this comment

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

Why changing from input to button fix it ?

We should put the check in the ng-disable i think ... but htat for another time :)

Copy link
Member Author

Choose a reason for hiding this comment

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

Oops, this was just a test. I forgot to replace it...

Copy link
Member

Choose a reason for hiding this comment

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

Then i don't understand what is fixing the issue here :(

Copy link
Member Author

Choose a reason for hiding this comment

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

The angular app was started twice in a row :

  1. with the ng-app directive (<div class="portlet" ng-app="accountManagement" [...]>)
  2. with : angular.bootstrap(document.getElementById('accountManagement'), ['accountManagement']);

This caused a JS error which was the origin of this bug

Copy link
Member Author

Choose a reason for hiding this comment

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

I simply removed the ngApp directive!

@Normation-Quality-Assistant
Copy link
Contributor

This PR is not mergeable to upper versions.
Since it is "Ready for merge" you must merge it by yourself using the following command:
rudder-dev merge https://github.com/Normation/rudder/pull/1522
-- Your faithful QA

…me name as an existing acocunt, nothing happen
@RaphaelGauthier
Copy link
Member Author

Commit modified

@RaphaelGauthier RaphaelGauthier force-pushed the bug_10250/when_trying_to_create_a_new_api_account_that_has_the_same_name_as_an_existing_acocunt_nothing_happen branch from 866f0d0 to 7dd23e4 Compare February 23, 2017 12:01
@Normation-Quality-Assistant
Copy link
Contributor

This PR is not mergeable to upper versions.
Since it is "Ready for merge" you must merge it by yourself using the following command:
rudder-dev merge https://github.com/Normation/rudder/pull/1522
-- Your faithful QA

@RaphaelGauthier
Copy link
Member Author

OK, merging this PR

@RaphaelGauthier RaphaelGauthier merged commit 7dd23e4 into Normation:branches/rudder/3.1 Feb 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants