"""add main platform for marketing site Revision ID: z6g7h8i9j0k1 Revises: z5f6g7h8i9j0 Create Date: 2026-01-19 14:00:00.000000 This migration adds the 'main' platform for the main marketing site: 1. Inserts main platform record (wizamart.lu) 2. Creates platform marketing pages (home, about, faq, pricing, contact) The 'main' platform serves as the marketing homepage at: - Development: localhost:9999/ (no /platforms/ prefix) - Production: wizamart.lu/ All other platforms are accessed via: - Development: localhost:9999/platforms/{code}/ - Production: {code}.lu or custom domain """ from typing import Sequence, Union import sqlalchemy as sa from alembic import op # revision identifiers, used by Alembic. revision: str = "z6g7h8i9j0k1" down_revision: Union[str, None] = "z5f6g7h8i9j0" branch_labels: Union[str, Sequence[str], None] = None depends_on: Union[str, Sequence[str], None] = None def upgrade() -> None: conn = op.get_bind() # ========================================================================= # 1. Insert Main Marketing platform # ========================================================================= conn.execute( sa.text(""" INSERT INTO platforms (code, name, description, domain, path_prefix, default_language, supported_languages, is_active, is_public, theme_config, settings, created_at, updated_at) VALUES ('main', 'Wizamart', 'Main marketing site showcasing all Wizamart platforms', 'wizamart.lu', NULL, 'fr', '["fr", "de", "en"]', true, true, '{"primary_color": "#2563EB", "secondary_color": "#3B82F6"}', '{"is_marketing_site": true}', CURRENT_TIMESTAMP, CURRENT_TIMESTAMP) """) ) # Get the Main platform ID result = conn.execute(sa.text("SELECT id FROM platforms WHERE code = 'main'")) main_platform_id = result.fetchone()[0] # ========================================================================= # 2. Create platform marketing pages (is_platform_page=True) # ========================================================================= platform_pages = [ { "slug": "home", "title": "Wizamart - E-commerce Solutions for Luxembourg", "content": """

Build Your Business with Wizamart

All-in-one e-commerce, loyalty, and business solutions for Luxembourg merchants

Our Platforms

Wizamart OMS

Order Management System for multi-channel selling. Manage orders, inventory, and fulfillment from one dashboard.

Learn More

Loyalty+

Customer loyalty platform to reward your customers and increase retention. Points, rewards, and member tiers.

Learn More

Site Builder

Create beautiful websites for your local business. No coding required.

Coming Soon

Why Choose Wizamart?

""", "meta_description": "Wizamart offers e-commerce, loyalty, and business solutions for Luxembourg merchants. OMS, Loyalty+, and Site Builder platforms.", "show_in_header": False, "show_in_footer": False, "display_order": 0, }, { "slug": "about", "title": "About Wizamart", "content": """

About Wizamart

Our Mission

We're building the tools Luxembourg businesses need to thrive in the digital economy. From order management to customer loyalty, we provide the infrastructure that powers local commerce.

Our Story

Wizamart was founded with a simple idea: Luxembourg businesses deserve world-class e-commerce tools that understand their unique needs. Local languages, local payment methods, local compliance - built in from the start.

Our Team

We're a team of developers, designers, and business experts based in Luxembourg. We understand the local market because we're part of it.

Our Values

""", "meta_description": "Learn about Wizamart, the Luxembourg-based company building e-commerce and business solutions for local merchants.", "show_in_header": True, "show_in_footer": True, "display_order": 1, }, { "slug": "pricing", "title": "Pricing - Wizamart", "content": """

Choose Your Platform

Each platform has its own pricing. Choose the tools your business needs.

Wizamart OMS

Order Management System

From €49/month
  • Multi-channel order management
  • Inventory tracking
  • Shipping integrations
  • Analytics dashboard
View OMS Pricing

Loyalty+

Customer Loyalty Platform

From €49/month
  • Points & rewards system
  • Member tiers
  • Analytics & insights
  • POS integrations
View Loyalty+ Pricing

Bundle & Save

Use multiple platforms together

Save up to 20%
  • Seamless integration
  • Unified dashboard
  • Single invoice
  • Priority support
Contact Sales
""", "meta_description": "Wizamart pricing for OMS, Loyalty+, and bundled solutions. Plans starting at €49/month.", "show_in_header": True, "show_in_footer": True, "display_order": 2, }, { "slug": "faq", "title": "FAQ - Frequently Asked Questions", "content": """

Frequently Asked Questions

General

What is Wizamart?

Wizamart is a suite of business tools for Luxembourg merchants, including order management (OMS), customer loyalty (Loyalty+), and website building (Site Builder).

Do I need to use all platforms?

No! Each platform works independently. Use one, two, or all three - whatever fits your business needs.

What languages are supported?

All platforms support French, German, and English - the three main languages of Luxembourg.

Billing & Pricing

Is there a free trial?

Yes! All platforms offer a 14-day free trial with no credit card required.

What payment methods do you accept?

We accept credit cards, SEPA direct debit, and bank transfers.

Can I cancel anytime?

Yes, you can cancel your subscription at any time. No long-term contracts required.

Support

How do I get help?

All plans include email support. Professional and Business plans include priority support with faster response times.

Do you offer onboarding?

Yes! We offer guided onboarding for all new customers to help you get started quickly.

""", "meta_description": "Frequently asked questions about Wizamart platforms, pricing, billing, and support.", "show_in_header": True, "show_in_footer": True, "display_order": 3, }, { "slug": "contact", "title": "Contact Us - Wizamart", "content": """

Contact Us

We'd love to hear from you. Get in touch with our team.

Sales

Interested in our platforms? Let's talk about how we can help your business.

sales@wizamart.lu

Support

Already a customer? Our support team is here to help.

support@wizamart.lu

General Inquiries

For everything else, reach out to our general inbox.

hello@wizamart.lu

Office

Wizamart S.à r.l.
Luxembourg City
Luxembourg

""", "meta_description": "Contact Wizamart for sales, support, or general inquiries. We're here to help your Luxembourg business succeed.", "show_in_header": True, "show_in_footer": True, "display_order": 4, }, { "slug": "terms", "title": "Terms of Service - Wizamart", "content": """

Terms of Service

Last updated: January 2026

These Terms of Service govern your use of Wizamart platforms and services.

1. Acceptance of Terms

By accessing or using our services, you agree to be bound by these Terms.

2. Services

Wizamart provides e-commerce and business management tools including order management, loyalty programs, and website building services.

3. Account Registration

You must provide accurate information when creating an account and keep your login credentials secure.

4. Fees and Payment

Subscription fees are billed in advance on a monthly or annual basis. Prices are listed in EUR and include applicable VAT for Luxembourg customers.

5. Data Protection

We process personal data in accordance with our Privacy Policy and applicable data protection laws including GDPR.

6. Limitation of Liability

Our liability is limited to the amount paid for services in the 12 months preceding any claim.

7. Governing Law

These Terms are governed by Luxembourg law. Disputes shall be resolved in Luxembourg courts.

8. Contact

For questions about these Terms, contact us at legal@wizamart.lu

""", "meta_description": "Wizamart Terms of Service. Read the terms and conditions for using our e-commerce and business platforms.", "show_in_header": False, "show_in_footer": True, "show_in_legal": True, "display_order": 10, }, { "slug": "privacy", "title": "Privacy Policy - Wizamart", "content": """

Privacy Policy

Last updated: January 2026

Introduction

Wizamart S.à r.l. ("we", "us") is committed to protecting your privacy. This policy explains how we collect, use, and protect your personal data.

Data Controller

Wizamart S.à r.l.
Luxembourg City, Luxembourg
Email: privacy@wizamart.lu

Data We Collect

How We Use Your Data

Your Rights

Under GDPR, you have the right to:

Contact

To exercise your rights or ask questions, contact our Data Protection Officer at privacy@wizamart.lu

""", "meta_description": "Wizamart Privacy Policy. Learn how we collect, use, and protect your personal data in compliance with GDPR.", "show_in_header": False, "show_in_footer": True, "show_in_legal": True, "display_order": 11, }, ] for page in platform_pages: show_in_legal = page.get("show_in_legal", False) conn.execute( sa.text(""" INSERT INTO content_pages (platform_id, vendor_id, slug, title, content, content_format, meta_description, is_published, is_platform_page, show_in_header, show_in_footer, show_in_legal, display_order, created_at, updated_at) VALUES (:platform_id, NULL, :slug, :title, :content, 'html', :meta_description, true, true, :show_in_header, :show_in_footer, :show_in_legal, :display_order, CURRENT_TIMESTAMP, CURRENT_TIMESTAMP) """), { "platform_id": main_platform_id, "slug": page["slug"], "title": page["title"], "content": page["content"], "meta_description": page["meta_description"], "show_in_header": page["show_in_header"], "show_in_footer": page["show_in_footer"], "show_in_legal": show_in_legal, "display_order": page["display_order"], } ) def downgrade() -> None: conn = op.get_bind() # Get the Main platform ID result = conn.execute(sa.text("SELECT id FROM platforms WHERE code = 'main'")) row = result.fetchone() if row: main_platform_id = row[0] # Delete all content pages for main platform conn.execute( sa.text("DELETE FROM content_pages WHERE platform_id = :platform_id"), {"platform_id": main_platform_id} ) # Delete vendor_platforms entries for main (if any) conn.execute( sa.text("DELETE FROM vendor_platforms WHERE platform_id = :platform_id"), {"platform_id": main_platform_id} ) # Delete main platform conn.execute(sa.text("DELETE FROM platforms WHERE code = 'main'"))