PhoenixKit.Migrations.Postgres.V45 (phoenix_kit v1.7.71)

Copy Markdown View Source

PhoenixKit V45 Migration: E-commerce Shop Module

This migration creates the foundation for the Shop module.

Tables

  • phoenix_kit_shop_categories - Product categories with nesting support
  • phoenix_kit_shop_products - Products (physical and digital)
  • phoenix_kit_shop_shipping_methods - Shipping options with constraints
  • phoenix_kit_shop_carts - Shopping carts for users and guests
  • phoenix_kit_shop_cart_items - Cart contents with price snapshots
  • phoenix_kit_payment_options - Payment methods for checkout

Future Tables

  • phoenix_kit_shop_variants - Product variants (size, color)
  • phoenix_kit_shop_inventory - Inventory tracking

Settings

  • shop_enabled - Enable/disable shop module
  • shop_currency - Default currency (USD)
  • shop_tax_enabled - Enable tax calculations
  • shop_tax_rate - Default tax rate percentage
  • shop_inventory_tracking - Enable inventory tracking

Summary

Functions

Rollback the V45 migration.

Run the V45 migration.

Functions

down(opts)

Rollback the V45 migration.

up(opts)

Run the V45 migration.