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

23969 do not authorize button spinner disabled after clicking #701

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "business-filings-ui",
"version": "7.4.1",
"version": "7.4.2",
"private": true,
"appName": "Filings UI",
"sbcName": "SBC Common Components",
Expand Down
14 changes: 14 additions & 0 deletions src/components/Dashboard/TodoList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,9 @@
<v-btn
class="ma-1 affiliation-invitation-action-button"
color="primary"
:loading="isAuthorizeLoading"
:disabled="isAuthorizeLoading || isDoNotAuthorizeLoading"
severinbeauvais marked this conversation as resolved.
Show resolved Hide resolved
@click.native.stop="authorizeAffiliationInvitation(true, item)"

Check warning on line 315 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Authorize</span>
</v-btn>
Expand All @@ -318,7 +320,9 @@
class="ma-1 affiliation-invitation-action-button"
outlined
color="primary"
:loading="isDoNotAuthorizeLoading"
:disabled="isDoNotAuthorizeLoading || isAuthorizeLoading"
@click.native.stop="authorizeAffiliationInvitation(false, item)"

Check warning on line 325 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Do not authorize</span>
</v-btn>
Expand Down Expand Up @@ -392,7 +396,7 @@
<v-btn
class="btn-draft-delete"
color="primary"
@click.native.stop="confirmDeleteDraft(item)"

Check warning on line 399 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Delete draft</span>
</v-btn>
Expand All @@ -404,7 +408,7 @@
class="btn-draft-resume"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumeFiling(item)"

Check warning on line 411 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<template v-if="EnumUtilities.isTypeAmalgamationApplication(item) && item.isEmptyFiling">
<span>Fill out Amalgamation Application</span>
Expand Down Expand Up @@ -493,7 +497,7 @@
:class="{ 'cancellable' : isCancellableTodoItem(item) }"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumePayment(item)"

Check warning on line 500 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Change Payment Type</span>
</v-btn>
Expand All @@ -503,7 +507,7 @@
:class="{ 'cancellable' : isCancellableTodoItem(item) }"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumePayment(item)"

Check warning on line 510 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Resume Payment</span>
</v-btn>
Expand All @@ -521,7 +525,7 @@
color="primary"
:disabled="!item.enabled"
v-on="on"
@click.native.stop

Check warning on line 528 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<v-icon>mdi-menu-down</v-icon>
</v-btn>
Expand All @@ -543,7 +547,7 @@
class="btn-retry-payment"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumePayment(item)"

Check warning on line 550 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Retry Payment</span>
</v-btn>
Expand All @@ -560,7 +564,7 @@
class="btn-draft-resume"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumeFiling(item)"

Check warning on line 567 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Resume</span>
</v-btn>
Expand All @@ -572,7 +576,7 @@
class="btn-draft-resume rounded-r"
color="primary"
:disabled="!item.enabled"
@click.native.stop="doResumeFiling(item)"

Check warning on line 579 in src/components/Dashboard/TodoList.vue

View workflow job for this annotation

GitHub Actions / business-filings-ui-ci / linting-npm (20.5.1)

'.native' modifier on 'v-on' directive is deprecated
>
<span>Make Changes</span>
</v-btn>
Expand Down Expand Up @@ -789,6 +793,8 @@
panel: number = null // currently expanded panel
checkTimer = null // may be type number or NodeJS.Timeout
inProcessFiling: number = null
isAuthorizeLoading = false
isDoNotAuthorizeLoading = false
fetchAffiliationInvitationsErrorDialog = false
authorizeAffiliationInvitationErrorDialog = false

Expand Down Expand Up @@ -1099,6 +1105,11 @@
}

async authorizeAffiliationInvitation (isAuthorized: boolean, affiliationInvitationTodo: TodoItemIF) {
if (isAuthorized) {
this.isAuthorizeLoading = true
} else {
this.isDoNotAuthorizeLoading = true
}
const response = await AuthServices.authorizeAffiliationInvitation(
this.getAuthApiUrl,
affiliationInvitationTodo.affiliationInvitationDetails.id,
Expand All @@ -1108,6 +1119,9 @@
console.log('failed the call for authorization of affiliation invitation', err)
this.authorizeAffiliationInvitationErrorDialog = true
return null
}).finally(() => {
this.isAuthorizeLoading = false
this.isDoNotAuthorizeLoading = false
})

const index = this.todoItems.indexOf(affiliationInvitationTodo)
Expand Down
Loading