feat: Implement complete ticket purchasing flow with new TicketsController
- Create new TicketsController with actions for name collection, creation, and checkout - Add dedicated ticket views (new.html.erb, checkout.html.erb, show.html.erb) - Update ticket_selection_controller.js to handle form submission via AJAX - Add store_cart endpoint in EventsController for session-based cart management - Update routes to support new ticket flow: /tickets/new, /create, /checkout - Fix attribute name consistency across views (title→name, starts_at→start_time) - Add Stripe checkout integration with proper error handling - Remove deprecated collect_names flow in favor of streamlined approach The flow is now: Event selection → AJAX cart storage → Name collection → Checkout → Payment
This commit is contained in:
4
test/fixtures/ticket_types.yml
vendored
4
test/fixtures/ticket_types.yml
vendored
@@ -8,6 +8,7 @@ one:
|
||||
sale_start_at: <%= 1.day.ago %>
|
||||
sale_end_at: <%= 1.day.from_now %>
|
||||
event: one
|
||||
# minimum_age: 18
|
||||
|
||||
two:
|
||||
name: VIP Access
|
||||
@@ -16,4 +17,5 @@ two:
|
||||
quantity: 50
|
||||
sale_start_at: <%= 1.day.ago %>
|
||||
sale_end_at: <%= 1.day.from_now %>
|
||||
event: two
|
||||
event: two
|
||||
# minimum_age: 18
|
||||
|
||||
Reference in New Issue
Block a user