Files
aperonight/db/migrate/20250823171354_create_tickets.rb
kbe 1889ee7fb2 feat: replace Stripe Global Payouts with manual bank transfer system for France compliance
- Replace Stripe automatic payouts with manual admin-processed bank transfers
- Add banking information fields (IBAN, bank name, account holder) to User model
- Implement manual payout workflow: pending → approved → processing → completed
- Add comprehensive admin interface for payout review and processing
- Update Payout model with manual processing fields and workflow methods
- Add transfer reference tracking and rejection/failure handling
- Consolidate all migration fragments into clean "create" migrations
- Add comprehensive documentation for manual payout workflow
- Fix Event payout_status enum definition and database column issues

This addresses France's lack of Stripe Global Payouts support by implementing
a complete manual bank transfer workflow while maintaining audit trails and
proper admin controls.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-17 11:55:07 +02:00

23 lines
592 B
Ruby
Executable File

class CreateTickets < ActiveRecord::Migration[8.0]
def change
create_table :tickets do |t|
t.string :qr_code
t.integer :price_cents
t.string :status, default: "draft"
# Add names to ticket
t.string :first_name
t.string :last_name
# Tickets belong to orders (orders handle payment logic)
t.references :order, null: false, foreign_key: false
t.references :ticket_type, null: false, foreign_key: false
t.timestamps
end
add_index :tickets, :qr_code, unique: true
add_index :tickets, [:status, :order_id]
end
end