Skip to content
This repository has been archived by the owner on Jun 23, 2023. It is now read-only.

Commit

Permalink
Don't show update all button once it's clicked (#41)
Browse files Browse the repository at this point in the history
  • Loading branch information
mayankchhabra authored Sep 22, 2022
1 parent dc1cce4 commit 38f5170
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/views/AppStore/AppStore.vue
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@
</div>
<div class="d-flex align-items-center justify-content-between w-100 px-2 px-lg-3">
<h2 class="mr-auto text-lowercase">Updates</h2>
<b-button variant="outline-primary" class="px-2" size="sm" @click="updateAll" v-if="canUpdateAll">Update all</b-button>
<b-button variant="outline-primary" class="px-2" size="sm" @click="updateAll" v-show="canUpdateAll && !isUpdatingAll">Update all</b-button>
</div>
</div>
</template>
Expand Down Expand Up @@ -196,7 +196,9 @@ import UpdateAppsApp from "@/views/AppStore/UpdateAppsApp";
export default {
data() {
return {};
return {
isUpdatingAll: false,
};
},
computed: {
...mapState({
Expand Down Expand Up @@ -237,6 +239,7 @@ export default {
this.$store.dispatch("apps/updateAppStoreScrollTop", event.target.scrollTop);
},
updateAll: function() {
this.isUpdatingAll = true;
this.appsWithUpdate
.forEach(app => {
// Call updateApp() within each UpdateAppsApp component
Expand Down

0 comments on commit 38f5170

Please sign in to comment.