Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support asynchronous payment flows #23

Closed
syjer opened this issue Dec 2, 2014 · 1 comment
Closed

Support asynchronous payment flows #23

syjer opened this issue Dec 2, 2014 · 1 comment
Assignees
Milestone

Comments

@syjer
Copy link
Member

syjer commented Dec 2, 2014

For supporting other payment flow (where the ACK from the gateway can be hours or days later), we will need to an additional state for the TicketReservation I would guess.

Currently, as defined in the enum TicketReservationStatus we have the following states:

PENDING, IN_PAYMENT, COMPLETE, STUCK

The transition is, PENDING -> IN_PAYMENT -> COMPLETE | STUCK

The PENDING state is when the user has reserved a ticket but not paid, if the user has not completed the transaction in the configured timeout, the reservation will be removed.

The IN_PAYMENT state is when the user is paying (this is done in a transaction, so if there are no failure on the stripe side and our side this state is not visible (at the moment there is a error page for handling the IN_PAYMENT and STUCK page, see ReservationController#showReservationPage, last branch )).

So, for supporting the async case, we will need :

  • decide where the user will select the payment method (first page or second page?)
  • add an additional state between PENDING and IN_PAYMENT .
  • add the additional gui for the payment provider + logic on the controller side (we will need to abstract this part, at the moment it's hardcoded)
  • gui for the new state (where the user can still modify the ticket assignment) in ReservationController#showReservationPage.

When the payment has been confirmed, the reservation should transition directly to COMPLETE and it should send an email to the user(s) and let them download/see the tickets.

At the moment the user cannot see/interact with the TicketController until the reservation has a COMPLETE status, so on this side we are covered.

@syjer syjer modified the milestone: 1.1 Dec 14, 2014
@cbellone cbellone self-assigned this Dec 17, 2014
cbellone added a commit that referenced this issue Dec 21, 2014
cbellone added a commit that referenced this issue Dec 21, 2014
cbellone added a commit that referenced this issue Dec 24, 2014
cbellone added a commit that referenced this issue Dec 24, 2014
@cbellone
Copy link
Member

done. To be tested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants