You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/03/23 10:05:43 UTC

[GitHub] [cloudstack] davidjumani opened a new pull request #4857: ui: Disable login button until redirected

davidjumani opened a new pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857


   ### Description
   
   Disables the login button while discovering features to prevent a double login / repetitive API calls
   
   ### Types of changes
   
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [x] Bug fix (non-breaking change which fixes an issue)
   - [ ] Enhancement (improves an existing feature and functionality)
   - [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
   
   #### Bug Severity
   
   - [ ] BLOCKER
   - [ ] Critical
   - [ ] Major
   - [ ] Minor
   - [x] Trivial
   
   
   ### Screenshots (if appropriate):
   
   #### Before :
   
   ![Screenshot from 2021-03-23 15-31-48](https://user-images.githubusercontent.com/8244774/112129335-55ec6d80-8bed-11eb-84d0-08f70f46554d.png)
   
   #### After :
   
   ![Screenshot from 2021-03-23 15-31-21](https://user-images.githubusercontent.com/8244774/112129355-5ab12180-8bed-11eb-80b9-ddbd55659b13.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] davidjumani commented on pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
davidjumani commented on pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#issuecomment-804777408


   @blueorangutan ui


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on a change in pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
rhtyd commented on a change in pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#discussion_r599588789



##########
File path: ui/src/views/auth/Login.vue
##########
@@ -189,8 +189,8 @@ export default {
             }
             Login(loginParams)
               .then((res) => this.loginSuccess(res))
-              .catch(err => this.requestFailed(err))
-              .finally(() => {
+              .catch(err => {
+                this.requestFailed(err)
                 state.loginBtn = false

Review comment:
       this would set loginBtn to false on error?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] utchoang commented on a change in pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
utchoang commented on a change in pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#discussion_r600074511



##########
File path: ui/src/views/auth/Login.vue
##########
@@ -189,8 +189,8 @@ export default {
             }
             Login(loginParams)
               .then((res) => this.loginSuccess(res))
-              .catch(err => this.requestFailed(err))
-              .finally(() => {
+              .catch(err => {
+                this.requestFailed(err)
                 state.loginBtn = false

Review comment:
       @rhtyd I think it is correct because the goal is to only re-enable the button when it gets an error to perform click/submit again.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on a change in pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
rhtyd commented on a change in pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#discussion_r600212638



##########
File path: ui/src/views/auth/Login.vue
##########
@@ -189,8 +189,8 @@ export default {
             }
             Login(loginParams)
               .then((res) => this.loginSuccess(res))
-              .catch(err => this.requestFailed(err))
-              .finally(() => {
+              .catch(err => {
+                this.requestFailed(err)
                 state.loginBtn = false

Review comment:
       Thanks for explaining, I thought setting that to 'true' would mean enabling the button.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#issuecomment-804778356


   @davidjumani a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#issuecomment-804781770


   UI build: :heavy_check_mark:
   Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/4857 (SL-JID-52)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd merged pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
rhtyd merged pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] utchoang commented on a change in pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
utchoang commented on a change in pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#discussion_r600074511



##########
File path: ui/src/views/auth/Login.vue
##########
@@ -189,8 +189,8 @@ export default {
             }
             Login(loginParams)
               .then((res) => this.loginSuccess(res))
-              .catch(err => this.requestFailed(err))
-              .finally(() => {
+              .catch(err => {
+                this.requestFailed(err)
                 state.loginBtn = false

Review comment:
       @rhtyd I think it is correct because the goal is to only re-enable the button when it gets an error to perform click/submit again. And when success is not needed, because it will be redirected to the dashboard.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] davidjumani commented on a change in pull request #4857: ui: Disable login button until redirected

Posted by GitBox <gi...@apache.org>.
davidjumani commented on a change in pull request #4857:
URL: https://github.com/apache/cloudstack/pull/4857#discussion_r600155644



##########
File path: ui/src/views/auth/Login.vue
##########
@@ -189,8 +189,8 @@ export default {
             }
             Login(loginParams)
               .then((res) => this.loginSuccess(res))
-              .catch(err => this.requestFailed(err))
-              .finally(() => {
+              .catch(err => {
+                this.requestFailed(err)
                 state.loginBtn = false

Review comment:
       What he said ^^




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org