diff --git a/CLAUDE.md b/CLAUDE.md index ecfc4ef..2d68d14 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -1,7 +1,7 @@ # WooCommerce Tier and Package Prices - AI Context Document **Last Updated:** 2025-12-30 -**Current Version:** 1.2.7 +**Current Version:** 1.2.8 **Author:** Marco Graetsch **Project Status:** Production-ready WordPress plugin @@ -692,7 +692,7 @@ zip -r wc-tier-and-package-prices/releases/wc-tier-and-package-prices-X.X.X.zip **Critical Exclusions:** -- `*/wordpress/*` - MUST be excluded! The project has a symlink to WordPress installation that zip will follow, creating 129MB+ packages instead of ~430KB +- `*/wordpress/*` and `*/core/*` - MUST be excluded! The project has a symlink to WordPress installation that zip will follow, creating 129MB+ packages instead of ~430KB - `.git/*` - All git metadata (multiple patterns needed for reliability) - `.claude/*` and `CLAUDE.md` - Development documentation - `releases/*` - Prevents including previous releases in new ones @@ -775,7 +775,13 @@ Roadmap for the upcoming development. 1. ✅ **COMPLETED** - Updated all translation files (.pot, .po, .mo) with new strings from v1.2.6 and v1.2.7 for variable product parent pricing features. All 7 language variants updated with translations for "Default Tier & Package Pricing for All Variations" and related strings. -##### Planned Enhancements for v1.2.8+ +##### Bugfixes (Completed in v1.2.8) + +1. ~~Add a Suffix with the current configured default currency to the table-header and form placeholder. Use the common currency notation in placeholder~~ ✅ **FIXED in v1.2.8** - Updated all table headers in admin to display "Price (€)" format using `printf(__('Price (%s)'), get_woocommerce_currency_symbol())`. Modified all template render methods (tier_row, package_row, variation_tier_row, variation_package_row) to pass currency_symbol to Twig templates. Updated admin/tier-row.twig and admin/package-row.twig to concatenate currency symbol in price input placeholders (e.g., "e.g., 9.99 €"). Applied to simple products, variable parent products, and all variations. + +2. ~~Already stored tier and package prices on the children of a variable product are still available after deletion. Looks like the storage mechanism has an error. This occurs only on the child product, not on the parent product.~~ ✅ **FIXED in v1.2.8** - Fixed save logic in both `save_tier_package_fields()` and `save_variation_pricing_fields()` methods. Root cause: Empty arrays were being saved via `update_post_meta()` instead of being deleted. Changed logic from "save on isset, delete otherwise" to "filter entries, then save if not empty, delete if empty". Added `if (!empty($tiers))` and `if (!empty($packages))` checks before calling `update_post_meta()`. Now properly calls `delete_post_meta()` when all pricing entries are removed, preventing empty arrays from persisting in database. + +##### Planned Enhancements for v1.2.9+ 1. Create different, selectable templates for tierprices and packages to use in the frontend. Make the new templates selectable globally on the settings-page, not per product.