From dd1180ab30f0bc3106ca6be00a88b2e1e3344637 Mon Sep 17 00:00:00 2001 From: Andromeda Yelton Date: Tue, 12 Mar 2013 16:12:11 -0400 Subject: [PATCH 1/3] notification description field limited to 100 characters --- core/signals.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/signals.py b/core/signals.py index 171236ee..8200b724 100644 --- a/core/signals.py +++ b/core/signals.py @@ -92,7 +92,7 @@ def create_notice_types(app, created_models, verbosity, **kwargs): notification.create_notice_type("wishlist_successful", _("Successful Campaign"), _("An ungluing campaign that you have supported or followed has succeeded.")) notification.create_notice_type("wishlist_unsuccessful", _("Unsuccessful Campaign"), _("An ungluing campaign that you supported didn't succeed this time.")) notification.create_notice_type("wishlist_updated", _("Campaign Updated"), _("An ungluing campaign you support has been updated."), default = 1) - notification.create_notice_type("wishlist_message", _("Campaign Communication"), _("You have a private message from unglue.it staff or the rights holder about a campaign on your wishlist.")) + notification.create_notice_type("wishlist_message", _("Campaign Communication"), _("You have a private message from unglue.it staff or the rights holder about a book on your wishlist.")) notification.create_notice_type("wishlist_price_drop", _("Campaign Price Drop"), _("An ungluing campaign you're interested in has a reduced target."), default = 1) notification.create_notice_type("wishlist_unglued_book_released", _("Unglued Book!"), _("A book you wanted is now available to be downloaded.")) notification.create_notice_type("pledge_you_have_pledged", _("Thanks For Your Pledge!"), _("Your ungluing pledge has been entered.")) From 581944c3f9f93143679a685c3b767e64d31340e8 Mon Sep 17 00:00:00 2001 From: eric Date: Tue, 12 Mar 2013 23:11:59 -0400 Subject: [PATCH 2/3] fix bug on cancel pledge --- frontend/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/views.py b/frontend/views.py index 3dade3f7..6dcf8fa0 100755 --- a/frontend/views.py +++ b/frontend/views.py @@ -1178,7 +1178,7 @@ class PledgeCancelView(FormView): # send a notice out that the transaction has been canceled -- leverage the pledge_modify notice for now # BUGBUG: should have a pledge cancel notice actually since I think it's different from regluit.payment.signals import pledge_modified - pledge_modified.queue(sender=self, transaction=transaction, up_or_down="canceled") + pledge_modified.send(sender=self, transaction=transaction, up_or_down="canceled") logger.info("pledge_modified notice for cancellation: sender {0}, transaction {1}".format(self, transaction)) return HttpResponseRedirect(reverse('work', kwargs={'work_id': campaign.work.id})) else: From 037c917d74a3b77097fe8c78a1540fab2b52217f Mon Sep 17 00:00:00 2001 From: Raymond Yee Date: Tue, 12 Mar 2013 20:37:53 -0700 Subject: [PATCH 3/3] Change expected http response code from 302 to 200 on wishlist add to match change in UI. --- frontend/tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/tests.py b/frontend/tests.py index db4500b4..0de70c7f 100755 --- a/frontend/tests.py +++ b/frontend/tests.py @@ -31,7 +31,7 @@ class WishlistTests(TestCase): # add a book to the wishlist r = self.client.post("/wishlist/", {"googlebooks_id": "2NyiPwAACAAJ"}, HTTP_X_REQUESTED_WITH="XMLHttpRequest") - self.assertEqual(r.status_code, 302) + self.assertEqual(r.status_code, 200) self.assertEqual(self.user.wishlist.works.all().count(), 1) wished= self.user.wishlist.works.all()[0] # test the work page @@ -138,7 +138,7 @@ class PledgingUiTests(TestCase): # load a Work by putting it on the User's wishlist r = self.client.post("/wishlist/", {"googlebooks_id": "2NyiPwAACAAJ"}, HTTP_X_REQUESTED_WITH="XMLHttpRequest") - self.assertEqual(r.status_code, 302) + self.assertEqual(r.status_code, 200) self.assertEqual(self.user.wishlist.works.all().count(), 1) wished= self.user.wishlist.works.all()[0] # test the work page