refactor: rename Wizamart to Orion across entire codebase
Replace all ~1,086 occurrences of Wizamart/wizamart/WIZAMART/WizaMart with Orion/orion/ORION across 184 files. This includes database identifiers, email addresses, domain references, R2 bucket names, DNS prefixes, encryption salt, Celery app name, config defaults, Docker configs, CI configs, documentation, seed data, and templates. Renames homepage-wizamart.html template to homepage-orion.html. Fixes duplicate file_pattern key in api.yaml architecture rule. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# app/core/celery_config.py
|
||||
"""
|
||||
Celery configuration for Wizamart background task processing.
|
||||
Celery configuration for Orion background task processing.
|
||||
|
||||
This module configures Celery with Redis as the broker and result backend.
|
||||
It includes:
|
||||
@@ -66,7 +66,7 @@ def get_all_task_modules() -> list[str]:
|
||||
|
||||
# Create Celery application
|
||||
celery_app = Celery(
|
||||
"wizamart",
|
||||
"orion",
|
||||
broker=REDIS_URL,
|
||||
backend=REDIS_URL,
|
||||
include=get_all_task_modules(),
|
||||
|
||||
@@ -27,7 +27,7 @@ class Settings(BaseSettings):
|
||||
# =============================================================================
|
||||
# PROJECT INFORMATION
|
||||
# =============================================================================
|
||||
project_name: str = "Wizamart - Multi-Store Marketplace Platform"
|
||||
project_name: str = "Orion - Multi-Store Marketplace Platform"
|
||||
version: str = "2.2.0"
|
||||
|
||||
# Clean description without HTML
|
||||
@@ -47,12 +47,12 @@ class Settings(BaseSettings):
|
||||
# =============================================================================
|
||||
# DATABASE (PostgreSQL only)
|
||||
# =============================================================================
|
||||
database_url: str = "postgresql://wizamart_user:secure_password@localhost:5432/wizamart_db"
|
||||
database_url: str = "postgresql://orion_user:secure_password@localhost:5432/orion_db"
|
||||
|
||||
# =============================================================================
|
||||
# ADMIN INITIALIZATION (for init_production.py)
|
||||
# =============================================================================
|
||||
admin_email: str = "admin@wizamart.com"
|
||||
admin_email: str = "admin@orion.lu"
|
||||
admin_username: str = "admin"
|
||||
admin_password: str = "admin123" # CHANGE IN PRODUCTION!
|
||||
admin_first_name: str = "Platform"
|
||||
@@ -96,7 +96,7 @@ class Settings(BaseSettings):
|
||||
# =============================================================================
|
||||
# PLATFORM DOMAIN CONFIGURATION
|
||||
# =============================================================================
|
||||
platform_domain: str = "wizamart.com"
|
||||
platform_domain: str = "orion.lu"
|
||||
|
||||
# Custom domain features
|
||||
allow_custom_domains: bool = True
|
||||
@@ -107,7 +107,7 @@ class Settings(BaseSettings):
|
||||
auto_provision_ssl: bool = False
|
||||
|
||||
# DNS verification
|
||||
dns_verification_prefix: str = "_wizamart-verify"
|
||||
dns_verification_prefix: str = "_orion-verify"
|
||||
dns_verification_ttl: int = 3600
|
||||
|
||||
# =============================================================================
|
||||
@@ -130,8 +130,8 @@ class Settings(BaseSettings):
|
||||
# =============================================================================
|
||||
# Provider: smtp, sendgrid, mailgun, ses
|
||||
email_provider: str = "smtp"
|
||||
email_from_address: str = "noreply@wizamart.com"
|
||||
email_from_name: str = "Wizamart"
|
||||
email_from_address: str = "noreply@orion.lu"
|
||||
email_from_name: str = "Orion"
|
||||
email_reply_to: str = "" # Optional reply-to address
|
||||
|
||||
# SMTP Settings (used when email_provider=smtp)
|
||||
@@ -201,7 +201,7 @@ class Settings(BaseSettings):
|
||||
r2_account_id: str | None = None
|
||||
r2_access_key_id: str | None = None
|
||||
r2_secret_access_key: str | None = None
|
||||
r2_bucket_name: str = "wizamart-media"
|
||||
r2_bucket_name: str = "orion-media"
|
||||
r2_public_url: str | None = None # Custom domain for public access (e.g., https://media.yoursite.com)
|
||||
|
||||
# =============================================================================
|
||||
|
||||
@@ -9,7 +9,7 @@ Detection priority:
|
||||
1. Admin subdomain (admin.oms.lu)
|
||||
2. Path-based admin/store (/admin/*, /store/*, /api/v1/admin/*)
|
||||
3. Custom domain lookup (mybakery.lu -> STOREFRONT)
|
||||
4. Store subdomain (wizamart.oms.lu -> STOREFRONT)
|
||||
4. Store subdomain (orion.oms.lu -> STOREFRONT)
|
||||
5. Storefront paths (/storefront/*, /api/v1/storefront/*)
|
||||
6. Default to PLATFORM (marketing pages)
|
||||
|
||||
@@ -62,7 +62,7 @@ class FrontendDetector:
|
||||
Detect frontend type from request.
|
||||
|
||||
Args:
|
||||
host: Request host header (e.g., "oms.lu", "wizamart.oms.lu", "localhost:8000")
|
||||
host: Request host header (e.g., "oms.lu", "orion.oms.lu", "localhost:8000")
|
||||
path: Request path (e.g., "/admin/stores", "/storefront/products")
|
||||
has_store_context: True if request.state.store is set (from middleware)
|
||||
|
||||
@@ -110,7 +110,7 @@ class FrontendDetector:
|
||||
logger.debug("[FRONTEND_DETECTOR] Detected PLATFORM from path")
|
||||
return FrontendType.PLATFORM
|
||||
|
||||
# 3. Store subdomain detection (wizamart.oms.lu)
|
||||
# 3. Store subdomain detection (orion.oms.lu)
|
||||
# If subdomain exists and is not reserved -> it's a store storefront
|
||||
if subdomain and subdomain not in cls.RESERVED_SUBDOMAINS:
|
||||
logger.debug(
|
||||
@@ -138,7 +138,7 @@ class FrontendDetector:
|
||||
@classmethod
|
||||
def _get_subdomain(cls, host: str) -> str | None:
|
||||
"""
|
||||
Extract subdomain from host (e.g., 'wizamart' from 'wizamart.oms.lu').
|
||||
Extract subdomain from host (e.g., 'orion' from 'orion.oms.lu').
|
||||
|
||||
Returns None for localhost, IP addresses, or root domains.
|
||||
Handles special case of admin.localhost for development.
|
||||
|
||||
@@ -32,13 +32,13 @@ async def lifespan(app: FastAPI):
|
||||
|
||||
# === STARTUP ===
|
||||
app_logger = setup_logging()
|
||||
app_logger.info("Starting Wizamart multi-tenant platform")
|
||||
app_logger.info("Starting Orion multi-tenant platform")
|
||||
logger.info("[OK] Application startup completed")
|
||||
|
||||
yield
|
||||
|
||||
# === SHUTDOWN ===
|
||||
app_logger.info("Shutting down Wizamart platform")
|
||||
app_logger.info("Shutting down Orion platform")
|
||||
# Add cleanup tasks here if needed
|
||||
|
||||
|
||||
|
||||
@@ -33,16 +33,16 @@ from .base import (
|
||||
BusinessLogicException,
|
||||
ConflictException,
|
||||
ExternalServiceException,
|
||||
OrionException,
|
||||
RateLimitException,
|
||||
ResourceNotFoundException,
|
||||
ServiceUnavailableException,
|
||||
ValidationException,
|
||||
WizamartException,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
# Base exception class
|
||||
"WizamartException",
|
||||
"OrionException",
|
||||
# Validation and business logic
|
||||
"ValidationException",
|
||||
"BusinessLogicException",
|
||||
|
||||
@@ -11,7 +11,7 @@ This module provides classes and functions for:
|
||||
from typing import Any
|
||||
|
||||
|
||||
class WizamartException(Exception):
|
||||
class OrionException(Exception):
|
||||
"""Base exception class for all custom exceptions."""
|
||||
|
||||
def __init__(
|
||||
@@ -39,7 +39,7 @@ class WizamartException(Exception):
|
||||
return result
|
||||
|
||||
|
||||
class ValidationException(WizamartException):
|
||||
class ValidationException(OrionException):
|
||||
"""Raised when request validation fails."""
|
||||
|
||||
def __init__(
|
||||
@@ -60,7 +60,7 @@ class ValidationException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class AuthenticationException(WizamartException):
|
||||
class AuthenticationException(OrionException):
|
||||
"""Raised when authentication fails."""
|
||||
|
||||
def __init__(
|
||||
@@ -77,7 +77,7 @@ class AuthenticationException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class AuthorizationException(WizamartException):
|
||||
class AuthorizationException(OrionException):
|
||||
"""Raised when user lacks permission for an operation."""
|
||||
|
||||
def __init__(
|
||||
@@ -94,7 +94,7 @@ class AuthorizationException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class ResourceNotFoundException(WizamartException):
|
||||
class ResourceNotFoundException(OrionException):
|
||||
"""Raised when a requested resource is not found."""
|
||||
|
||||
def __init__(
|
||||
@@ -120,7 +120,7 @@ class ResourceNotFoundException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class ConflictException(WizamartException):
|
||||
class ConflictException(OrionException):
|
||||
"""Raised when a resource conflict occurs."""
|
||||
|
||||
def __init__(
|
||||
@@ -137,7 +137,7 @@ class ConflictException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class BusinessLogicException(WizamartException):
|
||||
class BusinessLogicException(OrionException):
|
||||
"""Raised when business logic rules are violated."""
|
||||
|
||||
def __init__(
|
||||
@@ -154,7 +154,7 @@ class BusinessLogicException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class ExternalServiceException(WizamartException):
|
||||
class ExternalServiceException(OrionException):
|
||||
"""Raised when an external service fails."""
|
||||
|
||||
def __init__(
|
||||
@@ -175,7 +175,7 @@ class ExternalServiceException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class RateLimitException(WizamartException):
|
||||
class RateLimitException(OrionException):
|
||||
"""Raised when rate limit is exceeded."""
|
||||
|
||||
def __init__(
|
||||
@@ -196,7 +196,7 @@ class RateLimitException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class ServiceUnavailableException(WizamartException):
|
||||
class ServiceUnavailableException(OrionException):
|
||||
"""Raised when service is unavailable."""
|
||||
|
||||
def __init__(self, message: str = "Service temporarily unavailable"):
|
||||
|
||||
@@ -19,7 +19,7 @@ from fastapi.responses import JSONResponse, RedirectResponse
|
||||
from app.modules.enums import FrontendType
|
||||
from middleware.frontend_type import get_frontend_type
|
||||
|
||||
from .base import WizamartException
|
||||
from .base import OrionException
|
||||
from .error_renderer import ErrorPageRenderer
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -28,8 +28,8 @@ logger = logging.getLogger(__name__)
|
||||
def setup_exception_handlers(app):
|
||||
"""Setup exception handlers for the FastAPI app."""
|
||||
|
||||
@app.exception_handler(WizamartException)
|
||||
async def custom_exception_handler(request: Request, exc: WizamartException):
|
||||
@app.exception_handler(OrionException)
|
||||
async def custom_exception_handler(request: Request, exc: OrionException):
|
||||
"""Handle custom exceptions with context-aware rendering."""
|
||||
|
||||
# Special handling for auth errors on HTML page requests (redirect to login)
|
||||
|
||||
@@ -37,7 +37,7 @@ class MerchantSubscription(Base, TimestampMixin):
|
||||
|
||||
Example:
|
||||
Merchant "Boucherie Luxembourg" subscribes to:
|
||||
- Wizamart OMS (Professional tier)
|
||||
- Orion OMS (Professional tier)
|
||||
- Loyalty+ (Essential tier)
|
||||
|
||||
Their stores inherit features from the merchant's subscription.
|
||||
|
||||
@@ -119,7 +119,7 @@ async def signup_success_page(
|
||||
Shown after successful account creation.
|
||||
"""
|
||||
context = get_platform_context(request, db)
|
||||
context["page_title"] = "Welcome to Wizamart!"
|
||||
context["page_title"] = "Welcome to Orion!"
|
||||
context["store_code"] = store_code
|
||||
|
||||
return templates.TemplateResponse(
|
||||
|
||||
@@ -324,7 +324,7 @@ function storeInvoices() {
|
||||
|
||||
try {
|
||||
// Get the token for authentication
|
||||
const token = localStorage.getItem('wizamart_token') || localStorage.getItem('store_token');
|
||||
const token = localStorage.getItem('orion_token') || localStorage.getItem('store_token');
|
||||
if (!token) {
|
||||
throw new Error('Not authenticated');
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{# Standalone Pricing Page #}
|
||||
{% extends "platform/base.html" %}
|
||||
|
||||
{% block title %}{{ _("cms.platform.pricing.title") }} - Wizamart{% endblock %}
|
||||
{% block title %}{{ _("cms.platform.pricing.title") }} - Orion{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div x-data="{ annual: false }" class="py-16 lg:py-24">
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{# Multi-step Signup Wizard #}
|
||||
{% extends "platform/base.html" %}
|
||||
|
||||
{% block title %}Start Your Free Trial - Wizamart{% endblock %}
|
||||
{% block title %}Start Your Free Trial - Orion{% endblock %}
|
||||
|
||||
{% block extra_head %}
|
||||
{# Stripe.js for payment #}
|
||||
|
||||
@@ -133,7 +133,7 @@
|
||||
"creating_account": "Erstelle Ihr Konto..."
|
||||
},
|
||||
"success": {
|
||||
"title": "Willkommen bei Wizamart!",
|
||||
"title": "Willkommen bei Orion!",
|
||||
"subtitle": "Ihr Konto wurde erstellt und Ihre {trial_days}-tägige kostenlose Testphase hat begonnen.",
|
||||
"what_next": "Was kommt als Nächstes?",
|
||||
"step_connect": "Letzshop verbinden:",
|
||||
@@ -149,7 +149,7 @@
|
||||
},
|
||||
"cta": {
|
||||
"title": "Bereit, Ihre Bestellungen zu optimieren?",
|
||||
"subtitle": "Schließen Sie sich Letzshop-Händlern an, die Wizamart für ihre Bestellverwaltung vertrauen. Starten Sie heute Ihre {trial_days}-tägige kostenlose Testversion.",
|
||||
"subtitle": "Schließen Sie sich Letzshop-Händlern an, die Orion für ihre Bestellverwaltung vertrauen. Starten Sie heute Ihre {trial_days}-tägige kostenlose Testversion.",
|
||||
"button": "Kostenlos testen"
|
||||
},
|
||||
"footer": {
|
||||
@@ -157,7 +157,7 @@
|
||||
"quick_links": "Schnelllinks",
|
||||
"platform": "Plattform",
|
||||
"contact": "Kontakt",
|
||||
"copyright": "© {year} Wizamart. Entwickelt für den luxemburgischen E-Commerce.",
|
||||
"copyright": "© {year} Orion. Entwickelt für den luxemburgischen E-Commerce.",
|
||||
"privacy": "Datenschutzerklärung",
|
||||
"terms": "Nutzungsbedingungen",
|
||||
"about": "Über uns",
|
||||
@@ -188,7 +188,7 @@
|
||||
"how_step1": "Letzshop verbinden",
|
||||
"how_step1_desc": "Geben Sie Ihre Letzshop-API-Zugangsdaten ein. In 2 Minuten erledigt, keine technischen Kenntnisse erforderlich.",
|
||||
"how_step2": "Bestellungen kommen rein",
|
||||
"how_step2_desc": "Bestellungen werden automatisch synchronisiert. Bestätigen und Tracking direkt von Wizamart hinzufügen.",
|
||||
"how_step2_desc": "Bestellungen werden automatisch synchronisiert. Bestätigen und Tracking direkt von Orion hinzufügen.",
|
||||
"how_step3": "Rechnungen erstellen",
|
||||
"how_step3_desc": "Ein Klick, um konforme PDF-Rechnungen mit korrekter MwSt für jedes EU-Land zu erstellen.",
|
||||
"how_step4": "Ihr Geschäft ausbauen",
|
||||
|
||||
@@ -133,7 +133,7 @@
|
||||
"creating_account": "Creating your account..."
|
||||
},
|
||||
"success": {
|
||||
"title": "Welcome to Wizamart!",
|
||||
"title": "Welcome to Orion!",
|
||||
"subtitle": "Your account has been created and your {trial_days}-day free trial has started.",
|
||||
"what_next": "What's Next?",
|
||||
"step_connect": "Connect Letzshop:",
|
||||
@@ -149,7 +149,7 @@
|
||||
},
|
||||
"cta": {
|
||||
"title": "Ready to Streamline Your Orders?",
|
||||
"subtitle": "Join Letzshop stores who trust Wizamart for their order management. Start your {trial_days}-day free trial today.",
|
||||
"subtitle": "Join Letzshop stores who trust Orion for their order management. Start your {trial_days}-day free trial today.",
|
||||
"button": "Start Free Trial"
|
||||
},
|
||||
"footer": {
|
||||
@@ -157,7 +157,7 @@
|
||||
"quick_links": "Quick Links",
|
||||
"platform": "Platform",
|
||||
"contact": "Contact",
|
||||
"copyright": "© {year} Wizamart. Built for Luxembourg e-commerce.",
|
||||
"copyright": "© {year} Orion. Built for Luxembourg e-commerce.",
|
||||
"privacy": "Privacy Policy",
|
||||
"terms": "Terms of Service",
|
||||
"about": "About Us",
|
||||
@@ -188,7 +188,7 @@
|
||||
"how_step1": "Connect Letzshop",
|
||||
"how_step1_desc": "Enter your Letzshop API credentials. Done in 2 minutes, no technical skills needed.",
|
||||
"how_step2": "Orders Flow In",
|
||||
"how_step2_desc": "Orders sync automatically. Confirm and add tracking directly from Wizamart.",
|
||||
"how_step2_desc": "Orders sync automatically. Confirm and add tracking directly from Orion.",
|
||||
"how_step3": "Generate Invoices",
|
||||
"how_step3_desc": "One click to create compliant PDF invoices with correct VAT for any EU country.",
|
||||
"how_step4": "Grow Your Business",
|
||||
|
||||
@@ -133,7 +133,7 @@
|
||||
"creating_account": "Création de votre compte..."
|
||||
},
|
||||
"success": {
|
||||
"title": "Bienvenue sur Wizamart !",
|
||||
"title": "Bienvenue sur Orion !",
|
||||
"subtitle": "Votre compte a été créé et votre essai gratuit de {trial_days} jours a commencé.",
|
||||
"what_next": "Et maintenant ?",
|
||||
"step_connect": "Connecter Letzshop :",
|
||||
@@ -149,7 +149,7 @@
|
||||
},
|
||||
"cta": {
|
||||
"title": "Prêt à optimiser vos commandes ?",
|
||||
"subtitle": "Rejoignez les vendeurs Letzshop qui font confiance à Wizamart pour leur gestion de commandes. Commencez votre essai gratuit de {trial_days} jours aujourd'hui.",
|
||||
"subtitle": "Rejoignez les vendeurs Letzshop qui font confiance à Orion pour leur gestion de commandes. Commencez votre essai gratuit de {trial_days} jours aujourd'hui.",
|
||||
"button": "Essai gratuit"
|
||||
},
|
||||
"footer": {
|
||||
@@ -157,7 +157,7 @@
|
||||
"quick_links": "Liens rapides",
|
||||
"platform": "Plateforme",
|
||||
"contact": "Contact",
|
||||
"copyright": "© {year} Wizamart. Conçu pour le e-commerce luxembourgeois.",
|
||||
"copyright": "© {year} Orion. Conçu pour le e-commerce luxembourgeois.",
|
||||
"privacy": "Politique de confidentialité",
|
||||
"terms": "Conditions d'utilisation",
|
||||
"about": "À propos",
|
||||
@@ -188,7 +188,7 @@
|
||||
"how_step1": "Connecter Letzshop",
|
||||
"how_step1_desc": "Entrez vos identifiants API Letzshop. Fait en 2 minutes, aucune compétence technique requise.",
|
||||
"how_step2": "Les commandes arrivent",
|
||||
"how_step2_desc": "Les commandes se synchronisent automatiquement. Confirmez et ajoutez le suivi directement depuis Wizamart.",
|
||||
"how_step2_desc": "Les commandes se synchronisent automatiquement. Confirmez et ajoutez le suivi directement depuis Orion.",
|
||||
"how_step3": "Générer des factures",
|
||||
"how_step3_desc": "Un clic pour créer des factures PDF conformes avec la TVA correcte pour tout pays UE.",
|
||||
"how_step4": "Développez votre entreprise",
|
||||
|
||||
@@ -133,7 +133,7 @@
|
||||
"creating_account": "Erstellt Äre Kont..."
|
||||
},
|
||||
"success": {
|
||||
"title": "Wëllkomm bei Wizamart!",
|
||||
"title": "Wëllkomm bei Orion!",
|
||||
"subtitle": "Äre Kont gouf erstallt an Är {trial_days}-Deeg gratis Testversioun huet ugefaang.",
|
||||
"what_next": "Wat kënnt duerno?",
|
||||
"step_connect": "Letzshop verbannen:",
|
||||
@@ -149,7 +149,7 @@
|
||||
},
|
||||
"cta": {
|
||||
"title": "Prett fir Är Bestellungen ze optiméieren?",
|
||||
"subtitle": "Schléisst Iech Letzshop Händler un déi Wizamart fir hir Bestellungsverwaltung vertrauen. Fänkt haut Är {trial_days}-Deeg gratis Testversioun un.",
|
||||
"subtitle": "Schléisst Iech Letzshop Händler un déi Orion fir hir Bestellungsverwaltung vertrauen. Fänkt haut Är {trial_days}-Deeg gratis Testversioun un.",
|
||||
"button": "Gratis Testen"
|
||||
},
|
||||
"footer": {
|
||||
@@ -157,7 +157,7 @@
|
||||
"quick_links": "Séier Linken",
|
||||
"platform": "Plattform",
|
||||
"contact": "Kontakt",
|
||||
"copyright": "© {year} Wizamart. Gemaach fir de lëtzebuergeschen E-Commerce.",
|
||||
"copyright": "© {year} Orion. Gemaach fir de lëtzebuergeschen E-Commerce.",
|
||||
"privacy": "Dateschutzrichtlinn",
|
||||
"terms": "Notzungsbedéngungen",
|
||||
"about": "Iwwer eis",
|
||||
@@ -188,7 +188,7 @@
|
||||
"how_step1": "Letzshop verbannen",
|
||||
"how_step1_desc": "Gitt Är Letzshop API Zougangsdaten an. An 2 Minutte fäerdeg, keng technesch Kenntnisser néideg.",
|
||||
"how_step2": "Bestellunge kommen eran",
|
||||
"how_step2_desc": "Bestellunge ginn automatesch synchroniséiert. Confirméiert an Tracking direkt vu Wizamart derbäisetzen.",
|
||||
"how_step2_desc": "Bestellunge ginn automatesch synchroniséiert. Confirméiert an Tracking direkt vu Orion derbäisetzen.",
|
||||
"how_step3": "Rechnunge generéieren",
|
||||
"how_step3_desc": "Ee Klick fir konform PDF Rechnunge mat korrekter TVA fir all EU Land ze erstellen.",
|
||||
"how_step4": "Äert Geschäft ausbauen",
|
||||
|
||||
@@ -165,8 +165,8 @@ async def homepage(
|
||||
logger.info(f"[HOMEPAGE] Rendering CMS homepage with template: {template_path}")
|
||||
return templates.TemplateResponse(template_path, context)
|
||||
|
||||
# Fallback: Default wizamart homepage (no CMS content)
|
||||
logger.info("[HOMEPAGE] No CMS homepage found, using default wizamart template")
|
||||
# Fallback: Default orion homepage (no CMS content)
|
||||
logger.info("[HOMEPAGE] No CMS homepage found, using default orion template")
|
||||
context = get_platform_context(request, db)
|
||||
context["tiers"] = _get_tiers_data(db)
|
||||
|
||||
@@ -204,7 +204,7 @@ async def homepage(
|
||||
]
|
||||
|
||||
return templates.TemplateResponse(
|
||||
"cms/platform/homepage-wizamart.html",
|
||||
"cms/platform/homepage-orion.html",
|
||||
context,
|
||||
)
|
||||
|
||||
|
||||
@@ -160,7 +160,7 @@ async def store_content_page(
|
||||
Generic content page handler for store shop (CMS).
|
||||
|
||||
Handles dynamic content pages like:
|
||||
- /stores/wizamart/about, /stores/wizamart/faq, /stores/wizamart/contact, etc.
|
||||
- /stores/orion/about, /stores/orion/faq, /stores/orion/contact, etc.
|
||||
|
||||
Features:
|
||||
- Two-tier system: Store overrides take priority, fallback to platform defaults
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
{# app/templates/platform/homepage-modern.html #}
|
||||
{# Wizamart OMS - Luxembourg-focused homepage inspired by Veeqo #}
|
||||
{# Orion OMS - Luxembourg-focused homepage inspired by Veeqo #}
|
||||
{% extends "platform/base.html" %}
|
||||
|
||||
{% block title %}
|
||||
Wizamart - The Back-Office for Letzshop Sellers
|
||||
Orion - The Back-Office for Letzshop Sellers
|
||||
{% endblock %}
|
||||
|
||||
{% block extra_head %}
|
||||
@@ -85,7 +85,7 @@
|
||||
<div class="w-3 h-3 rounded-full bg-red-500"></div>
|
||||
<div class="w-3 h-3 rounded-full bg-yellow-500"></div>
|
||||
<div class="w-3 h-3 rounded-full bg-green-500"></div>
|
||||
<span class="ml-4 text-gray-400 text-sm">Wizamart Dashboard</span>
|
||||
<span class="ml-4 text-gray-400 text-sm">Orion Dashboard</span>
|
||||
</div>
|
||||
{# Mock dashboard content #}
|
||||
<div class="p-6 space-y-4">
|
||||
@@ -219,7 +219,7 @@
|
||||
<div class="bg-white dark:bg-gray-900 rounded-2xl p-8 shadow-lg h-full">
|
||||
<div class="w-12 h-12 rounded-full bg-blue-500 text-white flex items-center justify-center font-bold text-xl mb-6">2</div>
|
||||
<h3 class="text-xl font-bold text-gray-900 dark:text-white mb-3">Orders Flow In</h3>
|
||||
<p class="text-gray-600 dark:text-gray-400">Orders sync automatically. Confirm and add tracking directly from Wizamart.</p>
|
||||
<p class="text-gray-600 dark:text-gray-400">Orders sync automatically. Confirm and add tracking directly from Orion.</p>
|
||||
</div>
|
||||
<div class="hidden lg:block absolute top-1/2 -right-4 w-8 h-0.5 bg-blue-300"></div>
|
||||
</div>
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
{# app/templates/platform/homepage-wizamart.html #}
|
||||
{# Wizamart Marketing Homepage - Letzshop OMS Platform #}
|
||||
{# app/templates/platform/homepage-orion.html #}
|
||||
{# Orion Marketing Homepage - Letzshop OMS Platform #}
|
||||
{% extends "platform/base.html" %}
|
||||
{% from 'shared/macros/inputs.html' import toggle_switch %}
|
||||
|
||||
{% block title %}Wizamart - Order Management for Letzshop Sellers{% endblock %}
|
||||
{% block title %}Orion - Order Management for Letzshop Sellers{% endblock %}
|
||||
{% block meta_description %}Lightweight OMS for Letzshop stores. Manage orders, inventory, and invoicing. Start your 30-day free trial today.{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
@@ -212,7 +212,7 @@
|
||||
|
||||
{# CTA Button #}
|
||||
{% if tier.is_enterprise %}
|
||||
<a href="mailto:sales@wizamart.com?subject=Enterprise%20Plan%20Inquiry"
|
||||
<a href="mailto:sales@orion.lu?subject=Enterprise%20Plan%20Inquiry"
|
||||
class="block w-full py-3 px-4 bg-gray-200 dark:bg-gray-700 text-gray-900 dark:text-white font-semibold rounded-xl text-center hover:bg-gray-300 dark:hover:bg-gray-600 transition-colors">
|
||||
{{ _("cms.platform.pricing.contact_sales") }}
|
||||
</a>
|
||||
@@ -7,10 +7,10 @@ Exceptions for core platform functionality including:
|
||||
- Settings management
|
||||
"""
|
||||
|
||||
from app.exceptions import WizamartException
|
||||
from app.exceptions import OrionException
|
||||
|
||||
|
||||
class CoreException(WizamartException): # noqa: MOD-025
|
||||
class CoreException(OrionException): # noqa: MOD-025
|
||||
"""Base exception for core module."""
|
||||
|
||||
|
||||
|
||||
@@ -663,11 +663,11 @@ def send_test_email(
|
||||
email_log = email_service.send_raw(
|
||||
to_email=request.to_email,
|
||||
to_name=None,
|
||||
subject="Wizamart Platform - Test Email",
|
||||
subject="Orion Platform - Test Email",
|
||||
body_html=f"""
|
||||
<html>
|
||||
<body style="font-family: Arial, sans-serif; padding: 20px;">
|
||||
<h2 style="color: #6b46c1;">Test Email from Wizamart</h2>
|
||||
<h2 style="color: #6b46c1;">Test Email from Orion</h2>
|
||||
<p>This is a test email to verify your platform email configuration.</p>
|
||||
<p>If you received this email, your email settings are working correctly!</p>
|
||||
<hr style="border: none; border-top: 1px solid #e5e7eb; margin: 20px 0;">
|
||||
@@ -678,7 +678,7 @@ def send_test_email(
|
||||
</body>
|
||||
</html>
|
||||
""",
|
||||
body_text=f"Test email from Wizamart platform.\n\nProvider: {app_settings.email_provider}\nFrom: {app_settings.email_from_address}",
|
||||
body_text=f"Test email from Orion platform.\n\nProvider: {app_settings.email_provider}\nFrom: {app_settings.email_from_address}",
|
||||
is_platform_email=True,
|
||||
)
|
||||
|
||||
|
||||
@@ -616,7 +616,7 @@ class OnboardingService:
|
||||
"success": True,
|
||||
"step_completed": True,
|
||||
"onboarding_completed": True,
|
||||
"message": "Onboarding complete! Welcome to Wizamart.",
|
||||
"message": "Onboarding complete! Welcome to Orion.",
|
||||
"redirect_url": f"/store/{store_code}/dashboard",
|
||||
}
|
||||
|
||||
|
||||
@@ -437,7 +437,7 @@ function storeLetzshop() {
|
||||
});
|
||||
|
||||
// Get the token for authentication
|
||||
const token = localStorage.getItem('wizamart_token');
|
||||
const token = localStorage.getItem('orion_token');
|
||||
if (!token) {
|
||||
throw new Error('Not authenticated');
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ const onboardingLog = window.LogConfig?.createLogger('ONBOARDING') || console;
|
||||
// Onboarding translations
|
||||
const onboardingTranslations = {
|
||||
en: {
|
||||
title: 'Welcome to Wizamart',
|
||||
title: 'Welcome to Orion',
|
||||
subtitle: 'Complete these steps to set up your store',
|
||||
steps: {
|
||||
merchant_profile: 'Merchant Profile',
|
||||
@@ -71,7 +71,7 @@ const onboardingTranslations = {
|
||||
},
|
||||
step4: {
|
||||
title: 'Historical Order Import',
|
||||
description: 'Import your existing orders from Letzshop to start managing them in Wizamart.',
|
||||
description: 'Import your existing orders from Letzshop to start managing them in Orion.',
|
||||
days_back: 'Import orders from last',
|
||||
days: 'days',
|
||||
start_import: 'Start Import',
|
||||
@@ -94,7 +94,7 @@ const onboardingTranslations = {
|
||||
},
|
||||
},
|
||||
fr: {
|
||||
title: 'Bienvenue sur Wizamart',
|
||||
title: 'Bienvenue sur Orion',
|
||||
subtitle: 'Complétez ces étapes pour configurer votre boutique',
|
||||
steps: {
|
||||
merchant_profile: 'Profil Entreprise',
|
||||
@@ -149,7 +149,7 @@ const onboardingTranslations = {
|
||||
},
|
||||
step4: {
|
||||
title: 'Import Historique des Commandes',
|
||||
description: 'Importez vos commandes existantes de Letzshop pour commencer à les gérer dans Wizamart.',
|
||||
description: 'Importez vos commandes existantes de Letzshop pour commencer à les gérer dans Orion.',
|
||||
days_back: 'Importer les commandes des derniers',
|
||||
days: 'jours',
|
||||
start_import: 'Démarrer l\'Import',
|
||||
@@ -172,7 +172,7 @@ const onboardingTranslations = {
|
||||
},
|
||||
},
|
||||
de: {
|
||||
title: 'Willkommen bei Wizamart',
|
||||
title: 'Willkommen bei Orion',
|
||||
subtitle: 'Führen Sie diese Schritte aus, um Ihren Shop einzurichten',
|
||||
steps: {
|
||||
merchant_profile: 'Firmenprofil',
|
||||
@@ -227,7 +227,7 @@ const onboardingTranslations = {
|
||||
},
|
||||
step4: {
|
||||
title: 'Historischer Bestellimport',
|
||||
description: 'Importieren Sie Ihre bestehenden Bestellungen von Letzshop, um sie in Wizamart zu verwalten.',
|
||||
description: 'Importieren Sie Ihre bestehenden Bestellungen von Letzshop, um sie in Orion zu verwalten.',
|
||||
days_back: 'Bestellungen der letzten importieren',
|
||||
days: 'Tage',
|
||||
start_import: 'Import Starten',
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{# Letzshop Store Finder Page #}
|
||||
{% extends "platform/base.html" %}
|
||||
|
||||
{% block title %}{{ _("cms.platform.find_shop.title") }} - Wizamart{% endblock %}
|
||||
{% block title %}{{ _("cms.platform.find_shop.title") }} - Orion{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div x-data="storeFinderData()" class="py-16 lg:py-24">
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Welcome to Wizamart - Setup Your Account</title>
|
||||
<title>Welcome to Orion - Setup Your Account</title>
|
||||
<link href="/static/shared/fonts/inter.css" rel="stylesheet" />
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet" />
|
||||
<link rel="stylesheet" href="{{ url_for('static', path='store/css/tailwind.output.css') }}" />
|
||||
@@ -22,7 +22,7 @@
|
||||
<div class="w-10 h-10 rounded-lg bg-purple-600 flex items-center justify-center">
|
||||
<span class="text-white font-bold text-xl">W</span>
|
||||
</div>
|
||||
<span class="text-xl font-semibold text-gray-800 dark:text-white">Wizamart</span>
|
||||
<span class="text-xl font-semibold text-gray-800 dark:text-white">Orion</span>
|
||||
</div>
|
||||
<!-- Logout Button -->
|
||||
<button @click="handleLogout()"
|
||||
|
||||
@@ -11,7 +11,7 @@ Architecture:
|
||||
- Stores MUST configure email settings to send transactional emails
|
||||
- Platform emails (billing, subscription) still use platform settings
|
||||
- Advanced providers (SendGrid, Mailgun, SES) are tier-gated (Business+)
|
||||
- "Powered by Wizamart" footer is added for Essential/Professional tiers
|
||||
- "Powered by Orion" footer is added for Essential/Professional tiers
|
||||
"""
|
||||
|
||||
import enum
|
||||
|
||||
@@ -291,7 +291,7 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"login_url": "https://example.com/login",
|
||||
"trial_days": "14",
|
||||
"tier_name": "Business",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"order_confirmation": {
|
||||
"customer_name": "Jane Doe",
|
||||
@@ -300,13 +300,13 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"order_items_count": "3",
|
||||
"order_date": "2024-01-15",
|
||||
"shipping_address": "123 Main St, Luxembourg City, L-1234",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"password_reset": {
|
||||
"customer_name": "John Doe",
|
||||
"reset_link": "https://example.com/reset?token=abc123",
|
||||
"expiry_hours": "1",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"team_invite": {
|
||||
"invitee_name": "Jane",
|
||||
@@ -315,7 +315,7 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"role": "Admin",
|
||||
"accept_url": "https://example.com/accept",
|
||||
"expires_in_days": "7",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"subscription_welcome": {
|
||||
"store_name": "Acme Corp",
|
||||
@@ -324,7 +324,7 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"amount": "€49.99",
|
||||
"next_billing_date": "2024-02-15",
|
||||
"dashboard_url": "https://example.com/dashboard",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"payment_failed": {
|
||||
"store_name": "Acme Corp",
|
||||
@@ -332,15 +332,15 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"amount": "€49.99",
|
||||
"retry_date": "2024-01-18",
|
||||
"update_payment_url": "https://example.com/billing",
|
||||
"support_email": "support@wizamart.com",
|
||||
"platform_name": "Wizamart",
|
||||
"support_email": "support@orion.lu",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"subscription_cancelled": {
|
||||
"store_name": "Acme Corp",
|
||||
"tier_name": "Business",
|
||||
"end_date": "2024-02-15",
|
||||
"reactivate_url": "https://example.com/billing",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
"trial_ending": {
|
||||
"store_name": "Acme Corp",
|
||||
@@ -349,7 +349,7 @@ def _get_sample_variables(template_code: str) -> dict[str, Any]:
|
||||
"trial_end_date": "2024-01-18",
|
||||
"upgrade_url": "https://example.com/upgrade",
|
||||
"features_list": "Unlimited products, API access, Priority support",
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
},
|
||||
}
|
||||
return samples.get(template_code, {"platform_name": "Wizamart"})
|
||||
return samples.get(template_code, {"platform_name": "Orion"})
|
||||
|
||||
@@ -184,9 +184,9 @@ def preview_template(
|
||||
variables = {
|
||||
**_get_sample_variables(code),
|
||||
**preview_data.variables,
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
"store_name": store.name if store else "Your Store",
|
||||
"support_email": store.contact_email if store else "support@wizamart.com",
|
||||
"support_email": store.contact_email if store else "support@orion.lu",
|
||||
}
|
||||
|
||||
return service.preview_store_template(
|
||||
@@ -216,9 +216,9 @@ def send_test_email(
|
||||
variables = {
|
||||
**_get_sample_variables(code),
|
||||
**test_data.variables,
|
||||
"platform_name": "Wizamart",
|
||||
"platform_name": "Orion",
|
||||
"store_name": store.name if store else "Your Store",
|
||||
"support_email": store.contact_email if store else "support@wizamart.com",
|
||||
"support_email": store.contact_email if store else "support@orion.lu",
|
||||
}
|
||||
|
||||
try:
|
||||
|
||||
@@ -51,24 +51,24 @@ from app.modules.messaging.models import (
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
# Platform branding constants
|
||||
PLATFORM_NAME = "Wizamart"
|
||||
PLATFORM_SUPPORT_EMAIL = "support@wizamart.com"
|
||||
PLATFORM_NAME = "Orion"
|
||||
PLATFORM_SUPPORT_EMAIL = "support@orion.lu"
|
||||
PLATFORM_DEFAULT_LANGUAGE = "en"
|
||||
SUPPORTED_LANGUAGES = ["en", "fr", "de", "lb"]
|
||||
|
||||
# Tiers that get white-label (no "Powered by Wizamart" footer)
|
||||
# Tiers that get white-label (no "Powered by Orion" footer)
|
||||
WHITELABEL_TIERS = {"business", "enterprise"}
|
||||
|
||||
# Powered by Wizamart footer (added for Essential/Professional tiers)
|
||||
# Powered by Orion footer (added for Essential/Professional tiers)
|
||||
POWERED_BY_FOOTER_HTML = """
|
||||
<div style="margin-top: 30px; padding-top: 20px; border-top: 1px solid #e5e7eb; text-align: center;">
|
||||
<p style="color: #9ca3af; font-size: 12px; margin: 0;">
|
||||
Powered by <a href="https://wizamart.com" style="color: #6b46c1; text-decoration: none;">Wizamart</a>
|
||||
Powered by <a href="https://orion.lu" style="color: #6b46c1; text-decoration: none;">Orion</a>
|
||||
</p>
|
||||
</div>
|
||||
"""
|
||||
|
||||
POWERED_BY_FOOTER_TEXT = "\n\n---\nPowered by Wizamart - https://wizamart.com"
|
||||
POWERED_BY_FOOTER_TEXT = "\n\n---\nPowered by Orion - https://orion.lu"
|
||||
|
||||
|
||||
@dataclass
|
||||
@@ -1045,7 +1045,7 @@ class EmailService:
|
||||
|
||||
def _should_add_powered_by_footer(self, store_id: int | None) -> bool:
|
||||
"""
|
||||
Check if "Powered by Wizamart" footer should be added.
|
||||
Check if "Powered by Orion" footer should be added.
|
||||
|
||||
Footer is added for Essential and Professional tiers.
|
||||
Business and Enterprise tiers get white-label (no footer).
|
||||
@@ -1066,7 +1066,7 @@ class EmailService:
|
||||
store_id: int | None,
|
||||
) -> tuple[str, str | None]:
|
||||
"""
|
||||
Inject "Powered by Wizamart" footer if needed based on tier.
|
||||
Inject "Powered by Orion" footer if needed based on tier.
|
||||
|
||||
Returns:
|
||||
Tuple of (modified_html, modified_text)
|
||||
@@ -1168,7 +1168,7 @@ class EmailService:
|
||||
store_logo_url=store.get_logo_url(),
|
||||
is_whitelabel=True,
|
||||
)
|
||||
# Standard: Wizamart branding with store details
|
||||
# Standard: Orion branding with store details
|
||||
return BrandingContext(
|
||||
platform_name=PLATFORM_NAME,
|
||||
platform_logo_url=None, # Use default platform logo
|
||||
@@ -1401,11 +1401,11 @@ class EmailService:
|
||||
For store emails (when store_id is provided and is_platform_email=False):
|
||||
- Uses store's SMTP/provider settings if configured
|
||||
- Uses store's from_email, from_name, reply_to
|
||||
- Adds "Powered by Wizamart" footer for Essential/Professional tiers
|
||||
- Adds "Powered by Orion" footer for Essential/Professional tiers
|
||||
|
||||
For platform emails (is_platform_email=True or no store_id):
|
||||
- Uses platform's email settings from config
|
||||
- No "Powered by Wizamart" footer
|
||||
- No "Powered by Orion" footer
|
||||
|
||||
Args:
|
||||
is_platform_email: If True, always use platform settings (for billing, etc.)
|
||||
@@ -1437,7 +1437,7 @@ class EmailService:
|
||||
from_name = from_name or self._platform_config.get("from_name", settings.email_from_name)
|
||||
reply_to = reply_to or self._platform_config.get("reply_to") or settings.email_reply_to or None
|
||||
|
||||
# Inject "Powered by Wizamart" footer for non-whitelabel tiers
|
||||
# Inject "Powered by Orion" footer for non-whitelabel tiers
|
||||
if store_id and not is_platform_email:
|
||||
body_html, body_text = self._inject_powered_by_footer(
|
||||
body_html, body_text, store_id
|
||||
|
||||
@@ -284,12 +284,12 @@ class StoreEmailSettingsService:
|
||||
def _send_smtp_test(self, settings: StoreEmailSettings, to_email: str) -> None:
|
||||
"""Send test email via SMTP."""
|
||||
msg = MIMEMultipart("alternative")
|
||||
msg["Subject"] = "Wizamart Email Configuration Test"
|
||||
msg["Subject"] = "Orion Email Configuration Test"
|
||||
msg["From"] = f"{settings.from_name} <{settings.from_email}>"
|
||||
msg["To"] = to_email
|
||||
|
||||
text_content = (
|
||||
"This is a test email from Wizamart.\n\n"
|
||||
"This is a test email from Orion.\n\n"
|
||||
"Your email settings are configured correctly!\n\n"
|
||||
f"Provider: SMTP\n"
|
||||
f"Host: {settings.smtp_host}\n"
|
||||
@@ -298,7 +298,7 @@ class StoreEmailSettingsService:
|
||||
<html>
|
||||
<body style="font-family: Arial, sans-serif; padding: 20px;">
|
||||
<h2 style="color: #6b46c1;">Email Configuration Test</h2>
|
||||
<p>This is a test email from <strong>Wizamart</strong>.</p>
|
||||
<p>This is a test email from <strong>Orion</strong>.</p>
|
||||
<p style="color: #22c55e; font-weight: bold;">
|
||||
Your email settings are configured correctly!
|
||||
</p>
|
||||
@@ -341,12 +341,12 @@ class StoreEmailSettingsService:
|
||||
message = Mail(
|
||||
from_email=(settings.from_email, settings.from_name),
|
||||
to_emails=to_email,
|
||||
subject="Wizamart Email Configuration Test",
|
||||
subject="Orion Email Configuration Test",
|
||||
html_content="""
|
||||
<html>
|
||||
<body style="font-family: Arial, sans-serif; padding: 20px;">
|
||||
<h2 style="color: #6b46c1;">Email Configuration Test</h2>
|
||||
<p>This is a test email from <strong>Wizamart</strong>.</p>
|
||||
<p>This is a test email from <strong>Orion</strong>.</p>
|
||||
<p style="color: #22c55e; font-weight: bold;">
|
||||
Your SendGrid settings are configured correctly!
|
||||
</p>
|
||||
@@ -374,12 +374,12 @@ class StoreEmailSettingsService:
|
||||
data={
|
||||
"from": f"{settings.from_name} <{settings.from_email}>",
|
||||
"to": to_email,
|
||||
"subject": "Wizamart Email Configuration Test",
|
||||
"subject": "Orion Email Configuration Test",
|
||||
"html": """
|
||||
<html>
|
||||
<body style="font-family: Arial, sans-serif; padding: 20px;">
|
||||
<h2 style="color: #6b46c1;">Email Configuration Test</h2>
|
||||
<p>This is a test email from <strong>Wizamart</strong>.</p>
|
||||
<p>This is a test email from <strong>Orion</strong>.</p>
|
||||
<p style="color: #22c55e; font-weight: bold;">
|
||||
Your Mailgun settings are configured correctly!
|
||||
</p>
|
||||
@@ -417,14 +417,14 @@ class StoreEmailSettingsService:
|
||||
Source=f"{settings.from_name} <{settings.from_email}>",
|
||||
Destination={"ToAddresses": [to_email]},
|
||||
Message={
|
||||
"Subject": {"Data": "Wizamart Email Configuration Test"},
|
||||
"Subject": {"Data": "Orion Email Configuration Test"},
|
||||
"Body": {
|
||||
"Html": {
|
||||
"Data": """
|
||||
<html>
|
||||
<body style="font-family: Arial, sans-serif; padding: 20px;">
|
||||
<h2 style="color: #6b46c1;">Email Configuration Test</h2>
|
||||
<p>This is a test email from <strong>Wizamart</strong>.</p>
|
||||
<p>This is a test email from <strong>Orion</strong>.</p>
|
||||
<p style="color: #22c55e; font-weight: bold;">
|
||||
Your Amazon SES settings are configured correctly!
|
||||
</p>
|
||||
|
||||
@@ -236,7 +236,7 @@ function emailTemplatesPage() {
|
||||
expires_in_days: '7'
|
||||
}
|
||||
};
|
||||
return samples[templateCode] || { platform_name: 'Wizamart' };
|
||||
return samples[templateCode] || { platform_name: 'Orion' };
|
||||
},
|
||||
|
||||
// Test Email
|
||||
|
||||
@@ -35,8 +35,8 @@ class TestEmailProviders:
|
||||
subject="Test Subject",
|
||||
body_html="<h1>Hello</h1>",
|
||||
body_text="Hello",
|
||||
from_email="noreply@wizamart.com",
|
||||
from_name="Wizamart",
|
||||
from_email="noreply@orion.lu",
|
||||
from_name="Orion",
|
||||
)
|
||||
|
||||
assert success is True
|
||||
@@ -53,9 +53,9 @@ class TestEmailProviders:
|
||||
subject="Test Subject",
|
||||
body_html="<h1>Hello</h1>",
|
||||
body_text=None,
|
||||
from_email="noreply@wizamart.com",
|
||||
from_name="Wizamart",
|
||||
reply_to="support@wizamart.com",
|
||||
from_email="noreply@orion.lu",
|
||||
from_name="Orion",
|
||||
reply_to="support@orion.lu",
|
||||
)
|
||||
|
||||
assert success is True
|
||||
|
||||
@@ -253,7 +253,7 @@
|
||||
<span class="text-gray-600 dark:text-gray-400" x-html="$icon('cog', 'w-5 h-5')"></span>
|
||||
<span class="text-sm font-medium text-gray-700 dark:text-gray-300">Platform Settings</span>
|
||||
</a>
|
||||
<a href="https://docs.wizamart.com/architecture/capacity-planning/" target="_blank" class="flex items-center gap-3 p-3 rounded-lg border border-gray-200 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-700 transition-colors">
|
||||
<a href="https://docs.orion.lu/architecture/capacity-planning/" target="_blank" class="flex items-center gap-3 p-3 rounded-lg border border-gray-200 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-700 transition-colors">
|
||||
<span class="text-blue-600 dark:text-blue-400" x-html="$icon('book-open', 'w-5 h-5')"></span>
|
||||
<span class="text-sm font-medium text-gray-700 dark:text-gray-300">Capacity Planning Docs</span>
|
||||
</a>
|
||||
|
||||
@@ -12,9 +12,9 @@ from typing import Any
|
||||
|
||||
from app.exceptions.base import (
|
||||
BusinessLogicException,
|
||||
OrionException,
|
||||
ResourceNotFoundException,
|
||||
ValidationException,
|
||||
WizamartException,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
@@ -182,7 +182,7 @@ class InvoiceSettingsNotFoundException(ResourceNotFoundException):
|
||||
)
|
||||
|
||||
|
||||
class InvoiceSettingsAlreadyExistException(WizamartException): # noqa: MOD-025
|
||||
class InvoiceSettingsAlreadyExistException(OrionException): # noqa: MOD-025
|
||||
"""Raised when trying to create invoice settings that already exist."""
|
||||
|
||||
def __init__(self, store_id: int):
|
||||
@@ -205,7 +205,7 @@ class InvoiceValidationException(BusinessLogicException):
|
||||
)
|
||||
|
||||
|
||||
class InvoicePDFGenerationException(WizamartException):
|
||||
class InvoicePDFGenerationException(OrionException):
|
||||
"""Raised when PDF generation fails."""
|
||||
|
||||
def __init__(self, invoice_id: int, reason: str):
|
||||
|
||||
@@ -13,9 +13,9 @@ from app.exceptions.base import (
|
||||
BusinessLogicException,
|
||||
ConflictException,
|
||||
ExternalServiceException,
|
||||
OrionException,
|
||||
ResourceNotFoundException,
|
||||
ValidationException,
|
||||
WizamartException,
|
||||
)
|
||||
|
||||
# =============================================================================
|
||||
@@ -116,7 +116,7 @@ class UserAlreadyExistsException(ConflictException):
|
||||
# =============================================================================
|
||||
|
||||
|
||||
class PlatformNotFoundException(WizamartException):
|
||||
class PlatformNotFoundException(OrionException):
|
||||
"""Raised when a platform is not found."""
|
||||
|
||||
def __init__(self, code: str):
|
||||
@@ -128,7 +128,7 @@ class PlatformNotFoundException(WizamartException):
|
||||
)
|
||||
|
||||
|
||||
class PlatformInactiveException(WizamartException): # noqa: MOD-025
|
||||
class PlatformInactiveException(OrionException): # noqa: MOD-025
|
||||
"""Raised when trying to access an inactive platform."""
|
||||
|
||||
def __init__(self, code: str):
|
||||
@@ -140,7 +140,7 @@ class PlatformInactiveException(WizamartException): # noqa: MOD-025
|
||||
)
|
||||
|
||||
|
||||
class PlatformUpdateException(WizamartException): # noqa: MOD-025
|
||||
class PlatformUpdateException(OrionException): # noqa: MOD-025
|
||||
"""Raised when platform update fails."""
|
||||
|
||||
def __init__(self, code: str, reason: str):
|
||||
|
||||
@@ -34,7 +34,7 @@ class MerchantDomain(Base, TimestampMixin):
|
||||
|
||||
Examples:
|
||||
- myloyaltyprogram.lu -> Merchant "WizaCorp" (all stores inherit)
|
||||
- Store WIZAMART overrides with StoreDomain -> mysuperloyaltyprogram.lu
|
||||
- Store ORION overrides with StoreDomain -> mysuperloyaltyprogram.lu
|
||||
- Store WIZAGADGETS -> inherits myloyaltyprogram.lu
|
||||
"""
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ class Platform(Base, TimestampMixin):
|
||||
Represents a business offering/product line.
|
||||
|
||||
Examples:
|
||||
- Wizamart OMS (Order Management System)
|
||||
- Orion OMS (Order Management System)
|
||||
- Loyalty+ (Loyalty Program Platform)
|
||||
- Site Builder (Website Builder for Local Businesses)
|
||||
|
||||
@@ -62,7 +62,7 @@ class Platform(Base, TimestampMixin):
|
||||
name = Column(
|
||||
String(100),
|
||||
nullable=False,
|
||||
comment="Display name (e.g., 'Wizamart OMS')",
|
||||
comment="Display name (e.g., 'Orion OMS')",
|
||||
)
|
||||
|
||||
description = Column(
|
||||
|
||||
@@ -40,8 +40,8 @@ class StorePlatform(Base, TimestampMixin):
|
||||
- Store platform-specific settings
|
||||
|
||||
Example:
|
||||
- Store "WizaMart" is on OMS platform (Professional tier)
|
||||
- Store "WizaMart" is also on Loyalty platform (Basic tier)
|
||||
- Store "Orion" is on OMS platform (Professional tier)
|
||||
- Store "Orion" is also on Loyalty platform (Basic tier)
|
||||
"""
|
||||
|
||||
__tablename__ = "store_platforms"
|
||||
|
||||
@@ -249,7 +249,7 @@ def verify_merchant_domain_ownership(
|
||||
Verify merchant domain ownership via DNS TXT record (Admin only).
|
||||
|
||||
**Verification Process:**
|
||||
1. Queries DNS for TXT record: `_wizamart-verify.{domain}`
|
||||
1. Queries DNS for TXT record: `_orion-verify.{domain}`
|
||||
2. Checks if verification token matches
|
||||
3. If found, marks domain as verified
|
||||
|
||||
|
||||
@@ -247,14 +247,14 @@ def verify_domain_ownership(
|
||||
Verify domain ownership via DNS TXT record (Admin only).
|
||||
|
||||
**Verification Process:**
|
||||
1. Queries DNS for TXT record: `_wizamart-verify.{domain}`
|
||||
1. Queries DNS for TXT record: `_orion-verify.{domain}`
|
||||
2. Checks if verification token matches
|
||||
3. If found, marks domain as verified
|
||||
|
||||
**Requirements:**
|
||||
- Store must have added TXT record to their DNS
|
||||
- DNS propagation may take 5-15 minutes
|
||||
- Record format: `_wizamart-verify.domain.com` TXT `{token}`
|
||||
- Record format: `_orion-verify.domain.com` TXT `{token}`
|
||||
|
||||
**After verification:**
|
||||
- Domain can be activated
|
||||
|
||||
@@ -42,7 +42,7 @@ def get_store_info(
|
||||
**Returns only active stores** to prevent access to disabled accounts.
|
||||
|
||||
Args:
|
||||
store_code: The store's unique code (e.g., 'WIZAMART')
|
||||
store_code: The store's unique code (e.g., 'ORION')
|
||||
db: Database session
|
||||
|
||||
Returns:
|
||||
|
||||
@@ -293,7 +293,7 @@ class MerchantDomainService:
|
||||
Verify merchant domain ownership via DNS TXT record.
|
||||
|
||||
The merchant must add a TXT record:
|
||||
Name: _wizamart-verify.{domain}
|
||||
Name: _orion-verify.{domain}
|
||||
Value: {verification_token}
|
||||
"""
|
||||
try:
|
||||
@@ -304,7 +304,7 @@ class MerchantDomainService:
|
||||
|
||||
try:
|
||||
txt_records = dns.resolver.resolve(
|
||||
f"_wizamart-verify.{domain.domain}", "TXT"
|
||||
f"_orion-verify.{domain.domain}", "TXT"
|
||||
)
|
||||
|
||||
for txt in txt_records:
|
||||
@@ -331,7 +331,7 @@ class MerchantDomainService:
|
||||
except dns.resolver.NXDOMAIN:
|
||||
raise DomainVerificationFailedException(
|
||||
domain.domain,
|
||||
f"DNS record _wizamart-verify.{domain.domain} not found",
|
||||
f"DNS record _orion-verify.{domain.domain} not found",
|
||||
)
|
||||
except dns.resolver.NoAnswer:
|
||||
raise DomainVerificationFailedException(
|
||||
@@ -368,7 +368,7 @@ class MerchantDomainService:
|
||||
},
|
||||
"txt_record": {
|
||||
"type": "TXT",
|
||||
"name": "_wizamart-verify",
|
||||
"name": "_orion-verify",
|
||||
"value": domain.verification_token,
|
||||
"ttl": 3600,
|
||||
},
|
||||
|
||||
@@ -284,7 +284,7 @@ class StoreDomainService:
|
||||
Verify domain ownership via DNS TXT record.
|
||||
|
||||
The store must add a TXT record:
|
||||
Name: _wizamart-verify.{domain}
|
||||
Name: _orion-verify.{domain}
|
||||
Value: {verification_token}
|
||||
|
||||
Args:
|
||||
@@ -309,7 +309,7 @@ class StoreDomainService:
|
||||
# Query DNS TXT records
|
||||
try:
|
||||
txt_records = dns.resolver.resolve(
|
||||
f"_wizamart-verify.{domain.domain}", "TXT"
|
||||
f"_orion-verify.{domain.domain}", "TXT"
|
||||
)
|
||||
|
||||
# Check if verification token is present
|
||||
@@ -333,7 +333,7 @@ class StoreDomainService:
|
||||
except dns.resolver.NXDOMAIN:
|
||||
raise DomainVerificationFailedException(
|
||||
domain.domain,
|
||||
f"DNS record _wizamart-verify.{domain.domain} not found",
|
||||
f"DNS record _orion-verify.{domain.domain} not found",
|
||||
)
|
||||
except dns.resolver.NoAnswer:
|
||||
raise DomainVerificationFailedException(
|
||||
@@ -382,7 +382,7 @@ class StoreDomainService:
|
||||
},
|
||||
"txt_record": {
|
||||
"type": "TXT",
|
||||
"name": "_wizamart-verify",
|
||||
"name": "_orion-verify",
|
||||
"value": domain.verification_token,
|
||||
"ttl": 3600,
|
||||
},
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Merchant Login - Wizamart</title>
|
||||
<title>Merchant Login - Orion</title>
|
||||
<!-- Fonts: Local fallback + Google Fonts -->
|
||||
<link href="/static/shared/fonts/inter.css" rel="stylesheet" />
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap" rel="stylesheet" />
|
||||
|
||||
@@ -514,7 +514,7 @@ class TestMerchantDomainServiceInstructions:
|
||||
assert "instructions" in instructions
|
||||
assert "txt_record" in instructions
|
||||
assert instructions["txt_record"]["type"] == "TXT"
|
||||
assert instructions["txt_record"]["name"] == "_wizamart-verify"
|
||||
assert instructions["txt_record"]["name"] == "_orion-verify"
|
||||
assert "common_registrars" in instructions
|
||||
|
||||
def test_get_verification_instructions_not_found(self, db):
|
||||
|
||||
@@ -411,7 +411,7 @@ class TestStoreDomainServiceInstructions:
|
||||
assert "instructions" in instructions
|
||||
assert "txt_record" in instructions
|
||||
assert instructions["txt_record"]["type"] == "TXT"
|
||||
assert instructions["txt_record"]["name"] == "_wizamart-verify"
|
||||
assert instructions["txt_record"]["name"] == "_orion-verify"
|
||||
assert "common_registrars" in instructions
|
||||
|
||||
def test_get_verification_instructions_not_found(self, db):
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>{% block title %}Merchant Portal{% endblock %} - Wizamart</title>
|
||||
<title>{% block title %}Merchant Portal{% endblock %} - Orion</title>
|
||||
|
||||
<!-- Fonts: Local fallback + Google Fonts -->
|
||||
<link href="/static/shared/fonts/inter.css" rel="stylesheet" />
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
{# Dynamic page title #}
|
||||
<title>{% block title %}Wizamart - Order Management for Letzshop Sellers{% endblock %}</title>
|
||||
<title>{% block title %}Orion - Order Management for Letzshop Sellers{% endblock %}</title>
|
||||
|
||||
{# SEO Meta Tags #}
|
||||
<meta name="description" content="{% block meta_description %}Lightweight OMS for Letzshop stores in Luxembourg. Order management, inventory, and invoicing made simple.{% endblock %}">
|
||||
@@ -64,7 +64,7 @@
|
||||
<span class="text-white font-bold text-xl">W</span>
|
||||
</div>
|
||||
<span class="text-xl font-bold text-gray-900 dark:text-white">
|
||||
Wizamart
|
||||
Orion
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
@@ -190,7 +190,7 @@
|
||||
<span class="text-white font-bold text-xl">W</span>
|
||||
</div>
|
||||
<span class="text-xl font-bold text-gray-900 dark:text-white">
|
||||
Wizamart
|
||||
Orion
|
||||
</span>
|
||||
</div>
|
||||
<p class="text-gray-600 dark:text-gray-400 text-sm">
|
||||
@@ -225,7 +225,7 @@
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="/store/wizamart/login" class="text-gray-600 dark:text-gray-400 hover:text-primary transition-colors">
|
||||
<a href="/store/orion/login" class="text-gray-600 dark:text-gray-400 hover:text-primary transition-colors">
|
||||
{{ _("cms.platform.nav.store_login") }}
|
||||
</a>
|
||||
</li>
|
||||
|
||||
@@ -19,7 +19,7 @@ logger = logging.getLogger(__name__)
|
||||
|
||||
# Salt for key derivation - fixed to ensure consistent encryption/decryption
|
||||
# In production, this should be stored securely and not changed
|
||||
_ENCRYPTION_SALT = b"wizamart_encryption_salt_v1"
|
||||
_ENCRYPTION_SALT = b"orion_encryption_salt_v1"
|
||||
|
||||
|
||||
class EncryptionError(Exception):
|
||||
|
||||
Reference in New Issue
Block a user