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:
@@ -23,7 +23,7 @@ The platform is evolving from a single OMS product to a **multi-platform busines
|
||||
| Issue | Description |
|
||||
|-------|-------------|
|
||||
| **Conflated page types** | Platform pages and store defaults share `store_id = NULL`, making them indistinguishable |
|
||||
| **Hardcoded homepage** | Platform homepage uses `homepage-wizamart.html` directly, ignoring CMS |
|
||||
| **Hardcoded homepage** | Platform homepage uses `homepage-orion.html` directly, ignoring CMS |
|
||||
| **Non-functional admin UI** | `/admin/platform-homepage` saves to CMS but route doesn't use it |
|
||||
| **Single platform assumption** | Architecture assumes one platform, can't scale to multiple offerings |
|
||||
| **No platform isolation** | No way to have separate About/FAQ/Pricing pages per platform |
|
||||
@@ -48,7 +48,7 @@ ContentPage (store_id = NULL)
|
||||
│ PLATFORM LEVEL │
|
||||
│ ┌──────────────────┐ ┌──────────────────┐ ┌──────────────────┐ │
|
||||
│ │ Platform A │ │ Platform B │ │ Platform C │ │
|
||||
│ │ (Wizamart OMS) │ │ (Loyalty+) │ │ (Site Builder) │ │
|
||||
│ │ (Orion OMS) │ │ (Loyalty+) │ │ (Site Builder) │ │
|
||||
│ │ │ │ │ │ │ │
|
||||
│ │ • Homepage │ │ • Homepage │ │ • Homepage │ │
|
||||
│ │ • About │ │ • About │ │ • About │ │
|
||||
@@ -76,7 +76,7 @@ ContentPage (store_id = NULL)
|
||||
┌─────────────────────────────────────────────────────────────────────────────┐
|
||||
│ STORE LEVEL (isolated) │
|
||||
│ ┌─────────────────────────┐ ┌─────────────────────────┐ │
|
||||
│ │ Store 1 (WizaMart) │ │ Store 2 (TechStore) │ │
|
||||
│ │ Store 1 (Orion) │ │ Store 2 (TechStore) │ │
|
||||
│ │ Platform A, Tier: Pro │ │ Platform A, Tier: Basic │ │
|
||||
│ │ │ │ │ │
|
||||
│ │ Override Pages: │ │ Override Pages: │ │
|
||||
@@ -114,14 +114,14 @@ When a customer visits `store1.example.com/about`:
|
||||
class Platform(Base):
|
||||
"""
|
||||
Represents a business offering/product line.
|
||||
Examples: Wizamart OMS, Loyalty+, Site Builder
|
||||
Examples: Orion OMS, Loyalty+, Site Builder
|
||||
"""
|
||||
__tablename__ = "platforms"
|
||||
|
||||
id = Column(Integer, primary_key=True)
|
||||
code = Column(String(50), unique=True, nullable=False) # "oms", "loyalty", "sites"
|
||||
name = Column(String(100), nullable=False) # "Wizamart OMS"
|
||||
domain = Column(String(255), nullable=True) # "wizamart.lu"
|
||||
name = Column(String(100), nullable=False) # "Orion OMS"
|
||||
domain = Column(String(255), nullable=True) # "orion.lu"
|
||||
|
||||
# Branding
|
||||
logo = Column(String(500), nullable=True)
|
||||
@@ -219,8 +219,8 @@ class Store(Base):
|
||||
|-----------|:-----------:|:---------:|:----------------:|---------|
|
||||
| Platform Marketing Page | ✓ | NULL | TRUE | Platform A's homepage, pricing |
|
||||
| Store Default Page | ✓ | NULL | FALSE | Generic "About Our Store" template |
|
||||
| Store Override Page | ✓ | ✓ | FALSE | WizaMart's custom About page |
|
||||
| Store Custom Page | ✓ | ✓ | FALSE | WizaMart's "Store Locations" page |
|
||||
| Store Override Page | ✓ | ✓ | FALSE | Orion's custom About page |
|
||||
| Store Custom Page | ✓ | ✓ | FALSE | Orion's "Store Locations" page |
|
||||
|
||||
---
|
||||
|
||||
@@ -237,7 +237,7 @@ class Store(Base):
|
||||
3. Admin fills in:
|
||||
- Code: "loyalty"
|
||||
- Name: "Loyalty+"
|
||||
- Domain: "loyalty.wizamart.lu"
|
||||
- Domain: "loyalty.orion.lu"
|
||||
- Logo, theme colors
|
||||
4. Admin saves platform
|
||||
5. System creates platform record
|
||||
@@ -250,7 +250,7 @@ class Store(Base):
|
||||
- Contact (is_platform_page=True)
|
||||
8. Each page can use different templates (modern, minimal, etc.)
|
||||
9. Admin publishes pages
|
||||
10. Platform marketing site is now live at loyalty.wizamart.lu
|
||||
10. Platform marketing site is now live at loyalty.orion.lu
|
||||
```
|
||||
|
||||
### Journey 2: Platform Admin Creates Store Defaults
|
||||
@@ -308,7 +308,7 @@ class Store(Base):
|
||||
|
||||
### Journey 4: Store Overrides a Default Page
|
||||
|
||||
**Actor:** Store (WizaMart)
|
||||
**Actor:** Store (Orion)
|
||||
**Goal:** Customize the About page with store-specific content
|
||||
|
||||
```
|
||||
@@ -318,21 +318,21 @@ class Store(Base):
|
||||
4. Clicks "Override" button
|
||||
5. System creates a copy with store_id set
|
||||
6. Store edits content:
|
||||
- Title: "About WizaMart"
|
||||
- Content: "WizaMart was founded in 2020 in Luxembourg..."
|
||||
- Title: "About Orion"
|
||||
- Content: "Orion was founded in 2020 in Luxembourg..."
|
||||
- Adds store images
|
||||
7. Store saves and publishes
|
||||
8. Page list now shows:
|
||||
┌─────────────────────────────────────────────────────────┐
|
||||
│ About Us │ Custom Override │ Published │ Edit │
|
||||
└─────────────────────────────────────────────────────────┘
|
||||
9. Customer visits wizamart.example.com/about
|
||||
10. Sees WizaMart's custom About page
|
||||
9. Customer visits orion.example.com/about
|
||||
10. Sees Orion's custom About page
|
||||
```
|
||||
|
||||
### Journey 5: Store Creates a Custom Page
|
||||
|
||||
**Actor:** Store (WizaMart)
|
||||
**Actor:** Store (Orion)
|
||||
**Goal:** Add a new page that doesn't exist in defaults
|
||||
|
||||
```
|
||||
@@ -346,12 +346,12 @@ class Store(Base):
|
||||
- Show in footer: Yes
|
||||
5. Store saves and publishes
|
||||
6. Page appears in storefront footer navigation
|
||||
7. Accessible at wizamart.example.com/store-locations
|
||||
7. Accessible at orion.example.com/store-locations
|
||||
```
|
||||
|
||||
### Journey 6: Store Reverts Override to Default
|
||||
|
||||
**Actor:** Store (WizaMart)
|
||||
**Actor:** Store (Orion)
|
||||
**Goal:** Remove customization and use platform default again
|
||||
|
||||
```
|
||||
@@ -372,19 +372,19 @@ class Store(Base):
|
||||
**Goal:** Read store policies before purchasing
|
||||
|
||||
```
|
||||
1. Customer visits wizamart.example.com
|
||||
1. Customer visits orion.example.com
|
||||
2. Browses products, adds to cart
|
||||
3. Wants to check return policy
|
||||
4. Clicks "Returns" in footer
|
||||
5. System resolves page:
|
||||
- Check: WizaMart override? NO
|
||||
- Check: Orion override? NO
|
||||
- Check: Platform A default? YES
|
||||
- Serve: Platform A default "Return Policy" page
|
||||
6. Customer reads return policy
|
||||
7. Customer clicks "About Us" in footer
|
||||
8. System resolves page:
|
||||
- Check: WizaMart override? YES
|
||||
- Serve: WizaMart's custom "About WizaMart" page
|
||||
- Check: Orion override? YES
|
||||
- Serve: Orion's custom "About Orion" page
|
||||
9. Customer sees store-specific About page
|
||||
```
|
||||
|
||||
@@ -539,7 +539,7 @@ GET /api/v1/platform/{code}/pages/navigation # Get platform nav
|
||||
```sql
|
||||
-- 1. Create default platform
|
||||
INSERT INTO platforms (code, name, domain, is_active)
|
||||
VALUES ('oms', 'Wizamart OMS', 'localhost:8000', true);
|
||||
VALUES ('oms', 'Orion OMS', 'localhost:8000', true);
|
||||
|
||||
-- 2. Update all existing content_pages
|
||||
UPDATE content_pages
|
||||
@@ -567,7 +567,7 @@ SET platform_id = (SELECT id FROM platforms WHERE code = 'oms');
|
||||
## Open Questions
|
||||
|
||||
1. **Domain routing**: How to route requests to correct platform?
|
||||
- Option A: Separate domains (oms.wizamart.lu, loyalty.wizamart.lu)
|
||||
- Option A: Separate domains (oms.orion.lu, loyalty.orion.lu)
|
||||
- Option B: Path-based (/oms/*, /loyalty/*)
|
||||
- Option C: Subdomain detection
|
||||
|
||||
|
||||
Reference in New Issue
Block a user