mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2024-12-01 12:24:28 +01:00
fix process payzen transaction
This commit is contained in:
parent
051b56b72f
commit
365443775e
@ -4,7 +4,8 @@
|
|||||||
- Ability to create slots in the past
|
- Ability to create slots in the past
|
||||||
- Ability to disable public account creation
|
- Ability to disable public account creation
|
||||||
- Ability to select "bank transfer" as the payment mean for a payment schedule
|
- Ability to select "bank transfer" as the payment mean for a payment schedule
|
||||||
- When a payment schedule was canceled by the payment gateway, inform the user in the interface
|
- When a payment schedule was canceled by the payment gateway, alert the users
|
||||||
|
- When a payment schedule is in error, alert the users
|
||||||
- Updated caniuse db
|
- Updated caniuse db
|
||||||
- Fix card image ratio
|
- Fix card image ratio
|
||||||
- Update events heading style
|
- Update events heading style
|
||||||
|
@ -78,8 +78,8 @@ class PayZen::Service < Payment::Service
|
|||||||
end
|
end
|
||||||
|
|
||||||
def process_payment_schedule_item(payment_schedule_item)
|
def process_payment_schedule_item(payment_schedule_item)
|
||||||
pz_subscription = payment_schedule_item.gateway_subscription.retrieve
|
pz_subscription = payment_schedule_item.payment_schedule.gateway_subscription.retrieve
|
||||||
if DateTime.parse(pz_subscription['answer']['cancelDate']) < DateTime.current
|
if pz_subscription['answer']['cancelDate'] && DateTime.parse(pz_subscription['answer']['cancelDate']) < DateTime.current
|
||||||
# the subscription was canceled by the gateway => notify & update the status
|
# the subscription was canceled by the gateway => notify & update the status
|
||||||
notify_payment_schedule_gateway_canceled(payment_schedule_item)
|
notify_payment_schedule_gateway_canceled(payment_schedule_item)
|
||||||
payment_schedule_item.update_attributes(state: 'gateway_canceled')
|
payment_schedule_item.update_attributes(state: 'gateway_canceled')
|
||||||
|
Loading…
Reference in New Issue
Block a user