diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1e3edbd4c8..a3819fbc12 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,6 +5,7 @@ on: branches: - develop - v3 + - '4.3' pull_request: permissions: contents: read diff --git a/CHANGELOG.md b/CHANGELOG.md index 60f0c25b6a..dd6b2bd460 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,21 +1,39 @@ # Release Notes for Craft Commerce -## Unreleased - -- Variant min and max quantity fields now validate together logically. ([#3234](https://github.com/craftcms/commerce/issues/3234)) -- Added the “Product Type” product condition rule. ([#3209](https://github.com/craftcms/commerce/issues/3209)) -- Fixed a bug where `hasMatchingAddresses()` was incorrectly returning `false`. ([#3183](https://github.com/craftcms/commerce/issues/3183)) -- Fixed a bug where changing a user’s email would cause extra user elements to be created. ([#3138](https://github.com/craftcms/commerce/issues/3138)) -- Fixed a bug where related sales were showing when creating a new product. +## 4.3.0 - Unreleased + +- Sales and discounts now support using related entries in their matching item conditions. ([#3134](https://github.com/craftcms/commerce/issues/3134), [#2717](https://github.com/craftcms/commerce/issues/2717)) +- It’s now possible to query products by shipping category and tax category. ([#3219](https://github.com/craftcms/commerce/issues/3219)) +- Guest customers registering during checkout now have their addresses saved to their account. ([#3203](https://github.com/craftcms/commerce/pull/3203)) +- Product conditions can now have “Product Type”, “Variant SKU”, “Variant Has Unlimited Stock”, “Variant Price”, and “Variant Stock” rules. ([#3209](https://github.com/craftcms/commerce/issues/3209)) +- Improved the performance of discount recalculation. +- Improved the performance of the `commerce/upgrade` command. ([#3208](https://github.com/craftcms/commerce/pull/3208)) +- Added the `commerce/cart/forget-cart` action. ([#3206](https://github.com/craftcms/commerce/issues/3206)) +- The `commerce/cart/update-cart` action now accepts `firstName` and `lastName` address parameters. ([#3015](https://github.com/craftcms/commerce/issues/3015)) +- Added `craft\commerce\controllers\OrdersController::EVENT_MODIFY_PURCHASABLES_TABLE_QUERY`. ([#3198](https://github.com/craftcms/commerce/pull/3198)) +- Added `craft\commerce\elements\Order::$orderCompletedEmail`. ([#3138](https://github.com/craftcms/commerce/issues/3138)) +- Added `craft\commerce\elements\db\ProductQuery::$shippingCategoryId`. +- Added `craft\commerce\elements\db\ProductQuery::$taxCategoryId`. +- Added `craft\commerce\elements\db\ProductQuery::shippingCategory()`. +- Added `craft\commerce\elements\db\ProductQuery::shippingCategoryId()`. +- Added `craft\commerce\elements\db\ProductQuery::taxCategory()`. +- Added `craft\commerce\elements\db\ProductQuery::taxCategoryId()`. +- Added `craft\commerce\models\Discount::hasBillingAddressCondition()`. +- Added `craft\commerce\models\Discount::hasCustomerCondition()`. +- Added `craft\commerce\models\Discount::hasOrderCondition()`. +- Added `craft\commerce\models\Discount::hasShippingAddressCondition()`. +- Deprecated payment source creation via the `commerce/subscriptions/subscribe` action. +- Deprecated `craft\commerce\elements\Order::setEmail()`. `Order::setCustomer()` should be used instead. +- Removed the `htmx` option from the`commerce/example-templates` command. +- Removed the `color` option from the`commerce/example-templates` command. +- Added `craft\commerce\events\ModifyPurchasablesTableQueryEvent`. ([#3198](https://github.com/craftcms/commerce/pull/3198)) +- Fixed a bug where products/variants could be saved with a minimum quantity that was set higher than the maximum quantity. ([#3234](https://github.com/craftcms/commerce/issues/3234)) +- Fixed a bug where `craft\commerce\elements\Order::hasMatchingAddresses()` could incorrectly return `false`. ([#3183](https://github.com/craftcms/commerce/issues/3183)) +- Fixed a bug where changing a user’s email could cause additional user elements to be created. ([#3138](https://github.com/craftcms/commerce/issues/3138)) +- Fixed a bug where related sales were displaying when creating a new product. - Fixed a bug where Commerce wasn’t invoking `craft\services\Elements::EVENT_AUTHORIZE_*` event handlers. - Fixed a bug where discounts’ per user usage counters weren’t getting migrated properly when upgrading to Commerce 4. -- Fixed a bug where address changes weren’t being synced to carts using them as a source. ([#3178](https://github.com/craftcms/commerce/issues/3178)) -- Added `craft\commerce\services\Orders::afterSaveAddressHandler()`. -- Added `craft\commerce\elements\Order::$orderCompletedEmail`. ([#3138](https://github.com/craftcms/commerce/issues/3138)) -- Added the `commerce/cart/forget-cart` action. ([#3206](https://github.com/craftcms/commerce/issues/3206)) -- The `commerce/cart/update` action now accepts `firstName` and `lastName` in address params. ([#3015](https://github.com/craftcms/commerce/issues/3015)) -- Removed the htmx option from the`commerce/example-templates` command. -- Removed the color option from the`commerce/example-templates` command. +- Fixed a bug where address changes weren’t being synced to carts that were using them. ([#3178](https://github.com/craftcms/commerce/issues/3178)) - Fixed an XSS vulnerability. ## 4.2.11 - 2023-06-05 diff --git a/example-templates/dist/shop/_private/address/list.twig b/example-templates/dist/shop/_private/address/list.twig index e2c2e439e3..f73974af96 100644 --- a/example-templates/dist/shop/_private/address/list.twig +++ b/example-templates/dist/shop/_private/address/list.twig @@ -2,84 +2,74 @@ {% set selectable = selectable ?? false %} {% set primaryBillingAddressId = primaryBillingAddressId ?? null %} {% set primaryShippingAddressId = primaryShippingAddressId ?? null %} -{% set cardWidth = cardWidth ?? 'md:w-1/2' %} {% set showDelete = showDelete ?? false %} {% set showAdd = showAdd ?? false %} {% set addUrl = '/shop/customer/addresses/edit?redirect=' ~ craft.app.request.fullPath %} {% if currentUser %} - {% if addresses|length %} -