You've already forked wc-licensed-product
Update CLAUDE.md with v0.5.0 session history
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
78
CLAUDE.md
78
CLAUDE.md
@@ -36,10 +36,6 @@ This project is proudly **"vibe-coded"** using Claude.AI - the entire codebase w
|
|||||||
|
|
||||||
No known bugs at the moment.
|
No known bugs at the moment.
|
||||||
|
|
||||||
### Version 0.5.0
|
|
||||||
|
|
||||||
No changes at the moment.
|
|
||||||
|
|
||||||
## Technical Stack
|
## Technical Stack
|
||||||
|
|
||||||
- **Language:** PHP 8.3.x
|
- **Language:** PHP 8.3.x
|
||||||
@@ -1190,3 +1186,77 @@ Added self-licensing prevention to avoid circular dependency when the plugin tri
|
|||||||
- Created release package: `releases/wc-licensed-product-0.4.0.zip` (852 KB)
|
- Created release package: `releases/wc-licensed-product-0.4.0.zip` (852 KB)
|
||||||
- SHA256: `cf8769c861d77c327f178049d5fac0d4e47679cc1a1d35c5b613e4cd3fb8674f`
|
- SHA256: `cf8769c861d77c327f178049d5fac0d4e47679cc1a1d35c5b613e4cd3fb8674f`
|
||||||
- Tagged as `v0.4.0` and pushed to `main` branch
|
- Tagged as `v0.4.0` and pushed to `main` branch
|
||||||
|
|
||||||
|
### 2026-01-25 - Version 0.5.0 - Multi-Domain Licensing
|
||||||
|
|
||||||
|
**Overview:**
|
||||||
|
|
||||||
|
Major feature release enabling customers to purchase multiple licenses for different domains in a single order. Each cart item quantity requires a unique domain at checkout.
|
||||||
|
|
||||||
|
**Implemented:**
|
||||||
|
|
||||||
|
- Multi-domain licensing support with new setting "Enable Multi-Domain Licensing"
|
||||||
|
- Multi-domain checkout UI for both classic checkout and WooCommerce Blocks
|
||||||
|
- Grouped license display in customer account page by product/order (package view)
|
||||||
|
- "Older versions" collapsible section in customer download area
|
||||||
|
- Updated email templates to show licenses grouped by product
|
||||||
|
- DOM injection fallback for WooCommerce Blocks when React component fails
|
||||||
|
|
||||||
|
**New Setting:**
|
||||||
|
|
||||||
|
- `wclp_enable_multi_domain` - Enable/disable multi-domain licensing mode
|
||||||
|
|
||||||
|
**New Order Meta:**
|
||||||
|
|
||||||
|
- `_licensed_product_domains` - Array of domain data for multi-domain orders:
|
||||||
|
|
||||||
|
```php
|
||||||
|
[
|
||||||
|
['product_id' => 123, 'domains' => ['site1.com', 'site2.com']],
|
||||||
|
['product_id' => 456, 'domains' => ['another.com']],
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
**Modified files:**
|
||||||
|
|
||||||
|
- `src/Admin/SettingsController.php` - Added multi-domain setting
|
||||||
|
- `src/Checkout/CheckoutController.php` - Multi-domain field rendering and validation
|
||||||
|
- `src/Checkout/CheckoutBlocksIntegration.php` - WooCommerce Blocks multi-domain support
|
||||||
|
- `src/Checkout/StoreApiExtension.php` - Multi-domain data handling in Store API
|
||||||
|
- `src/Frontend/AccountController.php` - Grouped license display by product
|
||||||
|
- `src/Email/LicenseEmailController.php` - Grouped license email templates
|
||||||
|
- `src/Plugin.php` - Multi-domain license generation
|
||||||
|
- `src/License/LicenseManager.php` - Multi-domain license creation
|
||||||
|
- `src/Admin/OrderLicenseController.php` - Multi-domain order display
|
||||||
|
- `assets/js/checkout-blocks.js` - Complete rewrite for ExperimentalOrderMeta slot
|
||||||
|
- `assets/js/frontend.js` - Older versions toggle functionality
|
||||||
|
- `assets/css/frontend.css` - Package-based layout styles
|
||||||
|
- `templates/frontend/licenses.html.twig` - Grouped license template
|
||||||
|
|
||||||
|
**Technical notes:**
|
||||||
|
|
||||||
|
- WooCommerce Blocks integration uses `ExperimentalOrderMeta` slot with `registerPlugin`
|
||||||
|
- DOM injection fallback activates after 2 seconds if React component fails to render
|
||||||
|
- Multi-domain validation ensures unique domains per product
|
||||||
|
- Backward compatible: existing single-domain orders continue to work
|
||||||
|
- New `getLicensesByOrderAndProduct()` method returns all licenses for a product in an order
|
||||||
|
- Customer account groups licenses by product for package-style display
|
||||||
|
- Email templates show licenses in table format grouped by product
|
||||||
|
|
||||||
|
**Bug Fix:**
|
||||||
|
|
||||||
|
- Fixed: Domain fields not rendering in WooCommerce Blocks checkout
|
||||||
|
- Root cause: `registerCheckoutBlock` approach requires manual block editor configuration
|
||||||
|
- Fix: Switched to `ExperimentalOrderMeta` slot pattern with `registerPlugin` + DOM injection fallback
|
||||||
|
|
||||||
|
**Translation Updates:**
|
||||||
|
|
||||||
|
- Added 19 new strings for multi-domain functionality
|
||||||
|
- Fixed all fuzzy translations in German (de_CH)
|
||||||
|
- Updated .pot template and compiled .mo files
|
||||||
|
|
||||||
|
**Release v0.5.0:**
|
||||||
|
|
||||||
|
- Created release package: `releases/wc-licensed-product-0.5.0.zip` (863 KB)
|
||||||
|
- SHA256: `446804948e5f99d705b548061d5b78180856984c58458640a910ada8f27f5316`
|
||||||
|
- Tagged as `v0.5.0` and pushed to `main` branch
|
||||||
|
|||||||
Reference in New Issue
Block a user