Commit Graph

174 Commits

Author SHA1 Message Date
Claudio Sanches 02cf0dfaed
Merge pull request #27239 from woocommerce/fix/package-tag
Fix usage of "package" tag in file headers
2020-08-07 13:37:24 -03:00
Claudio Sanches d48f1d4e2e Fixed package tag usage 2020-08-05 13:36:24 -03:00
Claudio Sanches f5e1b4fa54 Update only if the code got changed 2020-08-03 11:28:27 -03:00
Claudio Sanches 93febdca19 Fixed option name 2020-08-03 11:27:38 -03:00
Claudio Sanches aa0b45358a Fixed upgrade routine 2020-07-30 16:36:54 -03:00
Claudio Sanches c574ea3364 Updated queries and fixed version 2020-07-30 16:23:39 -03:00
Claudio Sanches 0b45369bff Improved migration script to avoid race condition 2020-07-30 16:17:23 -03:00
Claudio Sanches bb131ace69 Clean cache 2020-07-29 23:14:50 -03:00
Claudio Sanches 5b48191eac Batch update coupons 2020-07-29 23:07:00 -03:00
Claudio Sanches 119b5d6568
Merge branch 'master' into fix/23790 2020-07-28 13:07:17 -03:00
Néstor Soriano e9d692f455 Apply suggestions from code review
Mostly adding "since 4.4.0" annotations and updating
db update functions from 4.2 to 4.4.

Co-authored-by: Claudio Sanches <contato@claudiosanches.com>
2020-07-28 09:01:55 +02:00
Nestor Soriano 9c6c0d73d8 Record attribute terms for product variations in wp_term_relationships.
Product attributes are currently recorded as terms in
wp_term_relationships (product attributes are actually taxonomies).
In the case of variable products this is true for the main product,
but not for the variations. The attributes used to define variations
are stored as post meta, but nothing is recorded in the term
relationships table.

This is a problem when using the layered nav filtering plugin,
since the attribute counters displayed are calculated based solely
on the contents of the term relationships table. Adding meta queries
would be really messy (especially when the widget is configured
with AND operator) and would probably also hurt performance.

This commit adds a change to store the attributes for variations
as term relationships, additionally to storing them as post meta.
Terms are stored on variation creation, and updated/deleted together
with the variation as appropriate. "Any" variations (stored in meta
as empty values) are not stored as terms.

Additionally, a database upgrade is included in order to backfill
terms for already existing products.
2020-07-28 08:55:55 +02:00
Nestor Soriano 752b47513d Fix code sniffer errors in some files.
Fixed files:

includes/data-stores/class-wc-product-variable-data-store-cpt.php
includes/wc-update-functions.php
2020-07-28 08:55:55 +02:00
Claudio Sanches be106af910 Added upgrade routine to sanitize all coupon codes 2020-07-27 16:50:23 -03:00
Rodrigo Primo cd75870267 Add the wc_update_400_ prefix to db update routine
The db update routine that resets action scheduler migration status was
missing the wc_update_400_ prefix. Doing this for the sake of
consistency.
2020-03-10 09:27:30 -03:00
Peter Fabian 7fdee5b03e
Merge pull request #25707 from woocommerce/fix/as-460
Mark AS migration pending when updating WC to ensure migration happens.
2020-02-25 22:03:45 +01:00
vedanshujain 6f53f42da6 Add checks to prevent if AS loaded is different version than we expect. 2020-02-21 16:35:37 +05:30
vedanshujain 90ab985cfb Mark AS migration pending when updating WC to ensure migration happens.
Ideally https://github.com/woocommerce/action-scheduler/pull/470 should take care of this issue, but since we have AS 3.x in the wild without fix in the PR, this change is also necessary.
2020-02-19 18:19:11 +05:30
Claudio Sanches fd488e5d2c Apply woocommerce_maxmind_geolocation_database_path filter in maxmind migration 2020-02-16 18:47:03 -03:00
Rohan V e2cb1dea73
Fix codestyle 2020-02-04 19:44:05 +05:30
Rohan Vakharia 4be33acd66
Merge branch 'master' into master 2020-02-04 19:23:22 +05:30
Peter Fabian 7a24aaecd5 Updated versions to 4.0. 2020-02-03 23:36:52 +01:00
Rohan V 0d9462d110
Fix for existing column 2020-02-03 19:50:37 +05:30
Mike Jolley 2638879bdc Add columns to schema and update routine 2020-01-20 14:21:42 +00:00
Christopher Allford e56e5dfc50 Pushed the first woocommerce_geoip_updater execution to fifteen days in the future
This will prevent the routine from deleting the pre-update archive that we just moved in the previous update routine.
2020-01-15 10:25:51 -08:00
Christopher Allford 2b503e0409 Changed the MaxMind database update process to move the existing archive instead of deleting it 2020-01-15 10:24:13 -08:00
Christopher Allford c34a5b6ffe Added an update task to increase the database version 2020-01-14 13:39:47 -08:00
Christopher Allford e851160927 Removed the erroneous space on the woocommerce_geoip_updater scheduled event 2020-01-14 13:20:41 -08:00
Christopher Allford b577b8a386 Changed the geoip update cron to run every 15 days to better comply with MaxMind's TOS 2020-01-13 17:02:41 -08:00
Christopher Allford ef0eccf0ac Added upgrade step for removing the legacy MaxMind database 2020-01-13 11:18:14 -08:00
Rohan V 83c88e47a5
Add fix to increase column size for existing installations 2019-12-18 13:24:18 +05:30
Peter Fabian 309c48ab0e Deprecated old cache function and replaced it with a new one. 2019-11-28 14:03:57 +01:00
Gerhard e586379c3c Delete woocommerce_tax_classes option after transfering it to the new tax class table. 2019-07-22 14:16:17 +02:00
Claudio Sanches db06d3dbae Merge branch 'master' into update/22164-tax-rate-class-table 2019-07-08 18:12:23 -03:00
MD0123-Hardip 60cafccb37 added new line in update-function.php file 2019-06-25 15:20:26 +05:30
MD0123-Hardip 530d53c428 added new 370 function for currency updater. 2019-06-25 15:17:16 +05:30
MD0123-Hardip a01d59e581 added db currency updater for both currency 2019-06-20 16:17:23 +05:30
Mike Jolley f113d26e44 Update routine 2019-03-20 15:27:43 +00:00
Mike Jolley 20d7603dd6 Merge branch 'fix/21034' 2019-03-12 13:47:08 +00:00
Mike Jolley a3c2dcd8f2 Update from master 2019-03-08 09:50:56 +00:00
Mike Jolley 16a0a3e27e Update from master 2019-03-05 19:03:01 +00:00
Mike Jolley abc3b6ca47 Use cache helper for invalidation 2019-03-05 16:16:46 +00:00
Gerhard Potgieter 5a6cc36fce
Merge branch 'master' into experiment/product-sorting-index 2019-03-05 14:04:11 +02:00
Mike Jolley 32417e1017 Unused result vars 2019-03-01 10:28:30 +00:00
Gerhard 36f0041673 PHPCS fixes 2019-02-28 15:37:37 +02:00
Gerhard b8a5a9ec55 Add update routine to add user_order_remaining_expires index and hook it up to the installer for 3.6.0 2019-02-28 15:36:55 +02:00
Mike Jolley ac51d1f1df Update routines 2019-02-12 13:27:30 +00:00
Mike Jolley 9fc78634f9 Update routine 2019-01-25 13:56:15 +00:00
Mike Jolley 6367d19615 phpcs 2019-01-21 08:11:40 -08:00
JeroenSormani f4775ccd90 Use shipping method instead of property through magic + doc return statements 2019-01-04 12:41:38 +00:00