Commit Graph

35914 Commits

Author SHA1 Message Date
Nestor Soriano 07b62dabbd Improve the query to retrieve "Any..."-attributed variations in filtering widget
The new query doesn't need empty attribute entries in the meta table,
therefore the code that generates them and the migration to backfill
the missing existing ones have been removed.
2020-09-01 16:47:41 +02:00
Nestor Soriano 53351fcc2f Update wc_product_attribute_uasort_comparison to accept null entries
When set_attributes is used on WC_Product to remove existing attributes
the wc_product_attribute_uasort_comparison ends up being called
with a null argument, and this breaks tests in PHP 7.4 since
null is used as an array. This commit modifies the function so that
if null is passed no array access is attempted.
2020-08-31 16:49:29 +02:00
Nestor Soriano 3a583feab1 Change filter by attributes widget to count products, not variations.
Right now the filter by attributes widget counts available variations
(for variation products). This is confusing since the counter shows
numbers that are higher than the actual count of products displayed.

This commit changes the query used by the widget so that instead
of counting variations it returns the parent product ids, and then
counts the distinct values. This also covers the case of products
where some of the variations have concrete values and some have
"Any..." values.
2020-08-31 12:22:33 +02:00
Nestor Soriano 602f58a7a9 Add data migration to backfill missing attributes meta for variations.
The previous commit fixes a bug that causes the "attribute_" metadata
with an empty value to not be created when a new variation attribute
is added to the product (so that all variations have the attribute
with a value of "Any..."). This commit adds a data migration to
backfill the missing metadata for existing variations.
2020-08-28 09:38:16 +02:00
Nestor Soriano 1113201f8b Update meta 'attribute_' values when variation attributes are added or removed.
When a new variation attribute is added, the corresponding 'attribute_'
meta entries are added for all variations with an empty value;
and when an existing variation attribute is removed, the existing
'attribute_' meta entries are deleted for all variations.

This is necessary for the filter by attribute widget to work properly
when variations exist with a value of "Any..." for attributes.
2020-08-27 16:10:41 +02:00
Nestor Soriano a75da34a45 Fix filter by attribute widget now working for "Any..." attributes
When a variation product has an attribute with a value of "Any...",
and there's a filter by attribute widget for that attribute, then
that product won't be included in the counts displayed in the widget
(and if the count ends up being zero, the attribute won't be shown
in the widget).

This happens before since Woo 4.4, this widget works by looking at
entries in the term relationships table for varitions too
(used to do so for simple products and for "main" variable products
only), see PR #26260; but there are no such entries for
"Any..." attributes.

This commit fixes that by extending the SQL query used by the widget
to look for variations that have empty attribute values in the meta
table too.
2020-08-27 10:59:15 +02:00
jonathansadowski c537a3f632
Merge pull request #27484 from woocommerce/fix/paypal-unit-tests
Fix paypal unit tests
2020-08-25 15:41:28 -05:00
Claudio Sanches 2b6d9a1074
Merge pull request #27485 from woocommerce/update/gh-workflows
woocommerce/action-build@v2 always build a zip file
2020-08-25 16:30:44 -03:00
Claudio Sanches ae3a444721 Merge branch 'fix/paypal-unit-tests' of github.com:woocommerce/woocommerce into fix/paypal-unit-tests 2020-08-25 16:15:03 -03:00
Claudio Sanches a133e56ebd Fixed unit tests 2020-08-25 16:13:49 -03:00
Ron Rennick e11ec4729e Include method title in name change 2020-08-25 16:13:28 -03:00
Ron Rennick 81dae70033 phpcs fixes 2020-08-25 15:41:31 -03:00
Ron Rennick de79f1a3cd update unit tests for included Paypal gate name change 2020-08-25 15:36:50 -03:00
Claudio Sanches 079572ae50 woocommerce/action-build@v2 always build a zip file 2020-08-25 15:07:15 -03:00
Claudio Sanches 889250b4f7
Merge pull request #27482 from woocommerce/update/wc-4.5-rc.1-version
Update version in woocommerce.php for 4.5.0 RC1
2020-08-25 14:21:03 -03:00
Jonathan Sadowski 9211844ace Update version in woocommerce.php for 4.5.0 RC1 2020-08-25 12:19:41 -05:00
Claudio Sanches 77fe18e0a0
Merge pull request #27481 from woocommerce/update/action-build-v2
Updated woocommerce/action-build to v2
2020-08-25 14:01:02 -03:00
jonathansadowski 22eccf4da1
Merge pull request #27480 from woocommerce/update/wc-4.5-rc.1-changelog
Update changelog and readme.txt for 4.5.1 RC.1
2020-08-25 11:49:44 -05:00
Claudio Sanches 59fbab9a42 Updated woocommerce/action-build in nightly builds 2020-08-25 13:42:07 -03:00
Claudio Sanches 4e15abbf53 Updated woocommerce/action-build to v2 2020-08-25 13:41:24 -03:00
Jonathan Sadowski d6d5042ae1 Update changelog and readme.txt for 4.5.1 RC.1 2020-08-25 11:40:38 -05:00
jonathansadowski 209ea6a8bb
Merge pull request #27448 from haydenw/fix-27436
Fix #27436
2020-08-25 09:18:07 -05:00
jonathansadowski 68d1641e5c
Merge pull request #27468 from woocommerce/fix/27467
Rename built-in PayPal payment method to PayPal Standard
2020-08-25 08:42:11 -05:00
Ron Rennick 41a7caae05
Merge pull request #27449 from haydenw/fix-27413
Fix #27413
2020-08-25 10:29:45 -03:00
Ron Rennick bdb1451f2b
Merge pull request #27441 from Rahmon/patch-1
Ensure that the return of get_the_terms is not a WP error
2020-08-25 10:13:45 -03:00
Néstor Soriano 4d7741c329
Merge pull request #27465 from woocommerce/revert-26885-fix/26780
Revert "Fixed HTML entities in product name not showing correctly in cart page"
2020-08-25 14:49:48 +02:00
Brent Shepherd a2e2d63265 Rename PayPal to PayPal Standard
In the admin area, not the front-end of the site.

Fixes #27467
2020-08-25 12:25:44 +10:00
Claudio Sanches 3732736029
Merge pull request #27443 from danielmorell/master
Fixed $columns type in WC_Shortcode_Products->get_wrapper_classes() docblock
2020-08-24 22:22:44 -03:00
jonathansadowski 386e44688b
Merge pull request #27466 from woocommerce/bump-wc-admin-version-to-1.5.0-rc.2
Bump wc-admin to 1.5.0-rc.2
2020-08-24 18:50:28 -05:00
Rebecca Scott 97902b00cd Bump wc-admin to 1.5.0-rc.2 2020-08-25 08:49:50 +10:00
jonathansadowski 09176808c7
Revert "Fixed HTML entities in product name not showing correctly in cart pag…" 2020-08-24 14:44:20 -05:00
Néstor Soriano 99e9d977ba
Merge pull request #27438 from woocommerce/update/readme-screenshots 2020-08-24 12:02:33 +02:00
Hayden Whiteman 3fca3caf1d Fix #27413 2020-08-22 19:35:13 +12:00
Hayden Whiteman 201db0ca9e Fix #27436 2020-08-22 17:22:45 +12:00
Daniel Morell 252128026f
Fixed $columns type in docblock 2020-08-21 12:55:28 -05:00
Ramon 7610e1311e
Ensure that the return of get_the_terms is not a WP error 2020-08-21 14:07:26 -03:00
Tam Mullen 9b9ebc396a
Merge pull request #27440 from woocommerce/fix/e2e-obw-remove-composite-products
Updating e2e tests for OBW changes
2020-08-21 17:42:40 +01:00
Tam Mullen b41bd5139d Updating e2e test for OBW changes 2020-08-21 16:03:02 +01:00
Gerhard 67806f3ddb Tweak site broke copy 2020-08-21 10:55:27 +02:00
Gerhard f70f4f51a0 Remove extra blank lines 2020-08-21 10:37:08 +02:00
Gerhard 1df3d1e22a Update readme description section 2020-08-21 10:26:50 +02:00
Gerhard 3a65700f73 Update wp.org listing screenshots 2020-08-21 09:36:25 +02:00
Néstor Soriano a81aa50c03
Merge pull request #27426 from woocommerce/fix/27381
Updated priority of admin_body_class filter
2020-08-21 09:15:00 +02:00
jonathansadowski e8884c85db
Merge pull request #27431 from woocommerce/update/readme-contributors
Update contributors in readme to add sadowski
2020-08-20 13:25:11 -05:00
Jonathan Sadowski b48a29d911 Update contributors in readme to add sadowski 2020-08-20 13:23:49 -05:00
Claudio Sanches d8d608da47
Merge pull request #27430 from woocommerce/update/package-json-4-5-release
Update the package-lock.json from running npm install during 4.5 beta release
2020-08-20 14:52:25 -03:00
Jonathan Sadowski 3a54daa73d Update the package-lock.json from running npm install during 4.5 beta release 2020-08-20 12:39:50 -05:00
jonathansadowski 7a1161495a
Merge pull request #27427 from woocommerce/update/release-changelog-and-version-numbers
Prepare 4.5 Beta 1 Release
2020-08-20 12:09:35 -05:00
Jonathan Sadowski f405863fe8 Add formatting to filter names in readme and changelog; Fix error with filter line in readme. 2020-08-20 11:59:27 -05:00
Jonathan Sadowski f8d2629e22 Update filter change to dev in readme and changelog 2020-08-20 11:53:50 -05:00