Commit Graph

223 Commits

Author SHA1 Message Date
roykho 05917f0d6d
Prep versions for trunk 2021-08-19 13:38:14 -07:00
Roy Ho 95abba7eeb
Merge pull request #30041 from woocommerce/add/29609
Sync the product attributes lookup table on product creation/change/deletion
2021-07-16 15:03:54 +01:00
vedanshujain 93fe370966 Update version to prep for 5.6 2021-06-22 12:28:20 +05:30
Nestor Soriano 0192ed0b93
Change LookupDataStore to allow updates being done in a scheduled action.
There's a new option, 'woocommerce_attribute_lookup__direct_updates'.
When set to 'yes', updates to the lookup table are performed as soon
as the change happen; otherwise, a scheduled action will do it,
the hook name is 'woocommerce_run_product_attribute_lookup_update_callback'
(the existing hook in the DataRegenerator class is renamed to
'woocommerce_run_product_attribute_lookup_update_callback')

Also, the settings page has a new "Advanced" section with a checkbox
to control the value of that new option; the section is visible only
when the feature has been enabled via LookupDataStore::show_feature.
2021-06-15 16:33:29 +02:00
Vedanshu Jain 6667233eb1
Merge pull request #29762 from woocommerce/fix/29502
Update restock logic during refunds closes #29502
2021-05-21 22:53:22 +05:30
Roy Ho 0643ccf4c6
Merge branch 'trunk' into add/woocommerce_inbox_variant 2021-05-19 10:36:21 -07:00
Christopher Allford 0b89a27abd Updated versions for 5.5.0 development 2021-05-14 15:03:39 -07:00
Christopher Allford dcec089e7e Merge branch 'trunk' into wc-admin-nonce 2021-05-13 14:11:32 -07:00
Paul Sealock 08d71b5a0c make assignment 1-12 2021-05-13 17:58:09 +12:00
Paul Sealock cc244ce103 remove activation hook as its redundant 2021-05-13 12:59:19 +12:00
Paul Sealock 1314e7e142 Add woocommerce_inbox_variant: 2021-05-13 12:55:58 +12:00
roykho b808d9a24f
Fix merge conflicts 2021-05-11 08:53:03 -07:00
roykho 8c3e90b3ce
Initialize _restock_refunded_items meta on order update 2021-05-11 08:35:48 -07:00
roykho ccef7c46a3
Restore testing version 2021-04-29 07:25:26 -07:00
roykho 87047c77df
Limit the new refund restock logic to order version 5.4+ 2021-04-29 06:30:53 -07:00
Nestor Soriano d1744ac99a
Add the ProductAttributesLookup\DataRegenerator class.
This class creates and fills the product attributes lookup table
from the existing products. It does so by in small chunks by using
Action Scheduler; it handles all the batches and the scheduling
by itself.

It also adds two entries to the debug tools menu:

- Initiate lookup table regeneration (deleting the existing table first)
- Enable or disable the actual usage of the lookup table
  for product filtering

The first one is the only way to generate the lookup table for now
(there's no explicit data migration).

The actual filling of the table is delegated to a LookupDataStore class
that is not implemented yet, so for now the table isn't actually filled.
Also enabling/disabling the lookup table usage has no real effect yet.
2021-04-28 10:30:11 +02:00
roykho c73ce8ea04
Convert to using internal DI container 2021-04-16 12:23:40 -07:00
roykho e1c6c540d7
Convert notices to use native nonce generation from WC Admin 2021-04-09 05:33:06 -07:00
Nestor Soriano a5e4bad042 Update the WooCommerce version in (class-)woocommerce.php to 5.3 2021-03-19 11:08:37 +01:00
roykho cf634987b4
Prepare default branch 2021-03-09 06:11:41 -08:00
Peter Fabian 8566a79da0 Pull out the constant to a globally accessible place so that it can be reused. 2021-02-24 14:29:45 +01:00
Claudio Sanches ee28da5d30 Prepare default branch for 5.1 2021-01-25 16:38:22 -03:00
roykho 21f872e766
Fix merge conflict 2021-01-20 07:10:47 -08:00
roykho 52a2ce0300
Move nonce prepartion into core utilizing filter hook from WC Admin 2021-01-20 07:06:23 -08:00
Claudio Sanches ea54d5ad5f
Merge pull request #28679 from woocommerce/fix/woocommerce-gutenberg-products-block-issues-3565
Show correct WooCommerce pages status if they are using blocks vs shortcode.
2021-01-18 19:26:34 -03:00
Roy Ho 4c548951f4
Merge pull request #28521 from woocommerce/fix/26475
Create additional download permissions on product save if needed
2021-01-18 06:51:57 -08:00
Nestor Soriano 8b0bd248d6 Attach hook for adjust_download_permissions from within init_hooks
The DownloadPermissionsAdjuster class hooks to adjust_download_permissions
from within its init method. However this method is executed only
if the class is resolved, otherwise the hooks doesn't get attached
and then the scheduled action is not serviced.

To solve this, the class is resolved from WooCommerce::init_hooks.
This requires a change in DownloadPermissionsAdjuster::init
to use wc_get_container()->get( LegacyProxy::class )->get_instance_of
instead of WC()->get_instance_of, since WC() can't be used from
WooCommerce::construct (which invokes init_hooks).
2021-01-14 11:40:11 +01:00
Ilyas Foo 0e5596d1fc Transient and action passes plugin filename 2021-01-13 09:52:17 +08:00
Nestor Soriano 10eb9f832e Remove one of the duplicate handlers for 'adjust_download_permissions' 2021-01-12 10:15:53 +01:00
budzanowski 29837c42ff Refactor. 2021-01-06 11:33:28 +01:00
Ilyas Foo 0e590d1bdb Add transient and action for proxying WC plugin activation hook 2020-12-31 14:30:29 +08:00
vedanshujain 44705386a4 Prep master for 5.0.0. 2020-12-22 19:01:56 +05:30
Nestor Soriano f0b834d1ec Move the download permissions adjustment process to a scheduled action.
Also, move all the new code from the 'WC_Product_Data_Store_CPT' class
to a new separate 'DownloadPermissionsAdjuster' class.
2020-12-10 15:40:38 +01:00
Roy Ho 018dbc251d
Merge pull request #28386 from abhishek-pokhriyal/remove/bc-check-determine-locale
Remove function_exists check for determine_locale
2020-12-08 13:15:22 -08:00
Christopher Allford 686872a237
Merge pull request #28134 from woocommerce/add/2021-compat
Add support for Twenty Twenty-One theme
2020-11-24 16:26:34 -08:00
abhishek-pokhriyal 9abbd42d69 Remove function_exists check for determine_locale 2020-11-24 15:37:13 +05:30
Christopher Allford bb38673dad Prepared branch for 4.9 2020-11-13 09:38:22 -08:00
Jeffrey Pearce bf8662bf67 Adds structure for Twenty Twenty One default theme support. Issue #27766
- New class class-wc-twenty-twenty-one.php
- New stylesheet twenty-twenty-one.scss
- Updates checks for default themes in theme_support_includes() and wc_is_wp_default_theme_active()
2020-11-16 06:41:39 -06:00
Claudio Sanches f7ecbbeb35 Prepare default branch to 4.8 2020-10-20 15:20:52 -03:00
Nestor Soriano b71f876cba Reintroduce the dependency injection related code.
After the League's Container package has been reintroduced, all the
code that implements the dependency injection mechanism in woocommerce
can be brought back as well.
2020-10-08 09:28:05 +02:00
Rodrigo Primo 6a641c4b1d Bump WC version to 4.7.0 2020-09-19 15:24:12 -03:00
Rodrigo Primo fd25815a7c Prepare master for 4.6.0 development 2020-09-11 14:07:58 -03:00
Jonathan Sadowski 9da304e983 Update version in class-woocommerce.php 2020-09-09 10:35:05 -05:00
Nestor Soriano c37771521a Remove call_function, call_static, get_instance_of from class-woocommerce.php 2020-08-19 12:08:54 +02:00
Christopher Allford 82df4b3303 Removed the contents of the WC() global container helpers 2020-08-18 20:45:34 -07:00
Claudio Sanches def2ef499c Master is 4.5.0 now 2020-08-07 12:55:51 -03:00
vedanshujain 1d782f025e Deprecate API Package class because its not a package anymore. 2020-08-06 14:34:02 +05:30
vedanshujain 16473d54e9 Fixes for correct time of loading API 2020-08-06 14:34:02 +05:30
vedanshujain 4a4767ae93 Load API files. 2020-08-06 14:34:02 +05:30
Néstor Soriano 0f134ca6a2
Merge pull request #27054 from woocommerce/fix/27036
add/update correct deprecated notices on existing deprecations
2020-07-29 15:20:24 +02:00