diff --git a/website/client/components/notifications.vue b/website/client/components/notifications.vue index c5945ceec4..fe375482b6 100644 --- a/website/client/components/notifications.vue +++ b/website/client/components/notifications.vue @@ -373,8 +373,8 @@ export default { this.$store.state.isRunningYesterdailies = true; if (!this.user.needsCron) { - this.handleUserNotifications(this.user.notifications); this.scheduleNextCron(); + this.handleUserNotifications(this.user.notifications); return; } @@ -415,8 +415,8 @@ export default { this.showLevelUpNotifications(this.user.stats.lvl); } - this.handleUserNotifications(this.user.notifications); this.scheduleNextCron(); + this.handleUserNotifications(this.user.notifications); }, transferGroupNotification (notification) { this.$store.state.groupNotifications.push(notification); @@ -424,6 +424,8 @@ export default { async handleUserNotifications (after) { if (!after || after.length === 0 || !Array.isArray(after)) return; + if (this.$store.state.isRunningYesterdailies) return; + let notificationsToRead = []; let scoreTaskNotification = []; diff --git a/website/client/components/shops/buyModal.vue b/website/client/components/shops/buyModal.vue index e896119a8d..77eda49fd8 100644 --- a/website/client/components/shops/buyModal.vue +++ b/website/client/components/shops/buyModal.vue @@ -42,10 +42,10 @@ ) .purchase-amount(:class="{'notEnough': !this.enoughCurrency(getPriceClass(), item.value * selectedAmountToBuy)}") - .how-many-to-buy(v-if='item.purchaseType !== "gear"') + .how-many-to-buy(v-if='["fortify", "gear"].indexOf(item.purchaseType) === -1') strong {{ $t('howManyToBuy') }} div(v-if='item.purchaseType !== "gear"') - .box + .box(v-if='["fortify", "gear"].indexOf(item.purchaseType) === -1') input(type='number', min='0', v-model='selectedAmountToBuy') span.svg-icon.inline.icon-32(aria-hidden="true", v-html="icons[getPriceClass()]") span.value(:class="getPriceClass()") {{ item.value }} diff --git a/website/client/store/actions/shops.js b/website/client/store/actions/shops.js index 8a7acbe4ea..cdd3d24a32 100644 --- a/website/client/store/actions/shops.js +++ b/website/client/store/actions/shops.js @@ -126,9 +126,13 @@ export async function genericPurchase (store, params) { await buyArmoire(store, params); return; case 'fortify': { - let rerollResult = rerollOp(store.state.user.data); + let rerollResult = rerollOp(store.state.user.data, store.state.tasks.data); - axios.post('/api/v3/user/reroll'); + await axios.post('/api/v3/user/reroll'); + await Promise.all([ + store.dispatch('user:fetch', {forceLoad: true}), + store.dispatch('tasks:fetchUserTasks', {forceLoad: true}), + ]); return rerollResult; }