Commit Graph

390 Commits (b35aa2ce933c86bfb74d08ab252af06890963cf8)

Author SHA1 Message Date
eric 6a1646f749 fixed bad method signature 2012-10-12 22:25:48 -04:00
eric be3f989d36 although "up_or_down" not distinguished, should make it return what it says it is 2012-10-12 18:18:55 -04:00
eric 7d21e60984 if view expects one acct peruser, dont give it multiple accounts! [#36797599] 2012-10-12 16:03:50 -04:00
Raymond Yee b0858ea12e add a payment.manager.PaymentManager.retrieve_or_make_accounts
Made a change in make_account signature to allow for token=None
2012-10-12 07:44:50 -07:00
Raymond Yee b281aca869 [#37567927] enforce constraint of at most 1 active Account / user of given host
-> migration was missing before from an earlier commit -- add in now.
2012-10-11 16:36:24 -07:00
Raymond Yee 9d17f93fac Now I have some tests to show how to trigger all of the stripe CardError except invalid_number, expired_card, and processing_error -- ones that we'll need to simulate in some other way 2012-10-08 13:08:28 -07:00
Raymond Yee 447b5973c2 Add ProcessorError
Start elaborating StripeClient testing
2012-10-06 09:51:43 -07:00
Raymond Yee 5df3ab23ab Merge branch 'master' into relaunch_ry 2012-10-04 09:35:54 -07:00
eric 75e0a4c534 clean up two loose ends 2012-10-03 17:36:17 -04:00
eric 462011ed7e add_pledge_badge was just a bug waiting to happen 2012-10-03 17:06:51 -04:00
Raymond Yee f9e81d1741 syntax error fix 2012-10-03 09:24:04 -07:00
eric 57dc500643 Revert "Revert "wired badge awarding into pledge modified and pledge complete signals""
This reverts commit 863055c305.
2012-10-03 08:57:24 -04:00
eric 863055c305 Revert "wired badge awarding into pledge modified and pledge complete signals"
This reverts commit 759e39f61d.
2012-10-03 08:56:29 -04:00
eric 65998ac219 this belongs with last commit 2012-10-02 23:51:25 -04:00
eric 73910ae8a0 To get credit module working again, had to move some methods into an object that inherits from a base class
So now all payment processor specific methods are on a Processor
object,
2012-10-02 23:49:19 -04:00
eric 7a1cf969ca fixed circular import problems [finish #37053797] 2012-10-02 22:14:40 -04:00
Raymond Yee e6b5146dff the Stripe api keys for nonprofit partner should be gone 2012-10-02 12:06:38 -07:00
Raymond Yee 89b3b5c599 [#37053797] reverting stripelib.py -- Sn tests run but django command test_stripe_charge fails: done so Eric can fix circular import issue:
>>> >>> >>> (regluitdj14)raymond-yees-computer:regluit raymondyee$ django-admin.py test_stripe_charge
Traceback (most recent call last):
  File "/Users/raymondyee/.virtualenvs/regluitdj14/bin/django-admin.py", line 5, in <module>
    management.execute_from_command_line()
  File "/Users/raymondyee/.virtualenvs/regluitdj14/lib/python2.7/site-packages/django/core/management/__init__.py", line 443, in execute_from_command_line
    utility.execute()
  File "/Users/raymondyee/.virtualenvs/regluitdj14/lib/python2.7/site-packages/django/core/management/__init__.py", line 382, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/Users/raymondyee/.virtualenvs/regluitdj14/lib/python2.7/site-packages/django/core/management/__init__.py", line 261, in fetch_command
    klass = load_command_class(app_name, subcommand)
  File "/Users/raymondyee/.virtualenvs/regluitdj14/lib/python2.7/site-packages/django/core/management/__init__.py", line 69, in load_command_class
    module = import_module('%s.management.commands.%s' % (app_name, name))
  File "/Users/raymondyee/.virtualenvs/regluitdj14/lib/python2.7/site-packages/django/utils/importlib.py", line 35, in import_module
    __import__(name)
  File "/Users/raymondyee/C/src/Gluejar/regluit/payment/management/commands/test_stripe_charge.py", line 2, in <module>
    from regluit.payment import stripelib
  File "/Users/raymondyee/C/src/Gluejar/regluit/payment/stripelib.py", line 10, in <module>
    from regluit.payment.models import Account
  File "/Users/raymondyee/C/src/Gluejar/regluit/payment/models.py", line 4, in <module>
    from regluit.core.models import Campaign, Wishlist, Premium, PledgeExtra
  File "/Users/raymondyee/C/src/Gluejar/regluit/core/models.py", line 998, in <module>
    from regluit.payment.manager import PaymentManager
  File "/Users/raymondyee/C/src/Gluejar/regluit/payment/manager.py", line 2, in <module>
    from regluit.payment.models import Transaction, Receiver, PaymentResponse
ImportError: cannot import name Transaction
2012-10-02 12:02:45 -07:00
Raymond Yee 72a440383d a django command to do a test charge 2012-10-02 11:49:17 -07:00
Raymond Yee 9b42c0ccd9 Merge branch 'master' into relaunch_ry
Conflicts:
	requirements_versioned.pip
2012-10-02 10:18:24 -07:00
Raymond Yee 27d0a808e0 get rid of more paypal references 2012-10-02 10:16:34 -07:00
Raymond Yee 166afece62 made some changes to reduce the likelihood of circular import dependencies in stripe code.
Made sure there is a core_key table in campaidgn_starter sql
2012-10-01 16:38:51 -07:00
eric 759e39f61d wired badge awarding into pledge modified and pledge complete signals 2012-10-01 18:28:26 -04:00
Raymond Yee 9e048c44f5 Get rid of print statement 2012-09-28 10:12:25 -07:00
Raymond Yee 3b04ddb4a9 Merge branch 'relaunch' into relaunch_ry 2012-09-27 14:07:47 -07:00
eric 880a9f14bd now adding credit records in migration [start #36325665]
that wasn't so hard
2012-09-27 12:58:47 -04:00
Raymond Yee 4a10edce1d [#36469239] Now handles modifications where new amount > previous amount and cancellation of pledge 2012-09-27 09:32:29 -07:00
Raymond Yee 8bd7a5eb65 [deliver #36743191] move stripe implementation UI back to stripe.js 2012-09-26 15:03:46 -07:00
Raymond Yee 1ab2383fec Reverting to using stripe.js on stripe/test as a stepping stone to changing fund_the_pledge.html 2012-09-26 13:52:36 -07:00
eric b75bb0c3a6 now adding credit records in migration [start #36325665]
that wasn't so hard
2012-09-26 13:52:21 -04:00
Raymond Yee 5833f8c0d3 Successfully able to modify transaction from $10 -> $5 in selenium script 2012-09-25 18:30:36 -07:00
Raymond Yee 1cbe62d573 Redirecting to pledge_complete works now -- though there's definitely clean up to do 2012-09-25 11:52:56 -07:00
Raymond Yee d0be2f8761 [#36469239] I can now get a transaction to work via stripelib.py now 2012-09-24 16:29:20 -07:00
Raymond Yee ed6bb5f3e0 BROKEN CODE -- checked in while I switch to working on other branch 2012-09-24 11:30:21 -07:00
Raymond Yee e8494864d4 This code is BROKEN -- but I'm committing this to capture current state of work -- problem is
global name 'stripe_token' is not defined
Exception Location:	/Users/raymondyee/C/src/Gluejar/regluit/payment/stripelib.py in __init__, line 285

when you run the selenium test -- brings up issue of where to create Stripe account in PaymentManager abstraction
2012-09-21 17:40:33 -07:00
Raymond Yee df4e434c45 Fold stripe2.py into stripelib.py 2012-09-21 11:24:42 -07:00
Raymond Yee 980bb218a0 stripe2.Execute actually charges the transaction -- NEED to do some more error checking 2012-09-18 17:56:38 -07:00
Raymond Yee be45a27b45 moving transaction.host None -> PAYMENT_HOST_NONE
a few typos (t->transaction, missing host)
skeleton for stripe2.py -- the module to implement various methods used by payment.manager
2012-09-18 17:01:07 -07:00
Raymond Yee ebb2144055 Responding to Eric's comment: yes Account.date_created should have auto_now_add not auto_add
I modified migration and model.
2012-09-18 08:16:12 -07:00
Raymond Yee 6a650affc8 Now recording pledge as such -- and not charging immediately.
running into exception at https://github.com/Gluejar/regluit/blob/relaunch_ry/payment/manager.py#L554-- have to start implementing a baseclass for stripelib to handle pledge modification
2012-09-17 16:56:07 -07:00
Raymond Yee 69e959a0c8 fleshing out of payment.models.Account 2012-09-17 14:55:28 -07:00
Raymond Yee f08206c5d0 got rid of repeated line (thanks, Eric -- fd1887ea44 (commitcomment-1865176) ) 2012-09-17 10:54:39 -07:00
Raymond Yee fd1887ea44 [#36028929] Work to pull out relevant fields in stripe Customer and Charge model with goal of figuring out which to add to payment.models.{Account | Transaction} 2012-09-14 17:00:21 -07:00
Raymond Yee c545173793 First pass at payment.models.Account 2012-09-13 16:43:54 -07:00
Raymond Yee 2ab1f8c7ea Now creating a charge based on token 2012-09-11 15:17:37 -07:00
Raymond Yee bcceaa719b integrating stripe into fund_the_pledge 2012-09-10 13:17:30 -07:00
Raymond Yee 3417c6372c Allow for passing in card instead of customer for creating stripe charge 2012-09-10 07:23:03 -07:00
Raymond Yee b8c0c8f98e Remove remnants of balanced and wepay that I missed earlier 2012-09-07 13:47:15 -07:00
Raymond Yee f639aa02dd Merge branch 'newpayment' into relaunch
Conflicts:
	frontend/views.py
	payment/manager.py
2012-09-07 13:46:09 -07:00
eric 6762c7d3f2 not really supposed to use Decimal.NaN changed to Decimal('NaN') 2012-09-07 14:40:00 -04:00
Raymond Yee 101cf1e7a0 Removed references to wepay and balanced 2012-09-07 11:31:49 -07:00
eric 0c9d71e4d6 introduce PledgeExtra data object to simplify method calls 2012-09-07 09:46:38 -04:00
eric 790969745e authorize method has changed 2012-09-07 09:45:43 -04:00
eric 4d4e61d338 donation modification now works [#21784207] 2012-09-06 16:55:32 -04:00
eric d63063b740 add missing notification for donation pledges 2012-09-06 13:27:34 -04:00
eric d14548f3af not sure how I missed this bug 2012-09-06 11:36:52 -04:00
eric 8eeadc99d3 woo hoo, credit and donation scaffolding works end to end [#21784207] 2012-09-06 01:01:17 -04:00
Raymond Yee bcbc75ed3d More analysis of what we need to figure out still about stripe. 2012-09-05 16:11:32 -07:00
Raymond Yee e8e6a51068 added a bit of handling of stripe Transfers 2012-08-31 22:59:22 -07:00
Raymond Yee cc8c075842 show error from bad card with stripe call 2012-08-31 11:19:05 -07:00
eric c20e6299bb off to a great start this morning [#16582483] 2012-08-31 11:05:00 -04:00
eric 7afedcd0b6 ack_link now considers anonymous [#16582483] 2012-08-31 10:58:57 -04:00
eric 94270f33c6 add in credi processing; overhaul the PledgeView forms and partition authorize fn in Manager
also removed unused target, lists, ack-link,
2012-08-31 03:16:04 -04:00
eric f299d9ecf7 rip out paypal and amazon code 2012-08-31 03:12:15 -04:00
eric 618eda4aa5 eliminate db skew between prod and relaunch 2012-08-31 02:49:04 -04:00
Raymond Yee 5ac4976950 Basic test for creating Customer, a charge, and then deleting Customer 2012-08-30 16:51:59 -07:00
Raymond Yee e44052712c Now able to wrap stripe functionality in a StripeClient object that is tied to a specific api_key. We use separate api_key for Gluejar and for partner non-profit 2012-08-30 09:24:42 -07:00
Raymond Yee 55d170e798 trivial change to try to trigger the display of the latest commit in github for newpayment 2012-08-29 08:22:35 -07:00
Raymond Yee bd48fdb437 Adding stripe payment tag use 2012-08-29 07:34:20 -07:00
Raymond Yee ec9c6d8fc0 add keys for partner non-profit in stripelib 2012-08-27 07:49:43 -07:00
Raymond Yee 214bc4b9e5 A pass to get a charge iframe show up for wepay 2012-08-20 15:19:27 -07:00
Raymond Yee 6c4f98095f First pass at balancedpayment prototype 2012-08-17 22:57:56 -07:00
Raymond Yee e81a25b1bd Now documenting more of what we need to do next with stripe if we go for a fullblown implementation 2012-08-16 17:24:18 -07:00
Raymond Yee 0d88a395cb First pass at stripe prototype --> /stripe/test will now let you type in a test credit card and display resulting stripeToken 2012-08-16 14:11:32 -07:00
eric 10560fb36b merge credit into relaunch 2012-08-14 21:15:31 -04:00
eric 5362c202bb added management command to create credits, balance notification [#21784207] 2012-08-07 14:12:50 -04:00
eric daf0636c5f back end for credit system [#21784207] 2012-08-06 22:52:45 -04:00
Andromeda Yelton da0f4970c2 improving data flow of acks throughout system 2012-08-06 15:44:43 -04:00
Andromeda Yelton b2161d8936 having acks variables works better if you actually pass them through all stages of the data flow 2012-08-06 13:34:51 -04:00
Andromeda Yelton b041430731 front end for new pledge page, plus just enough back end that it displays 2012-08-01 08:52:39 -04:00
Andromeda Yelton 5855593c5b adding support for acknowledgement fields throughout data pipeline 2012-07-23 08:31:57 -04:00
Andromeda Yelton ef005bbef1 added fields for supporter acknowledgement to class Transaction 2012-07-23 08:12:40 -04:00
Raymond Yee 1097c7891b verify signature for amazon payment return 2012-07-11 21:27:24 -07:00
eric 1764cd62d6 small optimization of supporter count 2012-07-07 16:38:23 -04:00
Raymond Yee 275d127e29 If we're canceling a campaign, record the reason in the transaction.reason as "UNSUCCESSFUL CAMPAIGN" (by default) 2012-06-29 11:11:42 -07:00
eric dfe17f94fa [finish #31637107] refactored transaction summary code, now considers pending and other transactions 2012-06-21 23:20:58 -04:00
eric eec03bd568 unused code 2012-06-21 23:20:58 -04:00
Raymond Yee 25268b34bc [#29500707] Logging an error when an attempt to cancel a transaction does not succeed 2012-06-15 16:59:51 -04:00
Raymond Yee 60434b24ad removing one redundant notice in pledge modify 2012-06-15 13:48:05 -04:00
Raymond Yee 2b7da6e91e First attempt to place the notices properly coming from a pledge modify -- inside payment.manager.cancel_related_transaction -- but current problem is now that we get too many notices 2012-06-15 11:38:38 -04:00
Raymond Yee 9058327370 Modify checkStatus to handle the scenario in which we pass in transactions to check on 2012-06-13 08:35:18 -04:00
Jason 56b6ed57cb Adding better error/exception handling to the amazon payment return URL 2012-06-12 14:52:53 -04:00
Raymond Yee 54e0ce8644 Slight change in amazon.py to avoid circular imports 2012-06-08 15:40:13 -04:00
Raymond Yee 3d07e09424 Merge branch 'master' into fps
Conflicts:
	payment/manager.py
2012-06-08 15:02:57 -04:00
Jason ef1338f7ce Removing extra cancel operations as part of payment checkStatus 2012-06-01 13:42:48 -04:00
Jason 3b7e57ad2a Fixing bug in payment checkStatus code to test for multiple active transactions per campaign 2012-06-01 13:16:52 -04:00
Jason 886280fe21 Adding modifications to payment/pledge modification code. The modify funciton will not cancel the existing pre-approval unless it is fully approved by the user via the co-branded API 2012-06-01 13:13:37 -04:00
Andromeda Yelton 79bdcf3f5c commenting 2012-05-29 21:16:01 -04:00
Andromeda Yelton 1c5264d8a1 removing reference to payment_processor context variable, made irrelevant now that we have transaction.host 2012-05-29 21:01:17 -04:00
Andromeda Yelton 48481bd819 improving ple pledge_modified 2012-05-29 20:50:53 -04:00
Raymond Yee 40d0397bc8 Document the new modification argument for payment.manager.PaymentManager.authorize 2012-05-29 15:16:21 -07:00
Raymond Yee 88d6955685 Name error --> transaction should be t 2012-05-29 11:41:36 -07:00
Andromeda Yelton 2563dda3e5 creating signal for pledge_modified and moving you_have_pledged to signals framework so they interact properly -- at most one sent 2012-05-29 08:54:57 -04:00
Raymond Yee 272d795ded Renaming the current functionality that has been named "cancel" to be "nevermind" because that functionality arose to support users changing their mind
The new PledgeCancel is a placeholder for the functionality I will build next to let users actually cancel existing transactions
Finally, I use  the setting.PAYMENT_PROCESSOR to set the default value of Transaction.host ('paypal' or 'amazon')
2012-05-18 16:59:48 -07:00
Raymond Yee 93aa8d54f2 The selenium test is now working again 2012-05-18 15:06:35 -07:00
Raymond Yee 1ca930440c certain test views that should be on only if DEBUG = True 2012-05-17 13:54:09 -07:00
Raymond Yee 3a6b6e038d First pass at handling the situation in which user interrupts Amazon pledge 2012-05-16 18:16:06 -07:00
eric a6e685618c resolve conflicts 2012-05-15 22:54:23 -04:00
eric 8fd4edbe42 wired pledged_charged notice [finish #28493739] 2012-05-15 22:47:57 -04:00
Raymond Yee 4d9873ccb5 Get rid of an FPS key 2012-05-15 17:46:01 -07:00
Jason 65a7df298d Adding secure IPN url for amazon payments 2012-05-15 16:52:05 -04:00
Jason 7a38bdf91c Merging master -> fps 2012-05-15 16:16:39 -04:00
Raymond Yee b07d6c267d Customize paymentReason for amazon -- in Paypal, we don't have it wired up anywhere yet 2012-05-14 10:15:40 -07:00
Raymond Yee 10db4d0e60 a fab command for pushing keys to ry-dev
corrected a typo in payment/manager.py
2012-05-11 18:54:21 -07:00
Raymond Yee 7b5c2feb35 Added logging on whether loading of FPS keys successful 2012-05-11 11:14:43 -07:00
Jason 55e388b4a3 Adding dynamic module selection for payment modules. Dynamic IPN selection for amazon payments. Bug Fixes 2012-05-11 07:19:13 -04:00
Raymond Yee 9aa586181e Wrapping the import of FPS keys in amazon.py so that things won't die if it gets imported before the database gets set up -- these changes don't break amazon functionality on ry's laptop and hopefully will be ok for jenkins. 2012-05-10 08:08:58 -07:00
Raymond Yee 090d36de66 [#29272807] implemented storage of FPS_* keys in the db 2012-05-09 17:16:49 -07:00
Jason e09418a7a2 Updating paypal code to use common global transaciton status, fixing bugs in paypal interface with abstract payment manager class 2012-05-04 10:30:05 -04:00
Raymond Yee c83aa8615a Removing django-merchant dependency 2012-05-03 10:58:08 -07:00
Raymond Yee 4219149132 Small tweaks to get rid of remnants of PayPal IPN_* variables -- I can now use campaign_admin to actually move fake amazon bucks. Still some IPN_* stuff remaining to clean up. 2012-04-26 19:31:55 +00:00
Raymond Yee 061f656e63 Merge branch 'jkace' of github.com:Gluejar/regluit into fps
Also fixed things so that regluit.test.campaigntest.support_campaign runs for Amazon without error -- though I still need to confirm that the status of transactions properly handled
Next up:  see whether this works for PayPal too.

Conflicts:
	frontend/views.py
2012-04-25 13:10:53 -07:00
Raymond Yee 709cb4ce41 now stuck on the status of an ACTIVE transaction in amazon in campaign_test 2012-04-24 18:03:57 -07:00
Raymond Yee 85797b11a7 incorporating host settings for FPSConnection 2012-04-23 17:12:36 -07:00
Raymond Yee b6e0369b1c Attempting to do a real testpayment 2012-04-23 13:54:37 -07:00
icellama21 df2dc3a8ca Fixing bugs where amazon transaction status REFUNDED was not being set, or was overwriten by PaymentDetails 2012-04-23 15:37:25 -04:00
icellama21 337a692995 Adding redirect to pledge cancel and complete URLs when using amazon payment API 2012-04-23 15:24:16 -04:00
icellama21 b4e424b9f5 Cleaning up amazon IPN logging messages 2012-04-23 15:09:43 -04:00
icellama21 883ec1ce56 Adding uniform logging and boto exception handling to amazon payment code 2012-04-23 15:03:32 -04:00
icellama21 931599f831 Adding PreapprovalDetails for amazon FPS payment system 2012-04-23 14:34:51 -04:00
Raymond Yee 0d3765aa27 Fixed spelling of TRANSACITON_STATUS_COMPLETE_PRIMARY 2012-04-21 16:10:13 -07:00
icellama21 b1dbf8642f Adding payment amazon module - IPN, Refund, Cancel, PaymentDetails support 2012-04-21 01:11:16 -04:00
icellama21 05fa8d83a8 Updating payment manager update_payment for amazon compatibility, fixing status code bugs 2012-04-21 01:10:56 -04:00
icellama21 cf5bb82b23 Adding payment transaction CREATED, FAILED status, fixing typo 2012-04-21 01:09:33 -04:00
icellama21 3796002824 Adding amazon ipn to payment URLs 2012-04-21 01:09:03 -04:00
icellama21 91090c60ac Updating test views to use amazon return URL 2012-04-21 01:08:49 -04:00
icellama21 8ffbd49230 Adding stub for local status in paypal-paymentdetails 2012-04-21 01:08:29 -04:00
icellama21 e8b2619207 Adding payment transaction local_status, local IPN functions, separating payment execute and finish, and updates to the amazon FPS payment system 2012-04-20 15:59:08 -04:00
icellama21 d370091db7 Adding amazon FPS return view, execute and preapproval support 2012-04-18 16:22:00 -04:00
icellama21 125582eebd Adding new amazon payment module 2012-04-18 12:51:54 -04:00
icellama21 03e9947189 Adding basic amazon FPS Pay function 2012-04-18 11:53:13 -04:00
Raymond Yee 697fb826b4 Continuing to take apart the responses from Amazon FPS in response to a PAY operation 2012-04-16 20:58:00 -07:00
Raymond Yee f012f011d2 More RY figuring out basics of FPS 2012-04-16 07:00:46 -07:00
Raymond Yee 86ed171cf3 Now I understand more of the status message that comes back after an attempted authorization at Amazon 2012-04-11 16:02:28 -07:00
Raymond Yee 491bad5c14 Simplified structure of URLs for testfps to:
urlpatterns += patterns('',
         (r'^fps/', include(amazon_fps_obj.urls)),
         url(r'^testfps/$', 'regluit.payment.views.testfps', name='app_offsite_amazon_fps'),
    )
2012-04-11 13:51:20 -07:00
Raymond Yee b808ddbed0 Added URLs needed for the return from Amazon authorization.
Also forgot to put keys in prod.py
2012-04-11 10:37:41 -07:00
Raymond Yee 00511e4730 First pass at trying to integrate Amazon fps 2012-04-11 09:51:18 -07:00
Raymond Yee 723f329e20 PayPal doesn't like iso formatted times using offsets if the offsets are different, as when the two timestamps are on the opposite side of a daylight savings shift. --> switch to sending Zulu time (time formatted in UTC with Z suffix) 2012-03-26 15:02:26 -07:00
Raymond Yee 0e61d7477a [#22756079] Changed name of constants (e.g., IPN_PAY_STATUS_ACTIVE to IPN_PREAPPROVAL_STATUS_ACTIVE to make the meaning of these constants clearer
Also fixed an error in how I'm using transaction management in regluit.test.campaigntest.support_campaign
2012-03-23 11:28:09 -07:00
Raymond Yee ffb7c8cd33 [#23019867] I believe this commit implements the rest of the pledge changing functionality and works as far as I can tell so far.
The one part I don't get yet is why the regluit.test.campaigntest.support_campaign script can successfully drive the browser to create a transction and then
change that pledge to create 2 transactions in total -- and yet until regluit.payment.manager.PaymentManager.check_status is run twice, there seems to be only
one transaction visible to the script.

Does this have to do with Django transactions?  I don't know yet.
2012-03-21 15:06:56 -07:00
Raymond Yee 9629e23b21 [#22755723] First step: adding premium field to Transaction model.
MIGRATION REQUIRED
2012-03-20 15:05:29 -07:00
Raymond Yee 5823c0e2de [#23019867] At this point, a supporter can change the pledge amount to a smaller amount (no new PayPal transaction required) or a larger amount (a new PayPal transaction is required and the old transaction is canceled.)
I've not implemented the storage of the premium yet -- that's coming next.
I've not implemented straight out cancellation of a pledge yet.
More UI refinement needed, especially around encouraging supporters not to decrease (or cancel) a pledge and refinements to help people know that they have made a modification.
2012-03-20 14:10:21 -07:00
Raymond Yee 46ca784030 [#23019867] First pass at allow for pledges to be modified 2012-03-19 16:32:37 -07:00
Raymond Yee 744693f178 1) Fix an error in which I wasn't checking properly that the pledge_complete page should allow only the pledging user to see the results.
2) Now tests.campaigntest.support_campaign takes us all the way through pledging for the first campaign
2012-03-19 11:46:41 -07:00
Raymond Yee 9199f78606 test/campaigntests.py has a BasicGuiTest.testFrontPage, which tests whether the Learn More link will toggle the description panel.
paypal/tests.py:  made loginSandbox drop the test parameter and callable from outside of paypal/tests.py -- now, for example, from test/campaigntests.py
settings/dev.py:  added LIVE_SERVER_TEST_URL, UNGLUEIT_TEST_USER, UNGLUEIT_TEST_PASSWORD -- parameters useful for selenium-based live server testing
the beginnings of test/campaigntests.support_campaign() -- a selenium script to drive automated pledging to campaign for testing purposes
2012-03-14 15:06:29 -07:00
Raymond Yee 29ff11af94 Missed a datetime import needed for timedelta 2012-03-12 15:55:14 -07:00
Raymond Yee 6bd003b0c6 It turns out that we were sending "naive" timestamps to PayPal....now passing isoformat() of timezone aware versions of timestamp to PayPal
Added a isoformat method to regluit.utils.localdatetime to handle both naive and aware datetimes
2012-03-12 15:42:20 -07:00
Raymond Yee a252f9d173 [#22561067] Implemented regluit.utils.localdatetime.now is by default datetime.datetime.now() (in Django 1.3) and django.utils.timezone.now() in Django 1.4+
One overrides regluit.utils.localdatetime._now to do "time travel" -- useful for testing scenarios requiring time changes (such as Campaigns)
Get rid of call references to datetime.datetime.now() or utcnow() and datetime.date.today() in favor of regluit.utils.localdatetime.now() and date_today().
2012-03-09 00:45:39 +00:00
Ubuntu 727580e330 Adding explicit waits to selenium payment tests in order to wait for very slow js when running headless on ec2 2012-01-26 19:50:14 +00:00
Ubuntu cf3ff26306 Adding screen to payment selenium tests 2012-01-26 17:44:00 +00:00
icellama21 8b6b038fe3 Merge branch 'master' into jkace 2012-01-26 11:23:10 -05:00
icellama21 a51d4c14e0 Changing payment tests to use webdriver, updating to use explicit waits instead of sleep, adding logging granularoty while running tests 2012-01-26 11:21:49 -05:00
Raymond Yee f7e8e41c71 First round of having debug URLs available only if not in preview mode 2012-01-18 09:08:34 -08:00
Raymond Yee 51cc7d4389 IMPORTANT: Transactions that are ACTIVE status must also have approved=True to be counted as an effectlvely active Transaction.
Changes in two tests are made to reflect this change.
2012-01-11 15:31:26 -08:00
Raymond Yee 9130aa8b4a The approved flag from IPNs for Preapprovals now captured properly. 2012-01-11 22:46:59 +00:00
Raymond Yee 9d7be4849a BUG FIX: must use request.POST.get("approved", 'None') to get approved attribute in IPN 2012-01-11 13:58:29 -08:00
Raymond Yee 712b803334 PreapprovalDetails now capturing approved flag
partial work on IPN to capture approved flag
2012-01-11 13:47:56 -08:00
Raymond Yee 7202e97f19 Allow for PaymentManager.checkStatus() to receive specific list of Transaction to process 2012-01-11 11:50:08 -08:00
Raymond Yee 25bc05050a Starting to refactor PaymentManager.checkStatus() to be able to handle transactions we pass in....first step is to factor out methods to handle Preapprovals vs Payments 2012-01-11 11:12:12 -08:00
Raymond Yee c5c9951c3d Fixed a bug in PaymentManager.checkStatus() -- I was appending statuses for recipients in the wrong place 2012-01-11 10:43:12 -08:00
Raymond Yee 0c7c912200 Adding Transaction.approved field (migration needed!) 2012-01-11 09:40:51 -08:00
Raymond Yee 54f2411ab9 Put in a basic page for a pledge completion. 2012-01-10 17:15:39 -08:00
Raymond Yee 01f5664bf5 Some very basic functionality associated with cancel_url, including the ability to try again on the pledge. 2012-01-10 15:26:04 -08:00
Raymond Yee 3abd29f225 First pass at passing in campaign id into cancel_url (which is now calculated in payment/manager.py) 2012-01-10 12:16:04 -08:00
Raymond Yee be67d9e14f Allow modifications if the amount is equal to max amount (not just less)
Fixed a small typo in the comments for payment.views
2012-01-06 10:32:52 -05:00
Raymond Yee 7012039aef Merge branch 'jkace' of github.com:Gluejar/regluit into payment 2012-01-05 15:21:45 -05:00
icellama21 e9d293199c Fixing bug in paypal checkStatus to separate preapproval max_amount from current amount 2012-01-05 12:56:20 -05:00
Raymond Yee 5e91827366 addition of max_amount to payment.models.Transaction 2012-01-05 09:55:18 -05:00
icellama21 b0b6d83f75 Adding payment code for refund and modification of existing transactions 2012-01-05 01:42:05 -05:00
Raymond Yee d106ff6f3d Run only TransactionTest right now in payment.tests because others require selenium to run 2012-01-04 11:04:18 -05:00
Raymond Yee c5e84d7006 Moved campaigntest.py to test/campaigntest.py
Added a simple selenium test to campaigntest to illustrate how to do a google search and test for the presence of text
Updated payment.tests to use the right settings for PayPal sandbox accounts
payment.tests.AuthorizeTest working for RY on laptop.  PledgeTest is going through the motions but not quite working yet
2012-01-04 10:52:19 -05:00
Raymond Yee eb147b3cd4 Added support for incomplete and completed payments in the PaymentManger query function 2012-01-03 14:49:37 -05:00
Raymond Yee d3f25cd788 Added Receiver and PaymentResponse to admin interface
Dropping all Receiver and PaymentResponse in campaigntest.drop_all_transactions
Added a __unicode__ method to Receiver and PaymentResponse
Added some more documentation of PayPal status parameters
2012-01-03 13:37:20 -05:00
Raymond Yee 81fc04ef12 Merge branch 'master' of github.com:Gluejar/regluit into payment 2012-01-03 09:53:51 -05:00
Raymond Yee 4292e1be0a whitespace change 2012-01-03 09:53:29 -05:00
Andromeda Yelton 1f29f7538d authorized_list was scanning ALL transactions, not just those in the transaction list passed into the function 2012-01-02 10:47:36 -05:00
Raymond Yee 56787c3c7b Adjust transaction test to have a deadline 6 months in the future 2011-12-29 10:17:11 -05:00
Raymond Yee a757f6f99b Versions that include movement to utcnow() and changing what comes out PaymentManager.checkStatus() -- but payment to primary recipient is now broken. Need to investigate 2011-12-22 20:34:24 -05:00
Raymond Yee 21c009998a Starting to display more information about recipients tied to transactions 2011-12-21 18:33:36 -05:00
Raymond Yee 17d4acceab changed PaymentManager.cancel to PaymentManager.cancel_transaction and added PaymentManager.cancel_campaign to parallel other methods in PaymentManager
morphing the campaign_admin view towards being able to push all the campaigns through the various states
2011-12-21 17:32:08 -05:00
Raymond Yee 1872615f2a Added a signal to handle the deletion of a transaction. Don't expect to delete transactions in production but for testing, it's important to get the current Campaign tally right based on transactions 2011-12-21 15:28:31 -05:00
Raymond Yee 4c9bf21ce8 Got rid of a bunch of print statements 2011-12-21 13:49:24 -05:00
Raymond Yee c3c0249b42 Added a PaymentManager.finish_campaign()
Fixed a small bug in which r['status'] is None and being attached as a text node in PaymentManager.checkStatus()
2011-12-21 12:31:58 -05:00
Raymond Yee 75fceed7c5 Now display the campaigns with three different types of transactions: ACTIVE, INCOMPLETE, COMPLETED on the campaign_admin view 2011-12-20 20:36:27 -05:00
Raymond Yee c055767173 set the expiry date based on the campaign deadline. There is a setting PREAPPROVAL_PERIOD_AFTER_CAMPAIGN for specifying how many days after the campaign deadline should we ask for a preapproval deadline. I've put in 90 days. 2011-12-20 14:56:01 -05:00
Raymond Yee bad343e3d2 views.py: wiring in the email address of partnering non-profit
payment/manager.py: wire in the email address of the campaign recipient and the Gluejar commission rate
move the Gluejar commission rate to dev.py/prod.py
2011-12-19 18:34:30 -05:00
Raymond Yee 09a0e5ba8b Merging jkace's changes into payment en route to integrating into master 2011-12-14 08:52:48 -08:00
Jason c2c3168e5a Updating payment code to support delayed chained payments. Adding entry points for delayed execution of payments. Creating common parent class for all paypal transactions to more accurately track metadata 2011-12-14 08:30:37 -05:00
eric 7bfc4849a4 added a column to track amount remaining on a campaign; updated by the Transaction change signal 2011-12-14 00:53:03 -05:00
Raymond Yee 5a27dae1d1 Allow the number of days in the past to be configured for PaymentManager.checkStatus (while keeping default of 3 days for now) 2011-12-08 09:13:23 -08:00