mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-14 10:12:21 +00:00
feat(event): Habit Birthday 2015
This commit is contained in:
parent
01d695cae5
commit
4ebc2953f5
3 changed files with 44 additions and 2 deletions
39
migrations/20150130_birthday_goodies.js
Normal file
39
migrations/20150130_birthday_goodies.js
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
db.users.update(
|
||||
{'items.gear.owned.armor_special_birthday':{$ne:null}},
|
||||
{$set:{'items.gear.owned.armor_special_birthday2015':false}},
|
||||
{multi:1}
|
||||
)
|
||||
|
||||
db.users.update(
|
||||
{'items.gear.owned.armor_special_birthday':null},
|
||||
{$set:{'items.gear.owned.armor_special_birthday':false}},
|
||||
{multi:1}
|
||||
)
|
||||
|
||||
db.users.update({},{$inc:{
|
||||
'items.food.Cake_Skeleton':1,
|
||||
'items.food.Cake_Base':1,
|
||||
'items.food.Cake_CottonCandyBlue':1,
|
||||
'items.food.Cake_CottonCandyPink':1,
|
||||
'items.food.Cake_Shade':1,
|
||||
'items.food.Cake_White':1,
|
||||
'items.food.Cake_Golden':1,
|
||||
'items.food.Cake_Zombie':1,
|
||||
'items.food.Cake_Desert':1,
|
||||
'items.food.Cake_Red':1
|
||||
}},{multi:1})
|
||||
|
||||
db.users.update(
|
||||
{'profile.achievements.habitBirthday':true},
|
||||
{$set:{
|
||||
'profile.achievements.habitBirthday':null,
|
||||
'profile.achievements.habitBirthdays':1
|
||||
}},
|
||||
{multi:1}
|
||||
)
|
||||
|
||||
db.users.update(
|
||||
{},
|
||||
{$inc:{'profile.achievements.habitBirthdays':1}},
|
||||
{multi:1}
|
||||
)
|
||||
|
|
@ -50,6 +50,7 @@ var UserSchema = new Schema({
|
|||
rebirthLevel: Number,
|
||||
perfect: Number,
|
||||
habitBirthday: Boolean,
|
||||
habitBirthdays: Number,
|
||||
valentine: Number,
|
||||
costumeContest: Boolean,
|
||||
nye: Number
|
||||
|
|
|
|||
|
|
@ -168,11 +168,13 @@ div(ng-if='profile.achievements.spookDust')
|
|||
=env.t('alarmingFriendsText', {spookDust: "{{profile.achievements.spookDust}}"})
|
||||
hr
|
||||
|
||||
div(ng-if='::profile.achievements.habitBirthday')
|
||||
div(ng-if='::profile.achievements.habitBirthdays')
|
||||
.achievement.achievement-habitBirthday
|
||||
h5=env.t('habitBirthday')
|
||||
small
|
||||
small(ng-if='::profile.achievements.habitBirthdays == 1')
|
||||
=env.t('habitBirthdayText')
|
||||
small(ng-if='::profile.achievements.habitBirthdays > 1')
|
||||
=env.t('habitBirthdayPluralText', {number: "{{profile.achievements.habitBirthdays}}"})
|
||||
hr
|
||||
|
||||
div(ng-if='::profile.achievements.valentine')
|
||||
|
|
|
|||
Loading…
Reference in a new issue