feat(admin): interactive subscription section fields

This commit is contained in:
SabreCat
2022-08-30 16:55:10 -05:00
parent 09d6dae75c
commit ae23ac12ff
3 changed files with 121 additions and 45 deletions

View File

@@ -273,6 +273,15 @@ api.updateHero = {
hero.balance = updateData.balance;
}
if (updateData.purchased && updateData.purchased.plan) {
if (updateData.purchased.plan.gemsBought) {
hero.purchased.plan.gemsBought = updateData.purchased.plan.gemsBought;
}
if (updateData.purchased.plan.consecutive && updateData.purchased.plan.consecutive.trinkets) {
hero.purchased.plan.consecutive.trinkets = updateData.purchased.plan.consecutive.trinkets;
}
}
// give them gems if they got an higher level
// tier = level in this context
let newTier = updateData.contributor && updateData.contributor.level;