Commit graph

3082 commits

Author SHA1 Message Date
PCoder
248283b369 Show user's credit cards dynamically in landing payment page 2017-10-28 23:44:06 +02:00
PCoder
bafb4e7b68 Remove hasCreditcard js code - not used anymore 2017-10-28 23:42:30 +02:00
PCoder
db8dd9af54 Hosting payment: select card text update 2017-10-28 23:18:10 +02:00
PCoder
7e5cab2cc4 Fix PEP8 warnings 2017-10-28 22:44:58 +02:00
PCoder
2a8f02a197 Order by preferred and id fields for cards in settings page 2017-10-28 22:32:35 +02:00
PCoder
cac00d4b9e Implement select default card functionality 2017-10-28 22:19:53 +02:00
PCoder
dc8ea8d253 Make save_default_card method static 2017-10-28 22:18:54 +02:00
PCoder
c47b5cdc72 Add form to send selected card in settings page 2017-10-28 22:17:46 +02:00
PCoder
175180e193 Show DEFAULT text against the default card in the settings page 2017-10-28 20:45:00 +02:00
PCoder
2a59a3336b Add metadata (vm_id) to Stripe subscription 2017-10-28 20:25:18 +02:00
PCoder
d2ae94327a Associate card only if it has not already been done 2017-10-28 18:29:19 +02:00
PCoder
06a5cba50e Add contains utility method 2017-10-28 18:28:14 +02:00
PCoder
4be105a0a9 Set default card for newly added card in hosting flow 2017-10-28 16:48:03 +02:00
PCoder
a17a5f66bc Set preferred = False for cards that are not preferred 2017-10-28 16:47:10 +02:00
PCoder
b6d1e8df6b Set preferred for the card that's used for a subscription 2017-10-28 15:45:05 +02:00
PCoder
6212c9df50 Manage token and card_id properly in hosting flow 2017-10-28 15:30:42 +02:00
PCoder
d14a643171 Set preferred field as in card_details 2017-10-28 15:26:15 +02:00
PCoder
8759e2a4b5 Save default card only if Stripe's default_source is not None 2017-10-28 15:14:42 +02:00
PCoder
73169e825d Add set_as_default parameter for associate_customer_card method 2017-10-28 15:13:38 +02:00
PCoder
38168e8f8f Allow use of previous cards in hosting flow 2017-10-27 00:45:26 +02:00
PCoder
bd7db30633 Add card hidden field to BillingAddressForm 2017-10-27 00:43:07 +02:00
PCoder
1374eaf1a2 Rename id to stripe_api_cus_id 2017-10-27 00:41:49 +02:00
PCoder
a6d28bff86 Add set_default_card and set_default_card_from_stripe methods 2017-10-27 00:40:38 +02:00
M.Ravi
4dd407da67 Use card_id as session variable instead of token and customer 2017-10-26 17:57:11 +02:00
M.Ravi
780fa6cb60 Add get_or_create_user_card_detail method 2017-10-26 17:56:12 +02:00
M.Ravi
85d19c004b Remove redundant code in check_customer 2017-10-26 15:21:29 +02:00
M.Ravi
692f82cba4 Code rearrange 2017-10-26 15:15:27 +02:00
M.Ravi
ef9dc446db Use hasattr to check if a user already has a stripecustomer object 2017-10-26 15:00:54 +02:00
M.Ravi
8d2c120b43 Associate newly added card with customer from hosting 2017-10-26 12:29:16 +02:00
PCoder
de5035d12e Add id_card input element 2017-10-22 00:21:08 +02:00
PCoder
21bb336166 Add js code to submit id_card 2017-10-22 00:20:40 +02:00
PCoder
8351b1bf8b Use refactored get_all_cards_list function 2017-10-21 23:14:55 +02:00
PCoder
bf91bf3822 Change text: delete card to remove card 2017-10-21 23:14:05 +02:00
PCoder
7f4993c3f0 Update hosting payment template to use added cards 2017-10-21 23:12:53 +02:00
PCoder
303eb4112d Add doc. and return empty list for get_all_cards_list function 2017-10-21 21:34:54 +02:00
PCoder
14c7d6ac0e Refactor getting all cards to UserCardDetail.get_all_cards_list() 2017-10-21 21:27:21 +02:00
PCoder
8df72620d6 Add 'billing address updated' message in that case 2017-10-21 20:58:54 +02:00
PCoder
1e08ae5426 Stripe API: Use list() instead of all() as the former is deprecated 2017-10-21 20:46:29 +02:00
PCoder
fb2056bf95 Update stripe_id for a missing case 2017-10-21 20:45:00 +02:00
PCoder
600b549704 Handle case where a Stripe account may have been deleted via dashboard 2017-10-21 20:39:00 +02:00
PCoder
75e90dbacd Refactor and add messages 2017-10-21 20:37:50 +02:00
PCoder
be8181ec42 Add _messages template to hosting/settings.html 2017-10-21 17:02:24 +02:00
PCoder
70b6bbdf2f Save card id as a parameter and use it to delete a source 2017-10-21 13:27:35 +02:00
PCoder
76b3785adc Merge branch 'master' into task/3747/multiple_cards_support 2017-10-21 12:04:15 +02:00
PCoder
7359431b9c Update Changelog 2017-10-21 11:44:55 +02:00
PCoder
12278fc5af Fetch page_title and meta_description dynamically in glasfaser CMS template 2017-10-21 11:42:56 +02:00
Nico Schottelius
ed87762ff0 Update changelog as well 2017-10-21 08:36:17 +02:00
Nico Schottelius
3d192ed59f Replace alplora.ch with .hack4glarus.ch 2017-10-21 08:33:37 +02:00
PCoder
c664b44f2c Add functionality to delete user card 2017-10-21 00:02:35 +02:00
PCoder
255c8a1d80 Add UserCardDetail create method that assigns appropriate object permission 2017-10-21 00:00:21 +02:00