Commit Graph

1937 Commits

Author SHA1 Message Date
Travis cd545e08d5 Implementing retries on failed user updates when finishing a quest (#8251)
* Implementing retries on failed user updates when finishing a quest. fixes #8035

* Refactoring mongo db retries to use the same as code path as original call and moving retries to count based over time based.

* Adding tests for retry logic and updating retries to happen recursively

* Moving callbacks to promises and other tweaks according to pr.

* Chaging mongoose promise to use .catch() functionality

* If all retries fail, the system will now throw an error instead of returning an error message.
2016-12-09 11:30:17 -08:00
Matteo Pagliazzi 1de4ab3612 client: namespaces for actions and getteters 2016-12-08 23:01:59 -08:00
Matteo Pagliazzi 3e6691dbbb client: test: getters 2016-12-06 18:53:03 -08:00
Matteo Pagliazzi 046761b9aa client: reorganize filters and add tests 2016-12-06 18:27:49 -08:00
Travis 6a63f080ad New feature that notifies a user when their group invite is accepted. (#8244)
* New notification feature that notifies a user when their group invite is accepted. fixes #7788

* Updating to a modal instead of a popup notification

* Making a generic modal template and using it for notifications of group invitation acceptance.

* Working with paglias's comments for doing translation server side.

* Final changes based on pr comments.
2016-12-01 19:04:57 +01:00
Keith Holliday bab41647f5 Fixed lint issues 2016-11-29 09:18:07 -06:00
Keith Holliday 8582a67308 Fixed broken tests and style changes 2016-11-29 08:53:36 -06:00
Keith Holliday 1d2482f8bc Fixed linting issues 2016-11-28 21:24:25 -06:00
Keith Holliday f4cf906127 Added remove when previous login incentive notifications exist 2016-11-28 21:19:53 -06:00
Alyssa Batula 7eeeda2aae Send a message to the party chat when a quest is aborted, fixes #4879 (#8150)
* Send a message to the party chat when a quest is aborted

* Added test cases for sending a message to party when quest is aborted

* Restore Group.prototype.sendChat after aborted quest test
2016-11-26 17:48:42 +10:00
Sabe Jones 25b0ff38c4 Login Incentives (#8230)
* feat(incentives): login bennies WIP

* feat(content): incentive prize content WIP

* fix(content): placeholders pass tests

* WIP(content): Bard instrument placeholder

* feat(content): Incentives build

* chore(sprites): compile
and fix some strings

* WIP(incentives): quests and backgrounds

* fix(quests): correct buy/launch handling

* [WIP] Incentives rewarding (#8226)

* Added login incentive rewards

* Updated incentive rewards

* Added incentive modal and updated notification structure

* Added analytics to sleeping

* Added login incentives to user analytics

* Fixed unit tests and ensured that prizes are incremented and not replaced

* Updated style of daily login incentive modal

* Added rewards modal

* Added translations

* Added loigin incentive ui elements to profile

* Updated login incentives structure and abstracted to common.content

* Added dynamic display for login incentives on profile

* Added purple potion image

* Updated daily login modal

* Fixed progress calculation

* Added bard gear

* Updated login incentive rewards

* Fixed styles and text

* Added multiple read for notifications

* Fixed lint issues

* Fixed styles and added 50 limit

* Updated quest keys

* Added login incentives reward page

* Fixed tests

* Fixed linting and tests

* Read named notifications route. Add image for backgrounds

* Fixed style issues and added tranlsations to login incentive notification

* Hided abiltiy to purchase incentive backgrounds and added message to detail how to unlock

* Updated awarded message

* Fixed text and updated progress counter to display better

* Fixed purple potion reward text

* Fixed check in backgrouns reward text

* fix(quest): pass tests

* Added display of multiple rewards

* Updated modal styles

* Fixed neagtive 50 issue

* Remvoed total count from daily login incentives modal

* Fixed magic paw display

* fix(awards): give bunnies again

* WIP(incentives): more progress on BG shop

* fix(incentives): actually award backgrounds

* fix(incentives): more BG fixy

* fix(backgrounds): don't gem-buy checkin bgs

* Added dust bunny notification

* fix(incentives): don't redisplay bunny award

* chore(news): Bailey
and different promo sprite
2016-11-23 19:34:09 -06:00
Sabe Jones dcc06931cc fix(test): disable unreliable XML test 2016-11-23 23:16:16 +00:00
Matteo Pagliazzi 4b9fe49e3a skip randomly failing test 2016-11-23 14:46:23 +01:00
Sabe Jones 80e9735b28 Turkey Day 2016 (#8231)
* feat(event): Turkey Day 2016

* fix(test): allow for free pet
2016-11-22 20:00:10 -06:00
Matteo Pagliazzi 64754777ed New Client: working navigation (#8131)
* initial work

* new client: working navigation and tasks showing up

* finish header menu and add avatar component

* fix sprites in new client

* initial header version

* initial styling for top menu

* more progress on the header menu

* almost complete menu and avatar

* correctly apply active class for /social and /help

* fix header colors and simplify css

* switch from Roboto to native fonts

* remove small avatar and add viewport

* fixes

* fix user menu with and progress bars

* fix avatar rendeting

* move bars colors to theme

* add site overrides

* fix tests

* shrinkwrap

* fix sprites path

* another try at fixing the sprites path

* another try at fixing the sprites path
2016-11-18 19:20:25 +01:00
shalott 8c4f35daf4 Fixing test failure
This test seems to occasionally start failing (another coder reported the same thing happening to them in the blacksmiths’ guild) because the order in which the tasks are created can sometimes not match the order in the array. So I have sorted the tasks array after creation by the task name to ensure a consistent ordering, and slightly reordered the expect statements to match.
2016-11-16 21:52:23 +01:00
Alys 5a150ebc5b change '/group/' to '/groups/' in docs for /api/v3/challenges/groups/:groupId 2016-11-13 17:43:52 +10:00
Keith Holliday cbe1892b50 Added note sync when user adds task to challenge, tests, and fixed challenge tests (#8200) 2016-11-12 23:48:22 +01:00
Keith Holliday 13df60e0dd Group approval ui (#8184)
* Added all ui components back

* Added group ui items back and initial group approval directive

* Added ability to mark tasks as requires approval. Added approvals ctrl. Added get approvals method to tasks service

* Added approval list view with approving functionality

* Added error to produce message when task requests approval

* Added notification display for group approvals

* Fixed notification read and adding task

* Fixed syncing with group approval required

* Added group id to notifications for redirect on client side

* Fixed approval request tests

* Fixed linting issues

* Removed expectation from beforeEach

* Moved string to locale

* Added eslint ignore

* Updated notification for group approved, added new icons, and updated styles

* Hid group plan ui
2016-11-12 23:47:45 +01:00
Romeeka Gayhart 5108480ec5 Get skipped/pending unit tests working for revive (#8193) 2016-11-06 21:17:52 -06:00
Alys 6693e9fca9 replace candy food with normal food and enhance canBuy / canDrop code (#8194)
* change food to normal; add variables to choose type of food; add canBuy, canDrop to cake

* reinstate ability to control canBuy and canDrop separately
2016-11-06 15:33:19 -06:00
Romeeka Gayhart 431bde56d2 Convert test UUID to string to avoid test error (#8195) 2016-11-05 23:53:11 -04:00
Sabe Jones 49561bfc8c fix(test): accommodate changing seasons 2016-11-04 20:38:29 +00:00
Amanda Furrow 421bd8624c Add flagger language to flag message sent to slack
closes #8179
fixes #8140
2016-11-02 17:28:44 -05:00
Matteo Pagliazzi 18bbdfa84b Merge branch 'group-tasks-approval' of https://github.com/TheHollidayInn/habitrpg into TheHollidayInn-group-tasks-approval2 2016-11-01 21:55:18 +01:00
Keith Holliday d8c37f6e2d Group plan subscription (#8153)
* Added payment to groups and pay with group plan with Stripe

* Added edit card for Stripe

* Added stripe cancel

* Added subscribe with Amazon payments

* Added Amazon cancel for group subscription

* Added group subscription with paypal

* Added paypal cancel

* Added ipn cancel for Group plan

* Added a subscription tab and hid only the task tab when group is not subscribed

* Fixed linting issues

* Fixed tests

* Added payment unit tests

* Added back refresh after stripe payment

* Fixed style issues

* Limited grouop query fields and checked access

* Abstracted subscription schema

* Added year group plan and more access checks

* Maded purchase fields private

* Removed id and timestampes

* Added else checks to ensure user subscription is not altered. Removed active field from group model

* Added toJSONTransform function

* Moved plan active check to other toJson function

* Added check to see if purchaed has been populated

* Added purchase details to private

* Added correct data usage when paying for group sub
2016-11-01 21:51:30 +01:00
Keith Holliday 6801dae75d Fixed history test 2016-10-30 03:23:01 -05:00
Keith Holliday 59e1de6771 Moved approval to subdoc 2016-10-29 14:19:16 -05:00
Keith Holliday 5b240a1950 Updated notification name and other minor fixes 2016-10-29 14:19:16 -05:00
Keith Holliday 3ec3722038 Moved approval fields to group subdoc 2016-10-29 14:19:16 -05:00
Keith Holliday d798ebadfe Fixed line endings 2016-10-29 14:19:16 -05:00
Keith Holliday 6cbddef627 Added get approvals route 2016-10-29 14:19:16 -05:00
Keith Holliday 016de411c9 Added notifications 2016-10-29 14:19:16 -05:00
Keith Holliday 2173f53883 Added fields for more approver details 2016-10-29 14:19:15 -05:00
Keith Holliday f2e5bc52e5 Added requested approval fields and logic 2016-10-29 14:19:15 -05:00
Keith Holliday ad5045bc09 Added git score approved task test 2016-10-29 14:19:15 -05:00
Keith Holliday 9b515ebdd1 Added task approve route 2016-10-29 14:19:15 -05:00
Keith Holliday 97bf9ee8e8 Added inital group task approval 2016-10-29 14:19:15 -05:00
Travis 0bfc9d9516 fix: allows user to save an alias and checklistCollapsed properties of a challenge task. fixes #7875 (#8170) 2016-10-25 21:47:49 -05:00
Sabe Jones d323be19c6 Mystery Items 2016/10 (#8169)
* feat(content): mystery items 2016-10

* chore(news): Bailey 2016-10-25
Also ends the Enchanted Armoire A/B test.

* fix(armoire): failing tests from A/B conclusion
2016-10-25 16:16:00 -05:00
Blade Barringer ba19c00617 Setup up non-API tests to not need server and mongo running
chore(travis): Build files before running tests

chore(travis): require server for api tests
2016-10-22 08:14:00 -05:00
Blade Barringer f9595af8a5 Re-enable armoire tests 2016-10-20 22:04:24 -05:00
Alyssa Batula d2756278c3 Only unequip Gen 1 pets/mounts when releasing pets/mounts, fixes #5366 (#8119)
* Only unequip Gen 1 pets/mounts when releasing pets/mounts

* Changed mount declaration to match releasePets

* Check if a pet/mount is a drop type instead of checking for its name in the list of pets

* Changed references to pet and mount to petInfo and mountInfo for consistency with releasePets and releaseMounts

* Test that releasePets, releaseMounts, and releaseBoth do not unequip quest pets

* Fixed test names, and tests verify that a pet/mount is/is not a drop pet/mount on release

* Removed unneeded comments
2016-10-20 22:00:15 -05:00
Blade Barringer 2e2dc179c4 chore: pend armoire test 2016-10-20 19:30:22 -05:00
Blade Barringer d5170251c0 fix: remove unneeded Math.random test 2016-10-20 17:11:28 -05:00
MathWhiz d4aac1ee4b Documentation - coupon
closes #8109
2016-10-19 21:31:07 -05:00
Thomas Gamble cb38475765 delete unread messages when a user leaves a group
closes #7955
closes #7965
2016-10-16 22:01:34 -05:00
Sabe Jones 009ab26711 Add special spells to Seasonal Shop API (#8138)
* WIP(shops): add spells to Seasonal API

* refactor(shops): remove superfluous if

* feat(shops): handle spell purchasing

* fix(test): proper required fields check
Also corrects a linting error.

* refactor(shops): use constants
2016-10-13 17:53:02 -05:00
Blade Barringer 8db6b7c6cb fix(api): Allow x-client to be set in cors middleware (#8117)
* fix(api): Allow x-client to be set in cors middleware

* chore: update cors middlware tests
2016-10-10 17:35:00 -05:00
Sabe Jones d40c923e6e refactor(test): less clunky timestamp conv 2016-10-10 16:02:08 +00:00