Commit Graph

8903 Commits

Author SHA1 Message Date
Fernando Marichal ff0430d847
Fix recording events without props (#34595)
* Fix tracking events without props

* Add changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-09-06 16:37:31 -03:00
Maikel David Pérez Gómez e2afc5c13d
Validate that tinymce exists before using it. (#34551)
* Validate that tinymce exists before using it.
If wp is not configured to use blocks and the tinymce was changed by a different editor then the error happends because tinymce is required. Applaying a validation that makes sure tinymce exists before using it solves the problem. But this introduces a new problem, the description property will be send with value 'No' when event 'product_update' will be fired.

* Add changelog file

* Check if tinymce.get( 'content' ) is not falsy before calling getContent()
2022-09-06 15:37:18 -03:00
Matt Sherman c87d3c68cb
Products pricing section code cleanup (#34560)
* Switch to formatAmount from formatCurrency

* Rename priceValidation to sanitizeAndSetPrice

* Swap order of name, value args in sanitizeAndSetPrice
2022-09-06 10:48:50 -04:00
Tomek Wytrębowicz a86e387667
Update/unify jest@27 across all packages (#34322)
* Update `jest-puppeteer@5.0.4` (from `4.4.0`)

to be albe to run with jest 28.

* Update `jest` and `ts-jest@^27` (from `25`),

to match `e2e-environment` needs.

* Update api-core-tests' `jest@^27` (from `25`),

to unify the used version across the stack.

* Update e2e-env's `jest@^27` & co.  (from `25`),

to unify the used version across the stack.

* Update e2e-env's `@jest/test-sequencer@^27`  (from `25`),

to unify the used version across the stack.

* Update admin-e2e-tests' `@jest/globals@^27`  (from `26`),

to unify the used version across the stack.

* Update woocommerce's `jest@^27.5.1`  (from `25`),

to unify the used version across the stack.

* Replace `mocked` from `ts-jest` to the one from `jest`,

Update `@types/jest@27.4.1` from `27.0.2`.
Try to fix broken tsc build.

* Update `e2e-core-tests`' `@jest/globals@^27.5.1`

from `^26.4.2`.

* Remove changelog entry for bumpin jest in `api-core-tests`

It was already covered in `trunk`.

Addresses https://github.com/woocommerce/woocommerce/pull/34322#discussion_r956019567

* Updated package-lock.yaml

* Updated timeout

* Added changelogs

Co-authored-by: jamelreid <jnoelreid@gmail.com>
2022-09-06 09:29:45 -05:00
Damon Cook 8b1a105f39
Fix Button block markup for Onboarding homepage (#33966)
* Fix Button block markup for Onboarding homepage

* Add changelog entry

Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2022-09-06 15:27:59 +05:30
Christopher Allford 6457348a97
Validate React Admin Changelog Files (#34520)
This maps the changelog command of the React Admin in order to ensure that they're validated and able to be added.
2022-09-05 13:02:00 -07:00
github-actions[bot] 59ee9418e7
Delete changelog files based on PR 34543 (#34577)
Delete changelog files for 34543

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-09-04 16:45:15 -07:00
github-actions[bot] 06da4144d0
Delete changelog files based on PR 34443 (#34575)
Delete changelog files for 34443

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-09-04 16:43:24 -07:00
github-actions[bot] c0e1b1abb4
Delete changelog files based on PR 34495 (#34573)
Delete changelog files for 34495

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-09-04 16:40:38 -07:00
github-actions[bot] 9345d34164
Delete changelog files based on PR 34455 (#34571)
Delete changelog files for 34455

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-09-04 16:37:35 -07:00
Tom Cafferkey e478f1a286
Bump WooCommerce Blocks to 8.3.2 (#34543) 2022-09-04 16:32:52 -07:00
Brian b82638c131
Liechtenstein Checkout: Hide Municipality Field with empty states array (#34189)
empty states array for liechtenstein
2022-09-02 13:20:28 +02:00
berislav grgičak ca91250b2e
Add WooCommerce header to WooCommerce.com requests (#33927)
* Add WooCommerce header to WooCommerce.com requests

* Remove duplicate user-agent

* Add header to suggestions request

* Add missing comma
2022-09-02 11:12:52 +02:00
Fernando Marichal 30151a6cf7
Add `recordEvent` validation to Tracks package (#34005)
* Add `recordEvent` validation

# Conflicts:
#	packages/js/tracks/package.json

* Convert tests to ts

* fix error message

* Add console.error message

* Fix `validateEventNameAndProperties`

* Add changelog

* Add validation method

* Fix tests

* Fix package

* Move changelog

* Add changelog

* Fix type

* Move env definition

* Fix tests

* Fix condition

* Fix regex and tests

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-09-01 13:34:42 -03:00
Peter Fabian 834d4945ad
Update Guernsey state field to non-required (#34500)
* Update Guernsey state field to non-required

Resolves woocommerce#32876 by making GG state field entry non-required.

* Update Guernsey state field with correct label

Based on https://en.wikipedia.org/wiki/Guernsey#:~:text=Guernsey%20(%2Fˈ%C9%A1ɜ%CB%90rn,Guernsey%2C%20a%20British%20Crown%20Dependency.&text=It%20is%20the%20second%20largest,west%20of%20the%20Cotentin%20Peninsula it looks like the state equivalent for GG is to "Parish" so rather than hiding the field entirely, it makes more sense to make it optional, and add the correct label.

* Added changelog.

Co-authored-by: Rynaldo <89896100+rynaldos@users.noreply.github.com>
2022-09-01 18:19:43 +02:00
Moon b4b7b4c329
Update/34540 add walmart and wish to store list (#34541)
* Add Wish and Walmart to the platform options

* Add changelog
2022-09-01 09:11:42 -07:00
Matt Sherman cf37a5dcfb
Use label prop on sale price input instead of separate label element (#34532)
Use label prop on sale price input instead of separate label element.
2022-09-01 11:09:22 -04:00
Vedanshu Jain 345f250a58
Add util methods to get order edit and create URLs (#34499) 2022-09-01 15:58:07 +02:00
Ilyas Foo 5af66c4b1e
Remove set up store details note (#34515)
* Remove CompleteStoreDetails note

* Changelog
2022-09-01 09:53:51 +08:00
Dharmesh Patel 9e9b4ef844
[COT] Fix error during apply coupon when COT enabled. (#34498)
* implement coupon held methods.

* Add changelog file.

* Used `delete_meta_data` of WC_Coupon and cleared meta cache after  adding coupon held meta.

Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2022-08-31 15:21:22 +05:30
Chi-Hsuan Huang e687a48abf
Update dependencies and jest config to pass admin tests for pnpm 7 (#34428)
* Update @wordpress/data version to ^6.15.0

* Update jest.config.js to transform is-plain-obj js

* Update pnpm-lock.yaml

* Add changelog

* Add babel configs and update jest config

* Update tsconfig.json to exclude babel.config.js

* Add missing @types packages

* Add changelog

* Update pnpm-lock.yaml

* Update pnpm-lock.yaml

* Fix DateTimePickerControl type errors
2022-08-31 12:06:51 +08:00
Moon 2a455d1bdc
Add missing styles for the progress header (#34521)
* Add styles for the progress header

* Add changelog

* Fix invalid header error from the changelog -- this file is not related to this repo, but I am still fixing it since it is not passing the gitflow job
2022-08-30 20:35:39 -07:00
Daniyal Ahmed dc10473fe8
No states for Saint Martin - French Part (#34014) 2022-08-30 15:48:00 +02:00
Fernando 33405283cd
Add Pricing section (#34382)
* Add pricing inputs

# Conflicts:
#	plugins/woocommerce-admin/client/products/add-product-page.tsx
#	plugins/woocommerce-admin/client/products/layout/product-section-layout.scss
#	plugins/woocommerce-admin/client/products/sections/product-details-section.tsx

* Add pricing inputs

* Add validation

* Fix scss

* Moved validations

* Add tests

* Add regex validations

* Add tax settings

* Fix comment

* Add product name validation

* Fix validation copy

* Rename `woocommerce-add` classes

* Fix texts i18n

* Remove image section

* Fix decimal separator error

* Add `FormSection` component

* Fix `Enriched-label` component

* Add packages changelog

* Removed not used styles

* Add error handling

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-08-30 10:26:24 -03:00
Peter Fabian 5af8f8cbdc
Tests for foreign key removal (#34416) 2022-08-30 12:50:13 +02:00
Albert Juhé Lluveras 05b171d4aa
Enable WC Customizer panels in customize.php routes also for block themes (#34443) 2022-08-30 12:47:10 +02:00
Jorge A. Torres 45563f0c11
[COT] Initialize order date props during `read()` as GMT (#34474)
* Load order date props as timestamps in COT
2022-08-30 12:30:03 +02:00
Chi-Hsuan Huang f813153ac5
Fix country field is empty when navigating back to the store details tab (#34484)
* Add is_store_country_set to onboarding profile items

* Fix country field is empty when navigating back to store details tab

* Add changelog
2022-08-30 09:43:59 +08:00
Chi-Hsuan Huang 9d23439136
Refactor inbox notes to have get_note method (#34357)
* Refactor NewSalesRecord to have get_note method

* Refactor OrderMilestones to have get_note method

* Add unit tests for notes

* Fix wrong content data return type

* Add changelog
2022-08-30 09:43:27 +08:00
Chi-Hsuan Huang 72d8c791e6
Migrate @woocommerce/data notes store to TS (#34220)
* Migrate wc.data.notes to TS

* Add missing field "is_read" to notes item schema

* Add changelog

* Fix test_get_notes_schema test
2022-08-30 09:42:32 +08:00
Néstor Soriano 427b3fbdc2
Make Yoda conditions mandatory again (#34335)
* Make Yoda conditions mandatory again

* Add changelog file
2022-08-29 11:55:23 +02:00
Chi-Hsuan Huang 08344736db
Fix "1 of 2 steps" is shown for the first step in a 3 step tour (#34413)
* Fix "1 of 2 steps" is shown for the first step in a 3 step tour

* Add changelog

* Rename prop

* Update shipping tour
2022-08-29 17:25:24 +08:00
Ilyas Foo c7015da14e
Update product task experiment names to re-run (#34495)
* Update product task experiment names to re-run experiment

* Add spotlight parameter experimental product task menu

* Changelog

* Fix yoda
2022-08-29 14:19:59 +08:00
Christopher Allford ad8f1de6d1
Fix "Orders" Plurality (#34491) 2022-08-26 14:34:40 -07:00
Gan Eng Chin 945a55adbc
Update Google logo icon (#34471)
* Update Google logo icon.

* Update Google logo icon to use img element with svg file.

* Simplify ProductIcon CSS with size prop.

This applies to svg and image icons, not just svg.

* Add changelog.

* Set style for Google logo icon.

We set white background to override the gray backgroun in ProductIcon.

Padding is used to make it look visually similar size with other icons.

* Update style for Google logo.
2022-08-26 19:24:19 +08:00
Rodrigue 0b772e31e3
Add back FB extension to Installed marketing extensions list. (#34259)
* Update FB icon component SVG to latest FB icon.
2022-08-26 19:36:44 +09:30
Chi-Hsuan Huang 51a794d743
Add `wp_version` prop to storeprofiler_store_business_details_continue track (#34439)
* Add wp_version prop to storeprofiler_store_business_details_continue_variant track

* Add changelog
2022-08-26 12:37:08 +08:00
Jamel Noel Reid ec3b10fe1f
Remove deprecation notice from e2e readmes (#34476)
* Remove deprecation notice

* Added changelog

* Update plugins/woocommerce/tests/e2e-pw/README.md

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>
2022-08-25 13:41:55 -06:00
Vedanshu Jain e8eb000733
Add inline file delivery to WC_Download_Handler (#31145)
Add inline file delivery to WC_Download_Handler

Create a new setting option for inline file delivery for downloadable
products. In the Download Handler create a new method for the new
setting as well as a method for returning the proper headers to deliver
files inline.

Resolves: #28410

* Update Content Type of inline delivered files

* Update Downloaded file name

* Change content-disposition to be a checkbox

Since inline-delivery works with multiple download methods

* Document  function

* Add new setting for test, see #31145.

* Better setting wording and remove typo comment.

* Address pr feedback.

* Add changelog.

* Rephrase the settings to make it more clear.

* More rephrasing.

Co-authored-by: Matthew Caldwell <caldwellysr@gmail.com>
2022-08-25 11:03:03 -07:00
Barry Hughes 91072c40e0
Order item meta/re-order fix (#34472)
Order-again item meta should store term slug instead of term value.

* Cleanup f26e62502c
* Remove extra tab
* Changelog.

Co-authored-by: Alexandre Froger <alex@froger.me>
2022-08-25 10:57:03 -07:00
Jorge A. Torres 2ce2b65959
[COT] Implement methods `get_order_count`, `get_unpaid_orders` and `get_order_id_by_order_key` in the COT datastore (#34324)
Implement `get_order_id_by_order_key()` and related methods in the COT datastore.

* Implement `get_order_count()` in the COT datastore

* Implement `get_unpaid_orders()` in the COT datastore

* Implement `get_orders()` in the COT datastore

* Add unit tests for misc. COT datastore methods

* Add changelog

* Apply suggestions from code review

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* Rename var

* Update docblock

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-08-25 08:51:27 -07:00
Rommel Castro 0654c4a7c6
make `wccom` commands text translatable, add application-password section URL (#34363)
* make text translatable, add application-password section url

* fix URL

* add missing `translators:` comments, fix wront params order
2022-08-25 09:27:36 -05:00
Barry Hughes 4dcff8ccf1
Trashed coupons should not be usable (unless restored). (#33791)
Trashed coupons should not be usable (unless restored).
2022-08-25 05:26:01 -07:00
Moon 83e191be31
Revert skip button changes on the OBW pages (#34455)
* Revert skip button changes

* Revert skip button changes -- e2e tests

* Remove unexpected whitespace

* Update test snapshot

* Return early

* Remove test
2022-08-24 19:33:31 -07:00
Vedanshu Jain b2c3ef8f29
Add support for refunds and other order types in custom order tables (#34050)
* Add suppport for types and refund in migrations.

* Add changelog.

* Make CI happy.

* Add support for refunds save and read.

* Remove placeholder from order types eligible for migration.

* Link backfilling to migration process.

* Add changelog.

* Reduce batch size for backfilling since it is slower.

* Correct grammer.

* Link backfilling with data synchronizer and adopt with pending migration on both sides.

We already have backfilling implemented, however it was not linked. This would make switching data stores back to posts table not possible. This commit links datasynchronizer so that it can both migrate as well as backfill.

* Remove _recorded_sales from skipped check keys since its implemented.

* Share concrete instance of cot controller to share feature value.

* Revert adding concrete controller, object instance is already shared.

* remove yoda condition.

* Remove unintended change.

* Add types in unit test since we added it in schema.

* Remove unsetting type, its supported now.

* Add support for backfilling order types with different datastores.

* Use correct datastore while migrating.

* Support -1 for limit queries

* Order factory to support reading multiple order types.

* Add read_multiple to refunds data store.

* Return negative total for consistency with posts table implementation.

In custom tables, we can directly sum the value for total_amount since they are being stored in flat tables, instead of relying on _refund_amount meta.

* Remove type definations for back compat.

* Add test for get_orders

* Use persist_udpates method for consistency and DRY.

* Resolve conflict correctly.

* Removed duplicated methods.

* Use correct order in doc comment.

* Fix typo

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>

* Rename parameter for better clarity.

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-08-24 14:33:03 -05:00
github-actions[bot] 9c56c77951
Delete changelog files based on PR 34359 (#34453)
Delete changelog files for 34359

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-08-24 12:06:15 -07:00
Tarun Vijwani a0ba266e75
Update WooCommerce blocks package to 8.3.1 (#34359) 2022-08-24 11:41:37 -07:00
susameca b8177b82e0
Fix Bulgarian States for Sofia (#34381)
Update subdivisions for Bulgaria.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-08-23 18:40:05 -07:00
Chi-Hsuan Huang 467b5dbfd2
Hide finish setup button when task list is disabled (#34410)
* Hide finish setup button when task list is disabled

* Add changelog

* Update plugins/woocommerce-admin/client/activity-panel/activity-panel.js

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2022-08-24 09:39:01 +08:00
Joel Thiessen 668244b2d7
Adding DateTimePicker component (#34293)
* Rudimentary functional version of datetimepicker

* Adding changelog

* Adding package changelog

* Making component more than barely functional

* Removing unnecessary export

* Rename directory to date-time-picker

* Add initial story

* Pass datetime to onChange callback

* Localize error string

* Remove initial error prop

* Rename currentDate to initialDate

* Simplify state for selected date

* Add extra stories around component

* Trigger onChange whenever date is changed

* Add readme

* Allow currentDate to be changed via props

* Update readme

* Update name to DateTimePickerControl

Co-authored-by: Joshua Flowers <joshuatf@gmail.com>
2022-08-23 15:19:46 -07:00
Barry Hughes 852dc0ca61
Integrates the COT admin list table and COT-based search. (#34421)
* Integrates the COT admin list table and COT-based search.

* A search should be regarded as a form of filtering.
2022-08-23 13:28:11 -05:00
Barry Hughes 1e3bf7aa66
[COT] Implement order search (#34405)
* Support searches as a direct feature of (COT) order queries.

* Always add `DISTINCT` to order queries.

* Add test (+fix order search logic for matching order IDs).

* Changelog.

* Clean-up search_orders() method, remove original roughed-out search code borrowed from CPT data-store.

* Tidy.
2022-08-23 12:15:39 -05:00
Chi-Hsuan Huang 9e891cf47b
Fix marketing task placeholder flash after a plugin is installed (#34414) 2022-08-23 12:07:30 +08:00
Chi-Hsuan Huang c612d04819
Fix store details fails to save store address after navigating back to the tab (#34426) 2022-08-23 11:44:51 +08:00
Chi-Hsuan Huang b07029873b
Update remote inbox notifications readme (#34411)
* Update remote inbox notifications README.md

* Add changelog

* Update readme
2022-08-23 08:20:41 +08:00
Paul Sealock e651a46fb6
Turbo: Avoid caching result of `build:feature-config` (#34296) 2022-08-22 16:28:57 +12:00
Chi-Hsuan Huang 4841595f2f
Fix texts in wp-admin-scripts not translated (#34371)
* Fix texts in wca client/wp-admin-scripts are not translated

* Add changelog

* Fix Navigation/Init.php

* Fix code sniff errors

* Fix param type

* Fix grammar
2022-08-22 07:12:52 +08:00
Christopher Allford d8ed0318ce
Bump WooCommerce 7.0.0 Versions (#34403) 2022-08-19 14:07:00 -07:00
github-actions[bot] 066affe669
Release: Remove 6.9 change files (#34379) 2022-08-19 13:13:21 -07:00
Jorge A. Torres dd070e63e4
[COT] `OrdersTableQuery`: ignore invalid elements in `meta_query` (#34347)
Handle invalid `meta_query` similarly to `WP_Query`

`meta_query` needs to be an array of arrays. Elements in `meta_query` that do not conform to the expected format will be ignored.

* Expose the SQL query in OrdersTableQuery for debugging purposes (similar to WP_Query)

* Add changelog

* Drop unnecessary `is_array()` check
2022-08-19 11:26:57 -07:00
Barry Hughes 87835e3af9
Feature/review table list (#34393)
* review table first adjustment

* fix format

* Update Reviews.php

* fix extra space

* Update plugins/woocommerce/src/Internal/Admin/ProductReviews/ReviewsListTable.php

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* added docblock

* renamed filter, array syntax

* Add changelog.

* Adjust hooks per coding standards.

Co-authored-by: Christopher Hedqvist <christopher.hedqvist@redlight.se>
2022-08-19 11:10:12 -05:00
Daniel W. Robert 8ee227f8df
Update Information Notice for No Products Found (#34362)
* Add additional class to no-products-found banner.

By adding an additional class of `woocommerce-no-products-found`, we can
target the info banner contextually without running the risk of
impacting notifictaions in other areas of the active theme.

See https://github.com/woocommerce/storefront/pull/2027#issuecomment-1218083764

* Add changelog for update.
2022-08-19 10:42:17 -05:00
louwie17 78c28ae9f3
Add product link field (#34313)
* Add initial product field and modal for editing product link

* Create a product link modal for editing product link

* Only show permalink when product is published

* Add changelogs

* Add changelog for data package

* Change save button to primary

* Fix merge conflcts

* Add getPermalinkParts selector to products store

* Made use of getPermalinkParts to support draft products
2022-08-19 12:05:13 -03:00
Vedanshu Jain c27565f413
Link backfilling to migration process (#34167)
* Link backfilling to migration process.

* Add changelog.

* Reduce batch size for backfilling since it is slower.

* Correct grammer.

* Link backfilling with data synchronizer and adopt with pending migration on both sides.

We already have backfilling implemented, however it was not linked. This would make switching data stores back to posts table not possible. This commit links datasynchronizer so that it can both migrate as well as backfill.

* Remove _recorded_sales from skipped check keys since its implemented.

* Share concrete instance of cot controller to share feature value.

* Revert adding concrete controller, object instance is already shared.

* remove yoda condition.

* Remove unintended change.

* Revert from using gmdate.

* Remove hardcoding.

* Remove doc block for fake option support.

* Comment out option check for better testability.
2022-08-19 06:27:19 -05:00
Barry Hughes 77d5842642
Restore 'Contributing to WooCommerce' guidance (#34380) 2022-08-18 10:41:17 -07:00
Joshua T Flowers 32de8bee6f
Add SearchControl component (#34159)
* Add initial SearchControl component

* Add async example

* Reorganize getItemPropsType type

* Create separate MenuItem component

* Update items to use value/label pairs

* Add fuzzy matching example

* Use MenuItem component in example

* Add callback method example and onSelect prop

* Add custom render example

* Add styling

* Simplify Menu component

* Add changelog entry

* Update SelectControl to DeprecatedSelectControl

* Rename SearchControl to SelectControl

* Add readme

* Add placeholder prop

* Add icon to combox box

* Rename deprecated SelectControl classes

* Add changelog entries

* Pass menu props to menu to fix ref issues

* Update lock file

* Rebase and update lock file

* Fix up IDs in e2e tests

* Make list structure more semantic

* Fix update conflict with pnpm-lock

* Move new SelectControl to experimental

* Change experimental class name to avoid style conflicts

* Fix up latest lock file from rebase

* Remove onboarding e2e changes

* Update changelogs

* Update lock file again

* Update pnpm-lock and fix lint error

Co-authored-by: Lourens Schep <lourensschep@gmail.com>
2022-08-18 10:36:20 -07:00
Chi-Hsuan Huang e9d27c8949
Update in-app marketplace to display localized strings (#34356)
* Update in-app marketplace to display localized strings

* Add changelog
2022-08-18 16:51:36 +08:00
Chi-Hsuan Huang 50d4d6774c
Update "Refund Returns" note to display localized strings (#34352)
* Update WC_Notes_Refund_Returns note to display localized strings

* Fix wrong get_action return type

* Add changelog

* Add locale check and unit tests for wc-notes-refund-returns

* Update plugins/woocommerce/includes/admin/notes/class-wc-notes-refund-returns.php

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

* Update plugins/woocommerce/includes/admin/notes/class-wc-notes-refund-returns.php

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2022-08-18 15:37:52 +08:00
Alejandro López Ariza 64b0b2865e
Added new command to set up the local environment with COT enabled. (#34321)
* Added new command to set up the local environment with COT enabled.

* Removed new file added to e2e-environment, which we will no longer be using.

Co-authored-by: jamelreid <jnoelreid@gmail.com>
2022-08-18 08:49:20 +02:00
Chi-Hsuan Huang 6d96a6e4c1
Exclude asterisk from Country / Region translation string (#34368) 2022-08-18 12:17:13 +08:00
RJ e3d0558447
add: store address tour tracks (#34337)
Added tracks event for store address tour dismissal with schema:

'wcadmin_settings_store_address_tour_dismiss'
{
  source: 'done-btn' | 'close-btn',
  fields_filled: {
    address_1: boolean;
    address_2: boolean;
    city: boolean;
    postcode: boolean;
  }
}
2022-08-18 10:10:22 +08:00
Chi-Hsuan Huang 26a3d0d3c1
Update inbox notes to display localized strings when locale changed (#34038)
* Add a filter woocommerce_get_note to modify note before it is returned

* Make ChoosingTheme.get_note public so we can call it outside

* Implement the get_note filter to return localized strings

* Create get_actions method to reuse it in RemoteInboxNotificationsEngine

* Implement get_note filter in RemoteInboxNotificationsEngine to return localized note

* Add changelog

* Make GivingFeedbackNotes.get_note public so we can call it outside

* Check if note class has NOTE_NAME constant

* Update WooSubscriptionsNotes to show localized content

* Rename filter hook name

* Remove todo to pass php lint

* Update filter description

* Move locale check into individual filter functions

* Fix get_note_from_db logic

* Fix php lint errors

* Update the filter doc

* Add test for spec-runner.php

* Add tests for RemoteInboxNotificationsEngine

* Remove unneeded check

* Check if $note_from_class is instance of Note class

* Fix unit test
2022-08-18 09:53:40 +08:00
Jamel Noel Reid b85819f2a9
Fix broken API tests (#34345)
* Bumped jest to v27

* Used jest in packaged node_modules

* Jest bump

* Removed puppeteer related code

* Updated CHANGELOG

* Added changelog
2022-08-17 11:04:41 -07:00
Néstor Soriano 5f257ed7d0
Fix inconsistent order total on checkout vs manual order page (#33812)
* fix: tax calculation and coupon sequence

* add phpunit skeleton

* Refactor calc_line_taxes and add_coupon_discount

The methods are moved to separate classes in src/Internal,
and two new "core" methods that exclude HTTP processing are added.

* The test partially passes now

* Final fix to unit tests, and fix remaining formatting issues

* Add changelog file

* Fix path to html-order-items.php

Co-authored-by: Siddharth Thevaril <siddharth.thevaril@gmail.com>
2022-08-17 14:56:28 +05:30
Ismael Martín Alabarce 115cac05de
Add WC Payments welcome page experiment (#34251)
* Show WCPay welcome page to all eligible merchants.

Remove the experiment and also check for marketplace suggestions.

* Update banner design and copy

Replace background `wcpay-banner.png` with `wcpay-offer.svg`, `flag.j` svg component with `gift.js`. Adjust styles and ensure it's responsive.

* Add more requirements.

Don't register it when there is an existing WCPay account or the site is on a WPCOM starter plan.

* Update promotion and FAQ copy

* Add the new experiment.

And remove the supported country check to use Explat instead.

* Add changelog entry

* Remove WPCOM starter plan check

* Remove Yoda comparisons

* Update `wcpay_exit_survey` event.

Record it also when the user chooses `Just remove` and use snake_case to avoid Track errors.

* Country and time conditions.

Only for US based businesses with a live store of at least 90 days.

* Update design and copy to match new requirements

* Update promo ID

* Fix country condition

* Load SVG as image instead of background

To prevent wrong asset generation due to Webpack configuration

* Fix WCPay installed condition

* Update promo ID

* Update promo ID in allowed notes

* Update FAQ copy

* Add `apply_filters` docblock

* Add missing `@since` to docblock comment
2022-08-17 17:11:51 +08:00
Rommel Castro 796c52018f
Add `wc com connect` command (#34073) 2022-08-17 10:21:16 +02:00
Paul Sealock 7a1048340e
Delete changelog files based on PR 34354 (#34355)
Delete changelog files for 34351
2022-08-17 18:33:04 +12:00
Chi-Hsuan Huang 64e14ebe7d
Enhance/34244 update data source poller for i18n (#34247)
* Update data source poller for i18n

* Update unit test

* Remove unnecessary change_locale hook

* Fix payment-gateway-suggestions unit test
2022-08-17 12:06:46 +08:00
Ilyas Foo cd5ffed61b
Deploy payments banner in settings page (#34326)
* Deploy payments banner in settings page, updated tests

* Add track on banner CTA click

* Add test for track

* Changelog

* Fix unit tests
2022-08-17 11:33:24 +08:00
Moon 68985e3222
Fix: Smart shipping defaults bug (#34351)
* Do not create default shipping zones when a shipping zone already exists

* Add changelog

* Use woocommerce_admin_skipped_creating_default_shipping_zones to avoid triggering spotlight tour

* Set woocommerce_admin_reviewed_default_shipping_zones to yes to prevent spotlight tour for the existing shipping zones
2022-08-16 20:18:52 -07:00
Eric Jinks 3739c425ac
Remove WCPay Subscriptions offer page experiment code (#34317)
* Remove WCPay Subscriptions offer page experiment

This removes all code added in PR#32957 as experiment has ended.

(WooCommerce > Subscriptions admin menu item and empty state offer screen)

* Add changelog entry
2022-08-17 15:07:39 +12:00
Peter Fabian 82b95fb474
Remove PHP 8.1 warnings and errors (#34336)
* Make the php file valid

* Remove code that's no longer in PHP.

mysql_* functions were removed in PHP 7.0

* Remove deprecated setting.

This only helps detecting \r as end of line and that should only be used in old MacOS 9 which is 20 years old by now.

* Changelog

* Added compulsory file comment.

* Removed forgotten phpcs flag

* ...and more cleanup.
2022-08-16 10:22:53 -07:00
Jorge A. Torres ecec9eaa76
[COT] Respect status flags `show_in_admin_(all|status)_list` in orders list table (#34290)
* Implement filtering by status in list table

* Respect ‘show_in_admin_status_list’ in list table

* Display correct status name for ‘draft’ and ‘trash’ post statuses
2022-08-16 12:37:46 +02:00
Sam Seay f4595c6ed4
Fix a bug crashing wp-env 5.1.0 in CI (#34274)
* remove `core: null` from wpenv json config
* peg wp-env to 5.1.0
2022-08-16 13:21:52 +12:00
Chi-Hsuan Huang ed9cd231d2
Add unit tests for orders milestone note (#34295)
* Refactor OrderMilestones.php

* Add unit tests for Orders Milestones note

* Add changelog

* Update OrderMilestones.php

* Fix OrderMilestones.php
2022-08-16 08:42:11 +08:00
Chi-Hsuan Huang 71ffd2c548
Update "context" prop of task list click/view event (#34297)
* Update Update context prop of wcadmin_tasklist_/view event

* Add changelog
2022-08-16 08:41:59 +08:00
Jamel Noel Reid 40dbc1f924
Update CI to use wp-env for api, e2e and performance tests (#34311)
* Renamed e2e to e2e-legacy

* Moved e2e folder to tests/e2e

* Updated gitignore

* Updted init script to work with wp-env

* Updated readme

* Updated commands to match new test structure

* Updated workflow to work with new test structure

* Added changelog

* turned off alternate wp cron in test

* Fixed path to playwright config

* Renamed e2e to e2e-pw

* Renamed e2e-legacy to e2e

* Updated e2e-pw path

* Fixed workflow

* Fixed csv test

* Updated .gitignore

* Removed puppeteer specific step
2022-08-15 11:47:53 -07:00
Barry Hughes 7021d442bd
Clear post cache after updating menu order for products. (#34195) 2022-08-15 07:28:14 -07:00
Rommel Castro 2ab9398167
Add `wc com disconnect` command (#33999)
* extract `disconnect` function

* extract `is_site_connected` function

* add `wc com disconnect` command

* add changelog

* fix phpcs errors
2022-08-15 09:54:55 -03:00
Chi-Hsuan Huang de46baf8fc
Fix review shipping option task title (#34294)
* Fix Review Shipping Options Task title

* Add changelog

* Reformat by phpcbf
2022-08-15 17:41:12 +08:00
Adrian Duffell d6224d8a0c
Add Facebook Extension to Onboarding (#34303)
* Add facebook logo

* Add facebook to OBW

* Add pinterest to OBW

* Add changelog

* Revert "Add pinterest to OBW"

This reverts commit cd99fb296c.

* Update changelog

* Update facebook URL

* Switch the “alt” data

* Update manage url
2022-08-12 14:54:53 -07:00
Peter Fabian 0f99bd4e8d
Fix/forgotten template version (#34308)
Corrected the template version.
2022-08-12 08:23:34 -07:00
Barry Hughes 1a4060d689
Fix/34271 unlimited results (#34289)
Support for unlimited ('-1') results in COT queries.
2022-08-12 08:22:32 -07:00
Fernando 4693e251f7
Add product name and checkboxes for Product details (#34214)
* Add product details

# Conflicts:
#	plugins/woocommerce-admin/client/products/sections/product-details-section.tsx

# Conflicts:
#	plugins/woocommerce-admin/client/products/sections/product-details-section.tsx

* Rename folder

* Fix help icon

* Fix form

* Removed useless `useState`

* Add `getCheckboxProps`

* Add params to getCheckboxProps

* Add recordEvent

* Rename event

* Add changelog

* Fix texts

* Remove Fragment

* Fix useState initial state

* Convert EnrichedLabel to TS

* Fix unknown value prop

* Rename event

* Move EnrichedLabel

* Fix js warning

* Add storybook

* Add readme

* Add components changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-08-12 10:47:54 -03:00
RJ 6a95d3ee93
dev: move guided tours into consolidated folder (#34279)
* dev: moved shipping tour into guided tours folder

* dev: moved store address tour to guided-tour folder

* dev: updated imports for store address tour code move

* dev: move add-product-tour to guided-tours

* dev: update imports for add-product-tour code move
2022-08-12 09:49:18 +08:00
Barry Hughes bc31065b8e
Filtering for the COT admin list table. (#33789)
* Column sorting for the COT admin list table.

* Add filter for easier extensibility.

* Implement date based filtering within the admin order list table.

* Implement customer-based filtering within admin order list table.

* Allow filtering down to no results, better management of http_referer state.

* Changelog.

* Bring up-to-date, fix some conflict resolution mis-steps.

* Address coding standards.

* Remove unused import.
2022-08-11 13:00:47 -03:00
louwie17 a498cc8280
Add product form buttons and specific product edit page (#34211)
* Add initial product form action buttons to form

* Add new edit page and allow for updating and creating products

* Move crud functions to helper hook to keep things seperated better

* Add changelog

* ADd package changelogs

* Add isPending selector to products store

* Fix trash screen showing up when deleting product and add loading indicators

* Add extra types to Product type

* Update track names and add product data to tracks

* Update track logic when product is published

* Remove the Image section for now, to prevent confusion as it is not ready yet

* Add tests for the product form actions

* Update copy for publish & duplicate

* Remove unused code

* Set window.location correctly with href

* Reset changes in pnpm lock

* Moved pending action variables to product helper and updated buttons to reflect new suggestions

* Fix backwards compabitibility issue with Form changes

* Add switch to draft button
2022-08-11 11:04:14 -03:00
Jorge A. Torres 055ed34c0d
[COT] Add support for /v3/orders (#34178)
* Use WC_Order_Query for REST API v3 requests when COT is enabled

* Remove pre-COT internal meta keys from metadata in REST order responses

* Add changelog

* Add unit tests

* Fix test in `ProductAttributesLookup\FiltererTest`

Some tests in this class relied on a particular ordering of an array of IDs returned by a query with an `ORDER BY` that doesn’t really disambiguate sorting (all rows have the same values for the fields). As such, `assertEquals()` can’t be used to make sure arrays had the same values.

* Use `get_internal_meta_keys()` from a CPT instance to hide certain meta on COT REST response

* Move COT REST test outside of the COT datastore tests

* Fix typo

* Remove unnecessary imports
2022-08-11 13:11:18 +05:30
Chi-Hsuan Huang 831c9fcab3
Keep the user in the marketing task after installing an extension (#34241)
* Keep the user in the marketing task after installing an extension

* Add changelog
2022-08-11 08:56:58 +08:00
Seghir Nadir 0a9c0049b3
support single_select_page_with_search in WC REST API (#34234)
Support single_select_page_with_search in WC REST API
2022-08-10 14:37:53 -07:00
Chi-Hsuan Huang 58ff656764
Remove @wordpress/eslint-plugin from woo admin package.json (#34240)
* Remove @wordpress/eslint-plugin from woo admin package.json

* Add changelog

* Update pnpm-lock.yaml
2022-08-10 14:45:40 +08:00
Moon dd794e8e26
Update/34063 store location skip btn (#34176)
* Make ProfileItems properties optional

* Remove skip button codes and replace them with SkipButton component

* Add SkipButton component

* Add changelog

* Add back continue button callback

* Apply popover styles globally

* Add skip button on the industry step

* Add skip button on the product types step

* Add skip button on the Business Details step

* Support onSkipped callback

* Record skip event

* Add skip event track for industry, product types, and business details

* Add SkipButton to the theme step

* Update snapshot

* Change track name to separate business details and free features

* Add changelog

* Remove unused code

* Update product types test snapshot

* Add back UsageModal on Continue click

* Update e2e tests to use Skip

* Use button selector for skip btn

* Fix duplicate event dispatch

* Do not call onClose and onContinue during the rendering -- it causes cannot update a component while rendering a different warning. Instead, call them when the button is clicked

* Skip the profiler without rendering usage modal when woocommerce_allow_tracking is set

* Skip the profiler without rendering usage modal when woocommerce_allow_tracking is set

* Go to the next step when allowTracking is yes
2022-08-08 21:08:03 -07:00
Paul Sealock 2fe344e2af
Remove cherry-picked 34209 changelogs (#34216)
remove wc-admin changelogs
2022-08-09 11:15:52 +12:00
Néstor Soriano cc779db83c
Add the woocommerce_cart_session_initialize-hook (#34156)
* Add the woocommerce_cart_session_initialize-hook

* Add changelog file
2022-08-08 16:54:44 -03:00
Oliver Juhas bb02983893
Accessibility: Adding missing form field and table header labels to template files (#31211)
Add screen reader labels to improve accessibility in various locations.

* Adding missing table header labels
* Adding missing form field labels
* Adding missing form field label
* Adding missing form field labels — Ideally we would add these with `<labe>` tag (may be hidden with `screen-reader-text` class), but playing safe here to prevent CSS style issues.
* Adding missing form field label
* Changing `aria-label` attribute to actual `<label>` tag
* Rebase; add changelog.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-08-08 12:32:51 -07:00
Vedanshu Jain fe27a9a87c
Add various Util methods to OrderUtil class (#34141)
Add method in utils to check whether posts and order tables are in sync.

* Add changelog.
* Fix Yoda condition

Co-authored-by: Nestor Soriano <konamiman@konamiman.com>
2022-08-08 11:28:35 -07:00
nigeljamesstevenson fbb6bd1c53
Add e2e test to check ability to add and remove regions from shipping… (#34187)
* Add e2e test to check ability to add and remove regions from shipping zone

* Add changelog file

* skip test in order to check CI

* add skipped test back in

* group shipping zone tests to avoid concurrency issues

* update assertions relevant to added zone region

* update test file

* update test to select appropriate delete based on other tests

* Ensure the correct Shipping Zone has been removed

* remove attempt to delte zone via front end as API call will handle this
2022-08-08 11:26:35 -06:00
Chi-Hsuan Huang af97aaf410
Migrate @woocommerce/data settings store to TS (#34184)
* Migrate wc.data.settings to TS

* Correct data.settings type

* Fix wc admin client type errors

* Add changelog

* Add changelog

* Update types

* Update RawSetting type
2022-08-08 13:25:46 +08:00
Chi-Hsuan Huang 3bbee139ed
Update "Add store details" task complete logic (#34206)
* Update store details task complete logic

Mark as completed if the store address, city and postcode are set.

* Add changelog

* Update store details test
2022-08-08 13:21:10 +08:00
Fernando 88c7cfb628
Fix Customer Effort Score Tracks (#34209)
* Rename sent prop (CustomerEffortScore)

* Add changelog

* Fix changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-08-05 15:40:01 -03:00
Jorge A. Torres c2cd415ab5
[COT] Misc test fixes (#34210)
* Stop resetting all definations in DI to not initialize hooks again.

* Adjust setting test to account for COT feature.

* Support temporary tables.

* Add changelog

Co-authored-by: Vedanshu Jain <vedanshu.jain.2012@gmail.com>
2022-08-05 11:08:35 -07:00
Néstor Soriano 3a76aa4255
Disable the WordPress.PHP.YodaConditions.NotYoda phpcs rule (#34204) 2022-08-05 10:39:55 +02:00
Ilyas Foo bc98010cd3
Fix set default homescreen layout after setup task completion or dismissal (#34191)
* Add set layout function after setup task completion or dismissal

* Add test

* Changelog
2022-08-05 15:53:11 +08:00
RJ f3e436f991
fix: type definition issues related to pnpm hoisting rules in preparation for pnpm 7 upgrade (#34154)
- added missing TS definition dependencies
2022-08-05 15:19:08 +08:00
Néstor Soriano a397168a37
Disallow/discourage Yoda comparisons in the WooCommerce codebase (#34185)
- Use the built-in phpcs sniff for "includes" (as warnings)
- Use the slevomat coding standards package for the rest of the code
  (as errors, with the ability to auto-correct)
2022-08-05 09:02:20 +02:00
Jorge A. Torres 7a1999ec86
[COT] `query()` method: add support for date queries (#34119)
* Add some date-related query arg mappings

* Add `join()` utility method

* Add support for date_query

* Add date_query tests

* Add changelog

* Address feedback

* ‘type’ not yet implemented

* Remap legacy date columns too
2022-08-05 08:59:12 +05:30
Sam Seay 5becf47d60
Simplify turbo commands (#34055)
* Change package json commands and turbo repo config to allow for greatly simplifying running turbo
* Remove require-turbo script which was causing caching issues
* Colorize CI output from scripts
* Add missing changelog script to extend-cart-checkout-block
2022-08-05 12:03:17 +12:00
Alba Rincón 4a4de7a7f6
Hide the customizer when the active theme is a FSE theme (#34022)
Only register the customizer and related scripts when the active theme is a classic one.

* See https://woofse.wordpress.com/2022/06/07/pt-ensure-customizer-doesnt-show-up-with-block-themes-active-2/
* Skip the test if the WP version is not compatible with the block theme.
* Move the condition to avoid the class instantiation when theme is fse.
2022-08-04 09:57:50 -07:00
louwie17 470fc899e1
Add/33 two column product page layout (#34113)
* Add product page layout components

* Add a quick sample page to test the product form layout

* Add changelog

* Add option 2

* Refactor the product field layout structure

* Update page component structure of product form

* Add simple SlotFill support

* Update product page chunk name

* Add order to slot fill and move product field layout wrapper into product category layout

* Remove unused import

* Consolidate the slot fill ordering logic

* Rename category component to section component to prevent confusion

* Remove edit product page and use the new add product page instead

* Add tests

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-08-04 10:15:30 -03:00
Vedanshu Jain 5f0efcf02f
Fixes a WP nightly unity test (#34190)
* Dont check for cache when there are no cached templates.

* Add changelog.
2022-08-04 10:00:39 -03:00
Néstor Soriano 0e0212254e
[COT] Add unique key constraints for the addresses and operational data tables (#34144)
* Add unique constraints to the COT addresses and operational tables

* Add changelog file
2022-08-04 16:52:08 +05:30
RJ 75f6ec3a43
dev: refactor Homescreen component to use useQuery hook (#34183)
- added useQuery hook for usage in functional components
- refactored Homescreen component to useQuery instead of prop drilling
2022-08-04 16:57:53 +08:00
Chi-Hsuan Huang cb87be1552
Update store location profiler (#34153)
* Update store details unit tests

* Update store details subheading and field order

* Update obw store details e2e tests

* Add changelog

* Add changelog

* Update Store owner can go through setup Task List test
2022-08-04 09:02:50 +08:00
Fernando 835f3d548e
Add/42 new product page (#34115)
* Add feature falg

* Modify href to menu item

* Modify page title href button

* Add product files on Client

* Change button's URL for new Nav

* Add changelog

* Moved changelog

* Fix URL for new nav

* Change URL for add product task

* Add Tracks event

* Change const name

* Renamed tracks event name

* Undo Add New Product redirect

* Undo use Products addition

* Undo lint fix to woocommerce_admin.js

* Rename component and file (AddProductPage)

* Set flag in core.json to false

* Fix typo

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-08-03 14:42:22 -03:00
Vedanshu Jain e4dae58502
Upgrade misc WooCommerce bits to support COT (#34124)
Update miscellanous WC bits to support custom tables.

* Add changelog.
* Add test for order_meta call.
* Make CI happy.
* Add tests for before_delete_order.
* Add test for is_valid_resource
* Add tests for PayPal API.
* Add test for save paypal meta data.
* Minor fixup.
2022-08-03 09:41:37 -07:00
Luigi Teschio 397a7846b5
JQuery FlexSlider: Fix innerHeight computation (#33847)
Fix computation innerHeight
2022-08-03 09:20:42 -07:00
Vedanshu Jain ef08507c13
Add support for updating values in order edit form inside WP Admin (#33972)
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-08-03 13:55:54 +02:00
RJ d44942dc0d
fix: e2e test on shipping task (#34165)
- shipping task was recently changed and shipping method is set up automatically now
2022-08-03 15:08:27 +08:00
Kaavya a9b0542532
Fix/33253 fix order number in notice (#33802)
Fix order number displayed in order status changed notice
2022-08-02 10:02:15 -07:00
Néstor Soriano c06ae5d903
Add a namespace prefix to the Psr/Container package (#33703)
Remove the explicit dependency from the psr/container package

* Prepend the psr/container package classes with a namespace using Mozart. This is done to prevent conflicts with other versions of the package used by other packages or plugins.
* Add changelog file
* Minor documentation/indentation updates
2022-08-02 09:59:32 -07:00
RJ cb09649a4c
add: store location settings tour (#34137) 2022-08-02 11:10:34 +08:00
Néstor Soriano e05697dfab
[COT] Fix order related methods in customer data store (#34121) 2022-08-01 11:13:55 +02:00
Néstor Soriano 5459f7e8ef
[COT] Add remove_processor method in batch processing controller, use it when disabling orders sync (#34122)
Also fix a bug: force_clear_all_processes wasn't actually unscheduling the watchdog.
2022-08-01 11:13:15 +02:00
Paul Sealock 06d5222585
Changelog removals due to 34133 (#34134)
remove changelog
2022-08-01 12:19:43 +08:00
Jorge A. Torres 0a3c3e7463
[COT] Make sure status is correctly prefixed for saving (#34128)
Make sure status is correctly prefixed for saving
2022-07-29 19:11:36 -07:00
Barry Hughes c97c373870
Remove 'do not edit' warnings (not applicable following monorepo rest… (#33790)
Remove 'do not edit' warnings (not applicable following monorepo restructuring).
2022-07-29 13:49:23 -07:00
Vedanshu Jain f7959c7680
Add order edit rendering when creating new order (#33848)
* Create an empty order when initializing new order form.

* Set object read to false to preent order note.

* Add changelog.
2022-07-29 17:08:38 -03:00
Barry Hughes 406853634a
Column sorting for the COT admin list table. (#33787)
* Column sorting for the COT admin list table.

* Add filter for easier extensibility.

* Changelog.

* Add support for orderby order’s total and creation/modification dates

* Remove unnecessary import

* Use ‘any’ instead of ‘all’ as status so that all valid statuses are used instead

* Use ‘order_total’ as orderby GET arg for backwards compat

* Rework sorting logic after support in `OrdersTableQuery`

* Update `@since` tag

* Make PHPCS happy

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-07-29 13:52:25 +05:30
RJ be89ba6e06
fix: wrong condition for shipping recommendations tour step (#34120) 2022-07-29 15:34:00 +08:00
Paul Sealock 4284673b68
Delete changelog files based on PR 34116 (#34117)
Delete changelog files for 34099
2022-07-29 10:15:41 +12:00
Paul Sealock d4e19d6c51
Beta Tester: Update composer lock file (#34086)
* Update Beta Tester lock file

* changelog
2022-07-29 09:11:04 +12:00
Moon 15015b9eda
Clean up setup_experiment_1 and setup_experiment_2 experiments (#34084)
* Remove setup_experiment_1 and setup_experiment_2 tests and css

* Remove setup_experiment_1 and 2 from the client code

* Copy over setup_experiment_1 options to the setup tasklist and remove setup_experiment_1 and 2

* Add changelog

* Determine the default component to use by task id

* Update plugins/woocommerce-admin/client/tasks/hooks/useActiveSetupList.ts

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-07-28 09:16:10 -07:00
Daniyal Ahmed 94cc85be6c
Fix fatal error when bulk editing sale price to empty value in PHP 8 (#34053) 2022-07-28 15:31:46 +02:00
Néstor Soriano 2c8a68315b
Introduce the object cache infrastructure (#33634)
* Introduce the ObjectCache class.

It's an abstract class intended to be used to implement caching for
any kind of object (arrays or PHP objects) using the underlying
WordPress caching or any alternative custom cache engine.

* Add changelog file

* Change the order of parameters in ObjectCache::get

Also change the max expiration value from one day to one month
2022-07-28 08:20:09 -03:00
Vedanshu Jain b4fcbd80a4
Render order edit page (#33638)
* Implement order edit screen rendering.

* Add changelog.

* Use global function instead of harcoded string.

* Use pagecontroller to display order edit form.

* Move HTML out from the translatable string.

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* Capitalize `Order` for consistency.

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* Minor realignment.

* phpcs fix .

* Decouple meta boxes from global $post object to support custom order tables.

* Bug fixes - improperly set $order object, and allow passing null.

* Make order item meta work with order object.

* Use `$order` object to minimize diff.

* Refactor $theorder object initialization to a common method.

* Remove check for WC_Order object.

* Move common methods to inside `src` in a dedicated class.

* Fix spacing for code style.

* Renamed method to be more accurate.

* Add proxies for static so they can be mocked.

* Remove PageController import.

* Move helper methods to an internal util class.

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-07-28 15:07:34 +05:30
Ilyas Foo a94d6c57ff
Fix shipping zone count transient reset (#34099)
* Delete shipping zone transient on adding shipping zone via smart defaults

* Changelog

* Fix comment
2022-07-28 16:18:08 +08:00
Paul Sealock e05f52b18a
Delete changelog files based on PR 34093 (#34094)
Delete changelog files for 34045
2022-07-28 17:05:27 +12:00
Adrian Duffell 50421efc3f
Fix Tracks event in Review Shipping task (#34045) 2022-07-28 12:21:32 +08:00
Moon dfa8d017f3
Use the default payment suggestions when woocommerce_show_marketplace_suggestions is set to no (#34083)
* Support force_default_suggestions argument

* Use force_default_suggestions

* Support force_default_suggestions argument -- returns the default payment suggestions when both woocommerce_show_marketplace_suggestions and woocommerce_setting_payments_recommendations_hidden options are set to no

* Add changelog
2022-07-27 21:02:24 -07:00
Paul Sealock 7fecfb35a8
Delete changelog files based on PR 34091 (#34092)
Delete changelog files for 34074
2022-07-28 15:20:39 +12:00
Paul Sealock b0b08c5c81
Delete changelog files based on PR 34089 (#34090)
Delete changelog files for 34072
2022-07-28 15:14:08 +12:00
Paul Sealock df35f674d4
Delete changelog files based on PR 34087 (#34088)
Delete changelog files for 34070
2022-07-28 15:09:16 +12:00
Chi-Hsuan Huang bc177ae83a
Fix shipping zone fails to create after installing Jetpack and WCS (#34074)
* Fix shipping zone fails to create after installing jetpack and wcs

* Add changelog
2022-07-28 09:40:56 +08:00
Joshua T Flowers 345b8886e5
Log tracks events after they have been validated (#34030)
* Log events after they have been validated

* Add changelog entry

* Remove old tracks file

* Fix lint errors
2022-07-27 14:01:18 -04:00
Joshua T Flowers 30de9ccb19
Add utils for testing tracks in backend (#34010)
* Add methods to get and clear queued pixel events

* Add utils for getting and asserting events in unit tests

* Add in some assertions around task list completion tracks

* Add changelog entry

* Add comment for test task fixture
2022-07-27 11:51:10 -04:00
Néstor Soriano 6c9254a18b
Fix: product attributes lookup table usage enabled on each upgrade (#34072)
* Stop re-enabling product attributes lookup table usage after each install.

Now the option will be enabled after a WooCommerce install/update
only if the user hadn't explicitly disabled it before.

* Add changelog file
2022-07-27 10:50:43 -03:00
Ilyas Foo aaa20f556b
Fix missing product task add product track via product templates (#34070)
* Add missing track on adding products via product templates

* Changelog
2022-07-27 12:47:18 +08:00
rodelgc 4dce15e706
E2E: Update WSL readme (#34068)
* Update link to setting default Linux distro in WSL

* Add changelog
2022-07-26 12:22:43 -07:00
Jorge A. Torres c97e1067c7
[COT] `query()`: add support for the `customer` query var (#34059)
* Make sure orders are saved with a default status

* Add support for ‘customer’ query var in COT

* Make PHPCS happy in COT datastore tests

* Add tests for ‘customer’ query var

* Add changelog
2022-07-26 15:54:12 +05:30
Paul Sealock 844faf2fa4
Delete changelog files based on PR 34061 (#34062)
Delete changelog files for 34054
2022-07-26 14:38:51 +12:00
Jamel Noel Reid 7e3b3ee94c
Add JSON report output to PW tests (#34057)
* Add PW json report when in CI

* Added wait for flaky test

* Used more robust selectors

* Added changelog
2022-07-25 10:44:11 -07:00
Jorge A. Torres 290b3b2dc0
[COT] Implement `query()` in the COT datastore (#33834)
* Add OrdersTableQuery for querying the COT tables

* First stab at `OrdersTableDataStore::query()` method

* Silence possible PHP warning

* Add docblocks & phpcs fixes

* Introduce OrdersTableMetaQuery

* Add support for meta_query

* Add changelog

* ‘status’ should have the ‘wc-‘ prefix

* PHPCS fixes

* Minor improvements

* Add tests for OrdersTableQuery

* Remove ‘paginate’ query var

* Add support for reading multiple objects at once

* Address feedback

* Prevent `get_order_data_for_ids()` from producing an incorrect query when no IDs are passed

* Make CI happy
2022-07-25 21:06:53 +05:30
Michael P. Pfeiffer 5ddcc40f04
Add WooCommerce default styles for block themes (#33518)
* Add WooCommerce default styles for block themes

* Ensure sale badge remains as is in Twenty Twenty-Two

* Style the mark element in theme colors

* Update product variations dropdowns

* address feedback

* address feedback

* fix store notice position

Co-authored-by: Luigi <gigitux@gmail.com>
2022-07-25 11:06:31 -03:00
Néstor Soriano 0b6de76567
Reduce the amount of terms shown in attributes page (#33962)
The attributes page displays all the terms for all the existing
product attributes, which causes a performance problem in sites
with a lot of attributes and terms.

This commit limits the number of attributes shown to 100 by default,
but it also introduces a woocommerce_max_terms_displayed_in_attributes_page
filter to customize it.
2022-07-25 08:55:08 +02:00
Ilyas Foo e41c8b027d
Fix unusable historical import (#34054)
* Add resolvers to data store

* Changelog
2022-07-25 11:20:40 +08:00
Néstor Soriano 166fecc0c1
Use method_exists instead of throwing in AbstractServiceProvider::reflect_class_or_callable (#33960)
* Use method_exists instead of throwing in reflect_class_or_callable

In AbstractServiceProvider::reflect_class_or_callable we were
detecting whether a 'init' method exists in the class or not via
doing 'new ReflectionMethod' and catching the exception.
This caused problems with XDebug, which is bad enough, but additionally,
throwing an exception when it's not abosultely necessary
is a bad practice in general.

* Add changelog file
2022-07-22 15:31:49 -03:00
Néstor Soriano 7d2a992746
Fix code standards in orders code, and check payment method name instead of title on get order totals (#30468)
* Fix code standards errors in class-wc-meta-box-orrder-data.php

- Sanitize all input
- Escape all output
- Verify nonce on save
- Verify that all required POST parameters are present on save
- Minor fixes (periods at end of comments, function docs, Yodas...)

* Check payment method name, not title, on add_order_item_totals_payment_method_row

* Remove unnecessary nonce verification in "save" for orders.

Also move comment to new line for readability.

* Remove unnecessary nonce check in WC_Meta_Box_Order_Data::save

 The check is already performed in the code that invokes "save".

* Add transaction id to payment method string if URL doesn't exist

* Minor fix

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-07-22 14:54:51 -03:00
louwie17 383c96f0ca
Update woocommerce admin scripts to align more with turborepo (#33982)
* Update woocommerce admin scripts to align more with monorepo

* Add changelog

* Add dev script back in

* Add install-if-deps-outdated back into build script

* Remove --force from dev script and add WC_ADMIN_PHASE to turbo cache key

* Remove install-if-deps-outdated from build

* Add composer install step to pr unit tests workflow

* Remove old install scripts, that are not needed anymore

* Make sure client changes are part of the cache hit

* Add composer install to code coverage and code sniff as well

* Add composer_no_dev input to install-build workflow

* Add sass dependency to woocommerce/admin/client turbo cache
2022-07-22 08:32:03 -03:00
Paul Sealock f056e041bb
Delete changelog files based on PR 34033 (#34034)
Delete changelog files for 34021
2022-07-22 11:49:05 +12:00
Paul Sealock b9a20edc55
Delete changelog files based on PR 34031 (#34032)
Delete changelog files for 33990
2022-07-22 11:46:37 +12:00
Alba Rincón 7741fd38f1
Update composer.lock after updating to WooCommerce Blocks 8.0.0 (#34021) 2022-07-22 11:37:13 +12:00
Fernando 59c9ef7922
Add validations to `recordEvent` (#33911)
* Add validations to `recordEvent`

* Add changelog

* Use always class constant

* Changed trow exception by console.error

* Add tests to `validate_and_sanitize`

* Created 2 different methods to test `event_validation_and_sanitization`

* Fix tests

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-07-21 16:11:32 -03:00
Chi-Hsuan Huang d09d59186d
Fix free features is still rendered when no recommendation (#33923)
* Fix free features is still rendered when there is no recommendation

* Add changelog

* Update BusinessDetails tab to go to next step if no installable extensions

* Update spinner
2022-07-21 12:57:46 +08:00
Paul Sealock 9620704d42
Delete changelog files based on PR 34008 (#34009)
Delete changelog files for 33934
2022-07-21 12:37:32 +12:00
Lucas Bustamante f1ba1febea
Add detailed logs for e2e setup/teardown (#34004) 2022-07-20 16:34:24 -07:00
Joel Thiessen 7741464a32
Adding additional instructions around product image upload modal (#33660) 2022-07-20 12:14:48 -07:00
Fernando 8b9ec814ec
Product creation experience: add more context about product data (#33755)
* Add product types tooltip

* Add target `_blank`

* Add changelog

* Fix typo

* Add onChange method

* Fixed product type tooltip

* Fix icon style

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-07-20 13:36:01 -03:00
Lucas Bustamante 3f1543c2db
Exclude e2e folder from build (#33934) 2022-07-20 16:17:24 +02:00
Lucas Bustamante 399796aa2d
Retry login on e2e (#33997)
* Retry login on e2e

* Add changelog
2022-07-20 07:46:29 -06:00
Moon f56b1da519
Make sure get_current_screen() is available (#33990)
* Make sure get_current_screen is available

* Add changelog
2022-07-20 03:31:46 -07:00
Chi-Hsuan Huang 9bc4e88b1a
Wrap default payment gateway strings in __() function call (#33987)
* Wrap default payment gateway strings in __() function call

* Add changelog
2022-07-20 16:28:22 +08:00
Kirtan Gajjar 2e735ed5f7
Fix type safety issues in product price (#33926) 2022-07-20 09:10:18 +02:00
Lucas Bustamante 4ffd5992a9
Reduce e2e flakiness in CI (#33979) 2022-07-19 11:28:15 -06:00
Jonathan Lane 26df595313
E2e/playwright test improvements 2 (#33965)
* Set retries to 4 on CI

* Use variable for authentication path storage

* Handle test cleanup in after hook

* Improve conditional

* Clean up global attributes

* Update customer email address

* Changelog file

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2022-07-19 10:04:53 -03:00
Vedanshu Jain df1937d71a
Add framework to write more robust action scheduler based migrations. (#33233)
Add the BatchProcessingController class and the BatchProcessorInterface interface.

Co-authored-by: Nestor Soriano <konamiman@konamiman.com>
2022-07-19 14:42:36 +02:00
Paul Sealock 8d56c31b3e
Delete changelog files based on PR 33967 (#33968)
Delete changelog files for 33956
2022-07-19 12:11:56 +12:00
Chi-Hsuan Huang 282d8daa26
Fix "undefined offset" warning notice on payment settings page (#33956)
* Fix undefined offset notice on payment settings page

* Add changelog
2022-07-18 16:54:02 +08:00
jonathansadowski 1a9a17c1e5
Update stable tag for 6.7.0 release (#33930)
* Update readme.txt

* Add change file
2022-07-15 09:52:27 -05:00
aezazs-multidots 0cbaab737d
Added the border bottom of the modal's header (#33807)
* Added the border bottom of the modal's header

* Created changelog entry

* Changelog entry update
2022-07-15 14:35:34 +08:00
Chi-Hsuan Huang 92df587769
Fix task list overlaps with the Ellipsis menu (#33882)
* Fix task list overlaps with the Ellipsis menu

* Add changelog
2022-07-15 10:26:22 +08:00
Paul Sealock 3575254895
Prepare trunk for version 6.9.0 (#33918) 2022-07-15 14:05:16 +12:00
Lucas Bustamante 2a89de195f
Small typos (#33914)
* Small typos

* Rewording
2022-07-14 14:40:32 -07:00
github-actions[bot] 93817aeeee
Release: Remove 6.8 change files (#33913)
Delete changelog files from 6.8 release

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-07-15 09:34:53 +12:00
Lucas Bustamante 5e4e37932f
Doc improvements for Playwright e2e (#33910)
* Doc improvements for Playwright e2e

* Remove spacing changes

* Undo spacing
2022-07-14 14:18:43 -07:00
Jamel Noel Reid 2da933a946
Configured wp-env to work with Playwright tests (#33850)
* Updated wp-env test port

* Added script to init test env

* Added env helper scripts

* Updated admin email to match wp-env

* Fixed flaky tests

* Updated test readme

* Updated workflow to use wp-env

* Added changelog

* Stored admin email in variable

* Added check for flaky test

* Updated workflow to work with both envs

* Updated README.md

* Updated condition

* Updated changelog

* Fixed workflow

* Fixed workflow

* Fixed workflow

* Restored workflow

* Updated check to be a string
2022-07-14 13:23:41 -07:00
Josh Betz 6f786e61c5
API: System Status: Cache plugins data (#33899)
* API: System Status: Cache plugins data

This is a follow up to https://github.com/woocommerce/woocommerce/pull/32823
where we introduced caching for retrieving theme data. Here we're
cachcing plugin data. Since we have to read from the filesystem and
parse the plugin headers, this can be kind of slow.

We should see an improvement on sites with more than a few plugins and
the improvement could be significant on sites that have many plugins
installed (even if they're not active).
2022-07-14 12:41:17 -05:00
Thilina Pituwala 449af6825f
Add the wp wc com extension list command (#33783)
* add CLI com command class and hook it

* Update php docs and change registered command names for wc com.

* Fix lint issues.

* Retrieve and display extension list and for the connected site.

* Adding the changelog for wc com extension list

* Remove the install command which not implemented in current branch.

* Update example usages for wp wc com extension list command.

* Update changelog.

* Fix the changelog file formatting

Co-authored-by: Rommel Castro <rommelxcastro@gmail.com>
Co-authored-by: Néstor Soriano <konamiman@konamiman.com>
2022-07-14 13:18:50 -03:00
louwie17 39470e9f5c
Fix API triggered tracks not firing (#33872)
* Revert back track property changes to WC_tracks class

* Add changelog
2022-07-14 08:30:03 -03:00
Adrian Duffell a7d34b22aa
Remove query for products type in Shipping Task (#33886) 2022-07-14 17:29:40 +08:00
aezazs-multidots 5093710ad4
Proper commenting of a function (#33823)
* Proper commenting of a function

* Created changelog entry

* change changelog entry
2022-07-14 19:58:39 +12:00
Adrian Duffell 4ab95678ab
Randomize the sections in the recommended marketing extensions (#33851) 2022-07-14 13:41:18 +08:00
Chi-Hsuan Huang 9d6bf48964
Setup Wizard: Fix "Save changes" does not work on "Free features" (#33844)
* Fix "Save changes" does not work on "Free features" step

* Add changelog
2022-07-14 13:38:33 +08:00
Moon cca2df58b4
Add a helper function to simplify ExPlat call in PHP (#33871)
* Add a helper function to simplify explat call

* Add changelog
2022-07-13 19:35:18 -07:00
Moon f2b6321b1b
Apply shipping smart defaults when country is US and Jetpack is installed (#33788)
* Enable shipping smart defaults when store country is US and Jetpack is installed

* Add changelog

* Remove redundant check
2022-07-13 19:34:56 -07:00
Niels Lange e09469c13c
Update WooCommerce Blocks package to 8.0.0 (#33736) 2022-07-14 13:58:51 +12:00
RJ 6af3ea5867
fix: typos in shipping settings (#33836) 2022-07-13 23:41:22 +08:00
Rommel Castro 70ea12eb81
add CLI `wc com extension install` command (#33775)
Co-authored-by: Thilina Hasantha <thilina.hasantha@gmail.com>
2022-07-13 10:34:03 +02:00
Chi-Hsuan Huang db8ea51d76
Set shipping feature flags to true (#33819)
* Set smart shipping feature flags to true

* Add changelog
2022-07-13 16:27:05 +08:00
aezazs-multidots a0a242f6a7
Ordering of CSV Columns of Revenue Table (#33818)
* Ordering of Text Columns of Revenue Table

* Created changelog entry
2022-07-13 10:33:42 +08:00
jonathansadowski 9c242bcc4c
Update github action to require valid changelog file (#33772)
* Update github action to equire valid changelog file

* Update github action for changelogger to install depedencies and composer

* Make valid changelog files that were invalid
2022-07-12 16:07:12 -05:00
jonathansadowski 38296db283
Remove change file for #33722 (#33740) 2022-07-12 16:00:04 -05:00
Fernando 94d545c35f
Product creation experience: improve inventory copy (#33754)
* Change copy `Manage stock level (quantity)`

* Change copy `Limit purchases to 1 item per order`

* Improve inventory copy and add tooltip

* Add changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-07-12 15:42:15 -03:00
Moon 18a4b802ed
Consider WC Admin is disabled when analytics feature is disabled in WC Status widget (#33816)
* Consider WC Admin is disabled when analytics feature is disabled

* Add changelog
2022-07-11 21:15:12 -07:00
Moon 7edec113ef
Use transient to cache Shipping::has_shipping_zones() result (#33813)
* Use transient to cache has_shipping_zones

* Add changelog
2022-07-11 21:14:43 -07:00
Sam Seay c702c66a44
Move all woocommerce-beta-tester release config into woorelease (#33799) 2022-07-12 13:36:05 +12:00
Christopher Allford 3c7f3a7190
Remove WooCommerce 6.7 Changelog Files (#33797)
Removed Changelog File
2022-07-11 10:22:49 -07:00
RJ 5bb03d0188
add: partial spotlight for shipping smart defaults tour (#33801)
- added a dynamic floating div to allow tour kit to track just part of the shipping settings table
2022-07-11 17:17:02 +08:00
Rodrigue a3a5168aea
Remove FB extension from Installed marketing extensions list. (#33781) 2022-07-10 12:10:01 -07:00
Jorge A. Torres 96f2cc30a4
[COT] Implement `delete()` in the COT datastore (#33708)
* `add_meta()` should be more flexible

* Add `delete_order_data_from_custom_order_tables()`

* Add private method `trash_order()` to COT datastore for handling order trashing

* First stab at COT datastore `delete()`

* Delete COT data for orders when deleting its associated post

* Add changelog

* Simplify delete logic

* Minor fixes

* Rework `create()` tests

* Add tests for `delete()`

* Remove unnecessary var
2022-07-08 17:15:10 +05:30
Chi-Hsuan Huang 8952dac7c0
Set up i18n-text-domain rule and fix missing text domain (#33780)
* Set allowedTextDomain to only allow woocommmerce text domain

* Set allowedTextDomain to only allow woocommerce text domain

* Fix wrong or missing i18n text domain

* Add changelog

* Add changelog
2022-07-08 18:37:30 +08:00
Jonathan Lane 537c8c44c7
Couple of Playwright fixes for some flaky tests (#33766)
* Updates to simple product test to reduce flakiness

* Remove focus

* Fix to improve flakiness of order refund test

* Added a wait to help page loads test

* Add a couple more waits to refund tests

* Changelog

* Retry key generation during global setup

* Setup checklist has changed, update

* Update to setup task list

* Add wait for setup checklist

* Update locator for install checklist

* Changelogger: Fix PHPCS violations (#33664)

* Deploy header task variant from task list experiment (#33750)

* Deploy task list experiment 1

* Add changelog

* Fix wrong copy in the payment task (#33749)

* Add headingDescription prop to PaymentGatewaySuggestions list

* Fix payment suggestions heading text

* Add changelog

* Fix missing manage button for TikTok (#33731)

* Fix missing manage button for TikTok

* Add changelog

* Packages: Fix postinstall errors on install (#33724)

* Fix additional payment task name (#33727)

* Rename "Set up additional payment providers" task -> "Set up additional payment options"

* Add changelog

* Remove change files for #33704 (#33734)

* Add shipping class data store (#33765)

* Add initial shipping classes data store

* Add types for the product shipping class store

* Filter out undefined items in list for when an item is deleted

* Add changelog

* Add data store README

* Fix onboarding test

* Skipping flaky test

Co-authored-by: Jon Lane <jon.lane@automattic.com>
Co-authored-by: Paul Sealock <psealock@gmail.com>
Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
Co-authored-by: jonathansadowski <jonathansadowski@users.noreply.github.com>
Co-authored-by: louwie17 <lourensschep@gmail.com>
2022-07-07 14:13:00 -06:00
jonathansadowski 481d61c525
Remove change files for #33704 (#33734) 2022-07-07 10:46:40 -05:00
Chi-Hsuan Huang 44c3ab8f74
Fix additional payment task name (#33727)
* Rename "Set up additional payment providers" task -> "Set up additional payment options"

* Add changelog
2022-07-07 11:33:30 +08:00
Chi-Hsuan Huang b48042b60b
Fix missing manage button for TikTok (#33731)
* Fix missing manage button for TikTok

* Add changelog
2022-07-07 10:14:19 +08:00
Chi-Hsuan Huang 6e21f2c9b4
Fix wrong copy in the payment task (#33749)
* Add headingDescription prop to PaymentGatewaySuggestions list

* Fix payment suggestions heading text

* Add changelog
2022-07-07 10:13:27 +08:00
Chi-Hsuan Huang 9c3118fdf4
Deploy header task variant from task list experiment (#33750)
* Deploy task list experiment 1

* Add changelog
2022-07-07 10:11:14 +08:00
Paul Sealock 7229b65bc9
Changelogger: Fix PHPCS violations (#33664) 2022-07-07 08:54:48 +12:00
Jonathan Lane 0cebdf5277
Convert e2e tests to Playwright (#33462)
* Final updates for Playwright

* Update config

* Add uuid dependency

* Increase retries to 2

* Update selectors on shipping page

* Use baseURL instead of hard-coded URL for API

* Clarify comment

* Use baseURL instead of hard-coded URL

* Check to see if an order was created before attempting to delete it

* Add changelog

* Turn on Playwright tests in GitHub

* Increase timeout for CI execution

* Update configuration options (minor edit)

* Fix for checkout flaky test

* Parse orderId from URL

* Check for substring

* Streamline email tests

* Remove .only

* Only clear email logs of messages for test

* Get orderId from page element

* Fix for test not waiting for reset

* Add in second wait for Performance section

* Change significance from minor to patch

Co-authored-by: Jon Lane <jon.lane@automattic.com>
2022-07-06 14:28:00 -06:00
louwie17 49859c8f84
Fix product variation tooltip (#33741)
* Make sure the default form value tooltip is initialiazed when adding the first variation

* Update copy of default form value tooltip in variations

* Add changelog

* Fix auto formatting

* Add pointer events: none to tooltip to prevent flickering
2022-07-06 13:54:11 -03:00
Ilyas Foo 8d281241a9
Add tracks for shipping smart defaults (#33748)
* Change review shipping task id to 'review-shipping'

* Add click track for shipping-recommendation task from the settings page

* Changelog

* Add test

* Add more specific test param
2022-07-06 20:00:08 +08:00
Moon 74fd45ec16
Add payment icons right next to the Discover other payments link (#33744)
* Add pyament icons

* Add changelog

* Text and logo changes when wc pay is installed and setup

* Use PaymentSuggestions to query plugins

* Make sure image_72x72 exists

* Remove unused namespaces

* Remove stripe2 image -- no longer needed

* Make sure recommended payment is not already active

* Check plugins field to filter out active plugins
2022-07-06 03:24:01 -07:00
Chi-Hsuan Huang b274831334
Update wcpay suggestion UI in payment task (#33717)
* Add WCPayBanner & WCPayBenefits

* Update payment setting & welcome screen to use components from woo onboarding

* Update wcpay suggestion UI in payment task

* Add changelog

* Add WCPayBannerImageCut image and update wcpay banner style

* Update packages/js/onboarding/src/components/WCPayBanner/WCPayBanner.scss

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

* Set .woocommerce-recommended-payments-banner__image_container display: flex

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2022-07-06 14:20:11 +08:00
Moon 9b175c64d9
Make store location and rates steps clickable (#33661)
* Make store location and rates clickable

* Add changelog

* Make store_location_completed camelCase

* Fix onCompleteStep logic

* Update plugins/woocommerce-admin/client/tasks/fills/shipping/index.js

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-07-05 19:13:57 -07:00
Moon 7c723583cb
Add tests for react admin translations (#33510)
* Add switch-language endpoint

* Add translation tests for PHP, react client, and component

* Fix component test

* Add Changelog

* Add Changelog
2022-07-05 17:16:15 -07:00
Christopher Allford 0a2588f6c4
Fixed WooCommerce Beta Tester Zip Build (#33728) 2022-07-06 11:28:56 +12:00
Joel Thiessen 57869a2ab7
Fixing activity panel does not appear after navigating to OBW and back (#33722) 2022-07-05 10:02:46 -07:00
Fernando f9f42ce3c2
Rename event prop from `cross-sell` to `cross_sell` (#33704)
* Rename event prop from `cross-sell` to `cross_sell`

* Added validation to `WC_Tracks_Event::validate_and_sanitize`

* Remove extra tab

* Remove `error_log

* Fix WP_Error message

* Add changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-07-05 10:38:29 -03:00
Chi-Hsuan Huang 97f3e2d609
Fix untranslated texts on payment setting page (#33718)
Fix untranslated string in payment setting page
2022-07-05 13:28:31 +08:00
RJ b7ffa1c3d2
Add: Intro tooltips for shipping smart defaults (#33688)
add: intro tooltips for shipping smart defaults

- removed php code for setting 'reviewed' option as it was being set on page load and thus always evaluated to true before the user sees it
- added intro tooltips
2022-07-05 13:02:52 +08:00
Noonan Web Group Limited 538403306c
Update wp-background-process.php to use wp_convert_hr_to_bytes() (#30908)
Update wp-background-process.php to use wp_convert_hr_to_bytes()

Currently the code is typecasting the memory limit to an int. This assumes that the memory limit is in MB, so if you set your memory limit to 4G this will return 4194304 bytes (4.19304 MB.) Instead, we should use the native WordPress function `wp_convert_hr_to_bytes` to handle the conversion into bytes correctly.
2022-07-04 19:23:52 -07:00
Luigi Pulcini 9cecce207a
Add exporter instance parameter to `woocommerce_product_export_row_data` filter (#33390)
Added exporter instance parameter

* added filter docblock and changelog entry
* Tweak changelog, tweak hook version number

Co-authored-by: Luigi Pulcini <luigi@barn2.com>
Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-07-04 19:22:13 -07:00
Chi-Hsuan Huang e471d7ce71
Update store details task action url (#33671)
* Update StoreDetails task action url to navigate to the setting page

* Add changelog

* Update complete logic of StoreDetails task

* Update store details unit tests for new task completion logic
2022-07-05 10:10:36 +08:00
Chi-Hsuan Huang da38571824
Fix wrong link and copy in payment setting page (#33716)
* Fix wrong link and copy in payment setting page

* Add changelog
2022-07-05 10:10:09 +08:00
Chi-Hsuan Huang 20b266743e
Fix wrong link in setup payments screen (#33715)
* Fix wrong link in Set up payments screen

* Add changelog
2022-07-05 09:00:12 +08:00
Luigi Pulcini 63dd5eda6f
Added mechanism to customize data before AJAX requests in `meta-boxes-order.js` (#33563)
Added `triggerHandler` before each ajax request.

* Added namespace to event name
* Linting.

Co-authored-by: Luigi Pulcini <luigi@barn2.com>
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-07-04 17:09:13 -07:00
Jorge A. Torres bddb6621ee
[COT] Implement order bulk actions (#33687)
Introduce `Admin\Orders\PageController` to manage admin pages for orders

* Change orders menu registration & initialization to use `Admin\Orders\PageController`
* Implement bulk actions in orders ListTable
* Unnecessary import
* Make PHPCS happy
* Add changelog
* Address feedback
2022-07-04 16:57:01 -07:00
Joel Thiessen 6c13fdf0ce
Making product image meta box more prominent as a default (#33707) 2022-07-04 11:55:18 -07:00
Chi-Hsuan Huang 4707dcbec0
Fix wrong copy in the payments settings for a country that WCPay is not supported (#33665)
* Fix wrong copy in payment recommendations

* Add changelog
2022-07-04 16:58:10 +08:00
Moon 76f9a1fc57
Fix export functionality on Analytic pages (#33709)
* Import correct controls

* Add changelog

* Add changelog
2022-07-04 12:55:39 +08:00
Moon 6a8f124022
Fix Uncaught DOMException on WooCommerce -> Extensions page. (#33711)
* Add .commerce to wrap selector

* Add changelog

* More specific selector

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2022-07-04 12:41:32 +08:00
Ilyas Foo dea22904e0
Fix marketing task completion logic (#33676)
* Add marketing action task on clicking Manage

* Revert marketing completion after installing any marketing plugin

* Changelog
2022-07-01 14:28:45 -07:00
Corey McKrill d15770132b
Revert "Update method for getting Reports API cache version number" (#33706)
This reverts commit bccc80366d.

When we merged this PR, we thought the Woo mobile apps would have enough time to implement some corresponding changes on their side. That turned out not to be the case. Without the ability to force a refresh of the analytics cache, this PR causes the apps to have a greater risk of showing users stale analytics data that they can’t immediately update.
2022-07-01 12:28:30 -07:00
Chi-Hsuan Huang f1ce6ec30c
Update WCPay to include a mention of in-person payments for Canada (#33669)
* Update wcpay to include a mention of in-person payments for Canada

* Add changelog
2022-07-01 13:51:54 +08:00
Moon f8e8b6ff04
Style fix for the print shipping banner close modal (#33587)
* Style fix for the close modal

* Add changelog
2022-06-30 14:05:00 -07:00
Matthew Hodge 6cb6fd02df
Added a filter to set fopen mode for streams that dont support a+ (#33652)
Added a filter to set fopen mode for streams that dont support a+

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-06-30 10:34:02 -07:00
AnnaMag 3fc11126a4
Include Tracks indicator property for block editor on product update. (#33321)
* Include Tracks property indicating block editor on product update.

* Add changelog

* In a block editor the Update button does not have the selector.

* Remove - from Tracks even property.

* Refine a condition of a non-empty object.

* Incorporate feedback: add callback for rendering the Update button.

* Add recent feedback- jQuery way of handling post render execution.

* Remove `console.log

* Fix `product_update` event recording

* Removed `hasRecordedEvent` and fixed `description validation

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-06-30 11:48:21 +02:00
Chi-Hsuan Huang 41ecb1ed6f
Fix wrong copy in the payments task on the Home Task list (#33663)
* Fix wrong copy in the payments task on the Home Task list

* Add changelog
2022-06-30 15:23:03 +08:00
Ilyas Foo d6ccaa67de
Shipping recommendation task set location step manual navigation (#33667)
* Adds capability for store location step to be manually navigated

* Add test

* Changelog
2022-06-30 14:45:52 +08:00
Chi-Hsuan Huang 2dc3d87e1c
Payment task: fix wrong copy in the accordion link (#33662)
* Fix wrong copy in the accordion link for payment task

* Add changelog
2022-06-30 12:20:23 +08:00
Tam Mullen def11b77d9
Update daily smoke test to add k6 smoke tests (#33658)
* Add k6 test scenario to the daily smoke test action.

* Add blank patch changelog for daily smoke update
2022-06-29 16:01:37 -06:00
Jorge A. Torres a80e0fe203
[COT] Implement create() method in COT datastore (#33341) 2022-06-29 08:54:29 -03:00
Moon feb3ab0581
Update shipping logic when OBW is skipped (#33630)
* Update shipping task fields when shipping smart default feature is enabled.

* Always display the shipping task regardless of having a physical product

* Updated text copy for the fields

* Do not display the step description if it is not the current step

* Added a banner for the shipping printing step

Remove description if the it is not the current step

* Add changelog

* Fix namespace conflict after the rebase

* Re-use wcs banner from the experimental shipping recommendation

* Delete ShippingLabelPrinting -- replaced by wcs banner from experimental-shipping-recommendation

* Add TOS link

* Remove ShippingPrintLabel styles -- no longer needed

* Minor refactor

* Move description set logic to getSteps()

* Use map to override step fields

* Remove unnecessary feature check

* Remove description in the map func

* Render ShipStation banner if plugins includes woocommerce-shipstation-integration
2022-06-29 00:40:42 -07:00
Chi-Hsuan Huang 88a66e6983
Update review shipping options task complete logic (#33650)
* Update review shipping options task complete logic

* Add changelog
2022-06-29 15:34:09 +08:00
Chi-Hsuan Huang 2e167ca088
Fix borken react admin commands (#33649)
* Fix admin build:packages and test:packages

* Add changelog
2022-06-29 13:02:56 +08:00
Ilyas Foo 1daa1c07fe
Add tests for shipping recommendation task (#33633)
* Move redirect function to utils to easily mock

* Add test

* Changelog
2022-06-29 11:24:25 +08:00
Christopher Allford 2e87b32034
Removed WooCommerce 6.7 Changelog Files (#33643)
Removed Changelog Files
2022-06-28 13:22:18 -07:00
jonathansadowski d48a0b2d90
Add helper tool for making sure build, lint, and test are run through Turborepo (#33573)
* Add helper tool for making sure build, lint, and test are run through Turborepo

* Update node version for require-turbo
2022-06-28 13:17:05 -05:00
Roy Ho 98cf4e7160
Add PR numbers to changelog entries on code freeze process (#33627)
* Add PR numbers to changelog entries on code freeze process

* Add markdown links to PR
2022-06-28 11:15:39 -07:00
Joshua T Flowers 0a5b912288
Move tracks _ui and _ut properties out of filtered tracks properties (#33621)
* Move tracks _ui and _ut properties out of filtered tracks properties

* Add tests around tracks properties

* Fix broken variable name

* Add changelog entry
2022-06-28 09:43:17 -04:00
Ilyas Foo b178e8a1f6
Add new flow shipping recommendation task (#33620)
* Plugins component skip button is now optional

* Add link from payment settings page

* Add new experimental shipping task flow

* Changelog

* Update plugins/woocommerce/src/Admin/Features/OnboardingTasks/Tasks/ExperimentalShippingRecommendation.php

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>

* Rename all tracks to shipping_recommendation

* Add back skip installer bind

* Pass plugins list to pluginSlugs to be more predictable

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-06-28 13:53:03 +08:00
Moon e9006b56df
Add logic to set the default shipping options on homescreen (#33547)
* Add logic to set the default shipping options

* Set the flat rate cost to 15 (temp cost)

* Add changelog

* Update plugins/woocommerce/src/Internal/Admin/Homescreen.php

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>

* Run the changes only if shipping-smart-defaults is enabled

* Assume user is going to sell physical products if obw is skipped or the store details has not been completed

* Make sure store country is set by an actual user by checking the value of woocommerce_store_addres

* Remove flat late logic

* Use woocommerce_store_address. store_address is always empty

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-06-27 20:23:13 -07:00
Chi-Hsuan Huang 5eea5ab072
Fix shipping display logic United Kingdom country code (#33629)
* Fix shipping display logic country code UK -> GB

* Add changelog
2022-06-28 11:15:01 +08:00
Roy Ho 14066bdeae
Add phpcs-changed (#33584)
* Add phpcs-changed

* Put report flag value in quotes

* Use phpcs action workflow instead

* Remove no longer used phpcs script

* Remove phpcs ignore rule

* Use proper name for code sniffer step
2022-06-27 11:46:29 -07:00
Pierre Carrier 10e1e62b8e
class-wc-geolocation.php: hide blog URL from third-party providers (#31941)
* includes/class-wc-geolocation.php: hide URL.
* Add changelog.
* Make phpcs happy.

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-06-24 17:34:29 -03:00
Dekadinious 2c721c7c88
Fixes issue #33335 (#33431)
* Fixes issue #33335

Check for an empty string instead of an empty variable.

* Update wc-product-functions.php

* Update wc-product-functions.php

* Changelog

* Fix cases when $term is false or empty array

Co-authored-by: Peter Fabian <peter.fabian.github@gmail.com>
2022-06-24 17:48:17 +02:00
RJ d2967e0ee8
Fixed missing wcpay setup task (#33590)
- task fill page was missing for the woocommerce-payments task
2022-06-24 17:06:43 +08:00
RJ 54b72dcae1
Fix: improve woocommerce-admin plugin deactivation notice message (#33592)
* Fix: improve wca deactivation notice message

* Update plugins/woocommerce/src/Internal/Admin/Loader.php

Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com>

Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com>
2022-06-24 17:00:42 +08:00
RJ c9e0cccc19
fix payments banner experiment test (#33589)
test needed to be updated as the component did not call useExperiment directly anymore
2022-06-24 13:06:11 +08:00
Chi-Hsuan Huang 417b694e1e
Fix local site url in woocommerce readme (#33579)
* Fix local wp site url in woocommerce/README.md

* Add changelog
2022-06-24 09:32:27 +08:00
Chi-Hsuan Huang 49b07dd9a8
Update shipping task display logic (#33533)
* Update display shipping task logic

* Add changelog

* Update ReviewShippingOptions.php

* Update ReviewShippingOptions.php

* Update ReviewShippingOptions.php

* Update shipping task display logic

* Add doc comments for can_view

* Update comment

* Update shipping task display logic to prevent showing two task simultaneously
2022-06-23 15:56:19 +08:00
Chi-Hsuan Huang 93c15e9f7d
Switch to ESLint to fix admin lint command (#33577)
* Switch woo admin lint command from wp-script to eslint

* Add changelog
2022-06-23 12:00:28 +08:00
Chi-Hsuan Huang dcbae453f8
Update shipping recommendations display logic (#33529)
* Update shipping recommendations display logic

* Add todo comment

* Add changelog

* Render null for shipping recommendations if store only sells digital products

* Fix onboarding product type

* Update plugins/woocommerce-admin/client/shipping/test/experimental-shipping-recommendations.tsx

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>

Co-authored-by: Ilyas Foo <foo.ilyas@gmail.com>
2022-06-23 09:54:38 +08:00
nigeljamesstevenson 77a93cc7ad
Update e2e README port number, remove Nx install PreRequisite steps (#33558)
Update e2e README port number, remove Nx install
2022-06-22 19:00:28 -06:00
Ilyas Foo 9c4c3834a7
Fix payments settings banner experiment logic (#33549)
* Delegate payment experiment logic into its own hook and rearrange the checking logic to be before the experiment is called

* Changelog
2022-06-22 16:45:31 +08:00
David Stone c8cb9877a2
Show generic error when trying to process a checkout while offline (#30860)
Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-06-21 17:02:14 -03:00
Paul Sealock a80462d594
Beta Tester: Prep for release (#33463) 2022-06-22 07:26:15 +12:00
Christopher Allford f6e065026e
Fixed Unit Test Suite (#33543)
This commit adds a missing `"test"` command
to the WooCommerce `package.json` file.
2022-06-21 12:11:43 -07:00
Johan de Jong ca524a7266
Add sort method to hide hidden columns in products sortable (#31866)
Co-authored-by: Jorge Torres <jorge@0xbad.com>
2022-06-21 15:26:43 -03:00
Mathias Reker ⚡️ ef8cf9f460
Ordered interfaces (#33488)
Orders the interfaces in an implements or interface extends clause.
2022-06-21 17:42:39 +02:00
David Marín 9095b65d0e
Add $transaction_id to payment_complete hooks (#28930)
Add $transaction_id to payment_complete hooks

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-06-21 11:21:26 -03:00
Michael P. Pfeiffer 958d083600
Fix broken design of Single Product template in block themes and on-sale badge being partially hidden (#33511)
* Fix broken design of Single Product template in block themes and on sale badge being partially hidden

* Update changelog to mention Twenty Twenty-Two explicitly.

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
2022-06-21 16:26:40 +05:30
Néstor Soriano 3b089f97dc
[PHP 8.1] Fix code that throws deprecation notices in tests in PHP 8.1 (#31333)
* Fix phpcs errors and warnings

* Fix code that throw deprecation notices in PHP 8.1

The deprecation notices are about:
- Various "passing null to parameter (...) is deprecated"
- Usage of strftime
- Using "false" as if it was an empty array
- Mismatching return type of implemented interfaces,
  that's fixed by adding #[\ReturnTypeWillChange]

* Fix some more code that throw deprecation notices in PHP 8.1

* Small commenting/formatting fixes.

* Add changelog file

* Formatting.

Co-authored-by: Peter Fabian <peter.fabian.github@gmail.com>
2022-06-21 12:16:44 +02:00
Chi-Hsuan Huang e412d5912b
Migrate `@woocommerce/data` item store to TS (#33482)
Migrate item store to TS
2022-06-21 16:46:30 +08:00
Chi-Hsuan Huang 7068c78101
Fix JS lint errors (#33484)
* Fix @woocommerce/data lint errors

* Fix internal-e2e-builds lint error

* Fix lint errors
2022-06-21 16:37:34 +08:00
Chi-Hsuan Huang 8825e06e46
Fix feature flags (#33532) 2022-06-21 15:48:30 +08:00
Chi-Hsuan Huang 420ed1e81f
Add shipping-smart-defaults and shipping-setting-tour feature flags (#33531)
* Add shipping-smart-defaults and shipping-setting-tour feature flags

* Add changelog
2022-06-21 14:24:47 +08:00
Luigi Teschio a53b44f6ef
Update WooCommerce Blocks package to 7.8.3 (#33514) 2022-06-20 16:34:29 -03:00
Brian 820963d450
Adjust DKK Currency Symbol (#33509)
Update Danish currency symbol per CLDR R41.
2022-06-20 10:34:42 -07:00
Kamil cea8aaf53d
Remove legacy image sizes which were planned for removal into 4.6.0 (#32709) 2022-06-20 12:00:33 +02:00
saboanca 5948858476
Add extra hook in email setup_locale and restore_locale functions. (#33254) 2022-06-20 11:40:33 +02:00
Dharmesh Patel 3abb3dfa8e
Added local pickup handling in `get_tax_location()`. (#33330) 2022-06-20 11:29:11 +02:00
Vedanshu Jain 87ccf73da7
Convert null and '' to 0 before verification. (#33453)
During migration $wpdb->prepare would force null and empty values to be zero for %f placeholder. This was causing verification logic to fail, which is being addressed in this commit.

The alternative was to insert null values without running them via $wpdb->prepare, but that seemed less safer than converting to zero because it would have to done manually since $wpdb->prepare wouldn't support it.
2022-06-20 09:43:10 +02:00
Christopher Allford 71456382c4
Add Client Components Documentation To WooCommerce Core (#33507)
This commit adds documentation for WooCommerce's client component commands. This should make it easier to know what commands to run to work in these components.
2022-06-17 15:32:29 -07:00
Christopher Allford c0b76f70cc
Rename @woocommerce/admin-library (#33460)
This commit changes it to woocommerce/client/admin. This is an invalid NPM package name and an invalid Composer package name. This will prevent conflicts but also identify it as a component of Core.
2022-06-17 13:28:34 -07:00
Christopher Allford dc2c3449b2
Prepare `trunk` For WooCommerce 6.8 (#33506)
This bumps the version of WooCommerce to 6.8 and removes all of the changelog files from WooCommerce 6.7.
2022-06-17 13:05:31 -07:00
Chi-Hsuan Huang 244387f5d8
Add playwright e2e README.md (#33470)
* Add playwright e2e README.md

* jest -> Playwright

* Add changelog
2022-06-17 09:50:54 -07:00
Moon 8bed87d91e
Fix Admin performance with a large # of zipcodes (#33422)
* Uses WC_Data_Store directly to count the shipping zones to avoid any unncessary query to the D.B

* Add changelog
2022-06-16 13:52:30 -07:00
Moon dc70bdfae4
Remove two-col task list experiments (#33426)
* Remove two-col task list experiments

* Add changelog
2022-06-16 13:51:46 -07:00
jonathansadowski 626a409e83
Release automation: generate changelog during code freeze (#33046)
* Update code freeze script to generate changelog PRs

* Add changelog file

Co-authored-by: jonathan <jonathan@jonathans-MacBook-Pro.local>
2022-06-16 14:44:07 -05:00
Christopher Allford 5175a6820b
Rename woocommerce-legacy-assets (#33461)
In line with the fact that it's a component of WooCommerce rather than a standalone package, `woocommerce-legacy-assets` has been renamed `woocommerce/client/legacy`.
2022-06-16 11:53:48 -07:00
Heba Fareed 0893217227
Fix $item->product condition in coupons validation (#28754)
Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-06-16 11:44:12 -03:00
Jorge A. Torres 6627fdb5ed
[redux] Coerce variable type of form field argument 'class' in woocommerce_form_field() (#33454)
Co-authored-by: hahn208 <208hahn@gmail.com>
2022-06-16 10:35:22 -03:00
RJ a78670bfec
Updated @automattic/tour-kit to 1.1.1 which has live resize functionality (#33452) 2022-06-16 15:49:03 +08:00
Chi-Hsuan Huang ea194237a3
Fix product tour TypeError when reading innerHTML (#33448)
* Fix product tour TypeError when reading innerHTML

* Add changelog
2022-06-16 14:02:28 +08:00
Ilyas Foo ced9207a5d
Remove obselete experiment calls (#33449)
* Remove woocommerce_test_experiment

* Remove woocommerce_tasklist_progression
2022-06-16 13:06:08 +08:00
Christopher Allford 6d0fc0d6ac
Expand Repository Development Documentation (#33423)
This commit reworks some of the documentation in the monorepo to better represent how to get started and develop projects in it.
2022-06-15 21:55:25 -07:00
AnnaMag 65cd33bee8
Settings: fix Tracks event when enabling/disabling advanced features settings. (#33305)
* Trigger the hook that record the track events
once the option settings are updated:navigation and analytics. Tracks do not include yes/no properties, so we record the latter as _disabled.

* Changelog

* Prevent reloading of page immediately after feature updates

* Remove feature specific code in tracks class

Co-authored-by: Joshua Flowers <joshuatf@gmail.com>
2022-06-15 14:58:49 -05:00
Corey McKrill bccc80366d
Update method for getting Reports API cache version number (#33353)
* Changes the frequency at which the Reports API cache can be invalidated via the cache version number to be at most once every 10 minutes, instead of with every change to the store.
* Changes the TTL of Reports API cache entries so that they expire after an hour instead of after a week.

The goal of these changes is to increase the chance that a request to the Reports API for store stats will result in a cache hit, thus avoiding expensive, slow queries. The reason for lowering the TTL is so that if multiple store changes are made within the new 10-minute frequency window, the cache data will only be stale for up to an hour. With #33325 users will be able to refresh entries in the cache manually if they think something is stale.

Closes #33315
2022-06-15 11:40:05 -07:00
Jorge A. Torres f0b9adc7ae
Make sure payment gateway title is a string before sanitizing (#33434)
Make sure payment gateway title is a string before sanitizing.

* Add changelog
* Drop type-hint in `validate_safe_text_field()`
* Update plugins/woocommerce/includes/abstracts/abstract-wc-settings-api.php

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-06-15 10:49:11 -07:00
Joshua T Flowers 35a4d1ca32
Clean up unused remote inbox notifications option (#33373)
* Clean up unused remote inbox notifications option

* Add changelog entry

* Add comments to existing action hooks
2022-06-15 08:03:36 -04:00
Jorge A. Torres 4b63f34841
[COT] Implement metadata CRUD and `update()` method in COT datastore (#33026)
* Add `OrdersTableDataStoreMeta` to handle metadata for orders

* Add `OrdersTableDataStoreHelper` with various helper functions used in the COT datastore

* Pass some helper classes as args to the COT datastore

* Use `OrdersTableDataStoreMeta` for meta in COT datastore

* Minor fixes to columns definition in COT datastore

* First pass at update() in the COT datastore

* PHPCS fixes

* Remove duplicate `read_meta` calls.

* Register `OrdersTableDataStore` earlier to make container happy

* Do not hardcode table metadata in `OrdersTableDataStoreMeta`

* Correctly format decimals for storing in the db

* read() shouldn’t success on non-existing orders

* Rework persisting to db in OrdersTableDataStore

* Correctly handle some props in OrdersTableDataStore

* Add changelog

* Add missing TODOs

* Remove unused variables

* No need to query db before deleting meta in `OrdersTableDataStoreMeta`

* Simplify OrdersTableDataStoreMeta::update_meta()

* Explicitly enumerate columns in OrdersTableDataStoreMeta::get_metadata_by_id()

* Make COT metadata implementation more generic

* Do not use property_exists() to determine existence of meta value

* Move some methods over to DatabaseUtil and get rid of COT datastore helper

* Rename `CustomDataStoreMeta` to `CustomMetaDataStore`

* Make PHPCS happy

* Add unit test.

* Correct arg passed to persist_order_to_db()

* Remove comment

* Split conditional on multiple lines

Co-authored-by: vedanshujain <vedanshu.jain.2012@gmail.com>
2022-06-15 14:09:41 +05:30
Ilyas Foo 090822eabf
Update product task experiment names (#33428)
* Update product task experiment names

* Changelog

* Fix lint
2022-06-15 16:34:24 +08:00
Niels Lange c33d7cc632
Correct CLIRunner translations (#33247)
* Correct CLIRunner translations

* Adjust placeholder formats and translator comments

* Add changelog.

Co-authored-by: vedanshujain <vedanshu.jain.2012@gmail.com>
2022-06-15 12:54:39 +05:30
Chi-Hsuan Huang aac85ac301
Turn on experimental-product-tour feature flag (#33413)
* Turn on experimental-product-tour feature flag

* Add changelog
2022-06-15 09:50:37 +08:00
Corey McKrill 12cbb87e80
Add cache refreshing/debugging mechanisms to Report API endpoints (#33325)
Adds a new collection parameter to all Reports API endpoints that utilize caching, `force_cache_refresh`, which will cause the current request to bypass the cache, re-run the queries for the requested data, and overwrite the previous cache entry with the new results.

Note that this doesn't invalidate the entire cache, only the entry for the particular set of collection parameters and values specified in the request.

This also adds a way to include debugging information related to the cache in the API response. Modeled after the way the Query Monitor plugin adds such information, you can get this by including an `_envelope` parameter in your API request. The debugging info includes whether the cache has been disabled via filter (`should_use_cache`), whether the `force_cache_refresh` parameter was used, whether the returned data was a `cache_hit` or not, and an array of the query parameters that were actually used to create the cache key.

Closes #33221
2022-06-14 14:24:31 -07:00
Paul Sealock dc2977cea3
Merge pull request #33329 from woocommerce/add/admin-tester
Add WooCommerce Admin Test Helper
2022-06-15 07:31:21 +12:00
jonathansadowski 4ec3bef590
Update the changelog.txt and the stable tag in readme.txt for 6.6.0 (#33419) 2022-06-14 14:14:27 -05:00
Joel Thiessen 183ac65c82
Adding context property to tasklist tracks event, introducing LayoutContext (#33287) 2022-06-14 11:31:50 -07:00
Daniel Morell 143d86490d
Generalize photoswipe button event target (#27804)
* Generalize photoswipe button event target

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-06-14 15:05:43 -03:00
jonathansadowski 277fd78bca
Sync payment gateway titles fix (#33418)
* Introduce a 'safe_text' field that allows a reduced subset of HTML tags.

* Escape on input as well as output; generalize sanitization function.

* Set reasonable default rules.

* Guard against invalid callbacks (escaping/sanitizing) functions.

* Update plugins/woocommerce/src/Internal/Utilities/HtmlSanitizer.php

Co-authored-by: Peter Fabian <peter.fabian.github@gmail.com>

* Allow alt (accessibility) for img tags; allow class attributes for img and span tags.

* Allow class attr for p tags.

* Use safe_text for payment gateway titles.

* Make HtmlSanitizer available through Utils service provider.

* Update settings code to pull HtmlSanitizer as a service and to use the new sanitize() method.

* Remove `style` from list of allowed attributes.

Allowing arbitrary CSS rules through style could undo the intent of this change, since that would allow a range of positioning and sizing changes to be effected.

* Remove unusued import.

* If no (KSES) rules are specifed, then strip all tags (this is a safer default strategy).

* For better safety, only apply pre-processor callbacks; remove responsibility for trimming of strings.

Applying callbacks to a string after it ahs passed through wp_kses() could (potentially) undo the work done by that function, and result in unexpected tags in the sanitizer's output.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
Co-authored-by: Peter Fabian <peter.fabian.github@gmail.com>
2022-06-14 12:31:27 -05:00
Luigi Teschio 84ecebdad2
Update WooCommerce Blocks package to 7.8.0 (#33338)
* Update WooCommerce Blocks package to 7.8.1

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
2022-06-14 11:24:41 -03:00
Ilyas Foo 27041efdc5
Add event tracking product page spotlight tour (#33400)
* Update WooStep to have name in meta

* Add useProductStepChange hook and use it to detect form value changes in product tourkit, added tracking for tour view, tour dismiss, tour complete, and step complete

* Add tour view, tour dismiss, tour completion track to old product walkthrough

* Changelog

* Fix test

* Add listener to publish button for product spotlight tour

* Add track for old walkthrough publish button
2022-06-14 16:19:32 +08:00
Chi-Hsuan Huang 94367ca559
Migrate `@woocommerce/data` onboarding store to TS (#33401)
* Migrate onboarding data store to TS

* Update deprecated-tasks.tsx type annotations

* Fix onboarding resolvers
2022-06-14 10:23:40 +08:00
Chi-Hsuan Huang 257e558530
Update product template descriptions (#33397)
* Update product template descriptions

* Add changelog
2022-06-14 10:22:57 +08:00
Chi-Hsuan Huang 8fb9664b7a
Fix product tour spotlight location (#33395) 2022-06-14 10:22:43 +08:00
Vedanshu Jain 3fd9ee99aa
Fix typos COT verification messages. (#33207)
* Fix typos in migration error messages.
2022-06-13 16:08:57 -03:00
mrleemon 22721e6a28
Fix typos in CLIRunner.php (#33231)
Fix typos in CLIRunner.php

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-06-13 11:30:24 -07:00
Adrian Duffell 1e03b68598
Update onboarding email marketing checkbox default to false (#33292) 2022-06-13 09:55:57 +08:00
Paul Sealock 0efd480581 merge conflicts 2022-06-13 12:47:00 +12:00
Paul Sealock b166d45986
WooCommerce Plugin: Update Webpack to 5.x (#33354) 2022-06-13 09:09:23 +12:00
Joshua T Flowers 935f915cb5
Update scrollbar hover styles in new navigation (#33313)
* Update scrollbar hover styles in new navigation

* Update contrast ratio

* Add Firefox scrollbar properties

* Fix scrollbar-color and scrollbar-width values

Co-authored-by: Matt Sherman <matt@jam123.com>
2022-06-10 12:24:02 -04:00
Kathy 483d62f1cc
follow up to #33182 swap .woocommerce-info and .woocommerce-message colors in twenty twenty (#33377)
* swap .woocommerce-info and .woocommerce-message colors in twenty twenty
2022-06-10 15:38:31 +02:00
Kathy 19bea3832e
First pass: Twenty Twenty One notice styles. Closes #29560. (#33379) 2022-06-10 11:37:06 +02:00
Adp5067 4c164c3247
Make the option 'woocommerce_tracker_ua' load on demand. (#33274) 2022-06-10 08:55:10 +02:00
Chi-Hsuan Huang 558e5e322e
Fix continue button is enabled when email is null in setup wizard (#33362)
* Fix continue button is enabled even when email is null in setup wizard

* Add changelog
2022-06-10 10:35:11 +08:00
Paul Sealock 4fa634ee0e merge changes 2022-06-10 12:26:26 +12:00
Paul Sealock 5054105972 try manual rebase conflict fix 2022-06-10 12:21:48 +12:00
Christopher Allford b7931409f2
Migrate From Nx to Turborepo (#33079)
This replaces all `nx` commands with `turbo` commands and removes Nx from the repository. All of the `project.json` files have been removed and any commands that broke with Turborepo have been adjusted.
2022-06-09 14:40:07 -07:00
Chi-Hsuan Huang a3d42be6b0
Fix setup wizard click button loading state (#33358)
* Fix setup wizard usage button loading state

* Add e2e tests for usage button loading state
2022-06-09 17:30:06 +08:00
Sakri Koskimies e80312eef0
Change attribute slug length requirement and add wc_create_attribute tests (#31795)
* Allow for 28-character attribute slugs
* Add wc_create_attribute tests
2022-06-09 10:51:38 +02:00
Ilyas Foo e3744709c7
Wrap product spotlight tour under ExPlat logic (#33361)
* Add experiment wrap

* Changelog

* Move experiment check to bottom to minimize explat calls
2022-06-09 16:21:28 +08:00
Néstor Soriano fe267f355e
Add a new ArrayUtil::select method (#33347)
This new method is syntactic sugar for array_map. It scans an array
of arrays and/or objects and selects one value from each using
an array key name, an object method, or an object property.
2022-06-09 08:40:40 +02:00
Néstor Soriano e822b97619
[COT] Add database transactions support for data synchronization (#33255)
* Add optional usage of database transactions for orders sync.

Includes a new setting in Advanced - Custom data stores to enable
or disable transactions usage and to select the transaction
isolation level.

* Improve the selection of data to be updated when syncing orders.

The SQL query that chooses records to be migrated to core tables
now explicitly excludes unchanged records based on the column mappings.

Also when syncing meta tables with single meta values, records for
which the value hasn't changed are now excluded from the update.

* Fix MetaToCustomTableMigrator to work with order addresses table.

* Add unit tests for db transactions on PostsToOrdersMigrationController

Also add the DynamicDecorator::call_original_method method
2022-06-09 08:39:56 +02:00
Chi-Hsuan Huang 04a763d389
Add product page spotlight tour (#33268)
* Add product-tour admin script

* Update class-wc-admin-pointers.php to show experimental product tour

* Remove unnecessary window.onload

* Replace add new button with Enable guided mode button for product editing

* Show tour when tutorial query = true

* Add logic to show new tour only when a user select the physical product template

* Update product tour last step button text

* Add auto-scroll effect

* Fix i18n text

* Use bottom-start placement and align the arrow to the left

* Update pnpm-lock.yaml

* Update product tour effects

* Add changelog

* Add doc comments & check for tour-kit

* Add focus elements to product tour and wait initial element for tour showup

* Use spotlight query param to toggle new product tour feature

* Update wait seconds

* Update border style for product description & short description when editor is focused

* Add experimental-product-tour feature flag

* Refactor product-tour and support html editor focus style

Co-authored-by: moon <moon.kyong@automattic.com>
2022-06-09 13:02:40 +08:00
Chi-Hsuan Huang 6858195510
Update webpack.config.js to ensure we use styles from build-style (#33357)
* Update webpack.config.js to ensure we use styles from build-style

* Add changelog
2022-06-09 10:45:36 +08:00
jonathansadowski 21e6eea3cc
Update ActionScheduler to 3.4.2 (#33351) 2022-06-08 14:23:57 -05:00
Chi-Hsuan Huang 5db5c8b110
Add tour kit component (#33229)
* Add tour-kit component

* Add @types/wordpress__viewport to @woocommerce/components devDeps

* Add tour-kit README.md

* Add primaryButtonText option to tour kit step meta

* Add changelog

* Remove unneeded style import

* Set position and z-index style for tour-kit

* Add disable primary button feature for tour kit

* Export TourKitTypes

* Update style-build config for @automattic/* packages

* Add @automattic/* deps for components

* Ignore fs in webpack.config.js

* Update tour-kit stories

* Add tour-kit tests

* Update tour-kit README.md

* Update tour-kit types

* Update webpack.config.js

* Update style.scss

* Add auto focus feature

* Update type doc
2022-06-08 17:16:31 +08:00
Paul Sealock ce796e1cd7 build zip for release 2022-06-08 14:14:45 +12:00
Paul Sealock 734cfebd8c Clean up eslintrc in favour of defaults 2022-06-08 14:03:16 +12:00
Paul Sealock 1aec706943 Run linter on all js files 2022-06-08 13:58:25 +12:00
Paul Sealock bab0bf8298 Run lint:fix on js 2022-06-08 13:39:59 +12:00
Chi-Hsuan Huang 62313708aa
Add `tasklist_cancel_load_sample_products_click` event track for product task (#33327)
* Add tasklist_cancel_load_sample_products_click event track for product task

* Add changelog
2022-06-08 09:39:14 +08:00
Paul Sealock 8a30e307b6 changelog 2022-06-08 13:33:59 +12:00
Paul Sealock 2dce7b5bba Remove duplicated src folder/ 2022-06-08 13:31:16 +12:00
Paul Sealock 979fa45627 downgrade to @wordpress/scripts 19.2.4 2022-06-08 09:14:50 +12:00
Néstor Soriano 6aa4b5cdae
Fix: error when creating products via REST API v1 (#33334)
* Fix root namespace indicator in parameter

For LookupDataStore::on_product_created_or_updated_via_rest_api.
This was preventing the v1 REST API endpoint for batch insert of
products from working.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-06-07 10:51:17 -07:00
jonathansadowski eba6df8299
Fix warning on WC Pay subscriptions page with unset submenu item (#33339)
* Fix warning on WC Pay subscriptions page with unset submenu item

* Add isset check before iterating over submenu in task list
2022-06-07 12:50:34 -05:00
Jorge A. Torres c3f7687feb
Add charset collation to COT database schema (#33210) 2022-06-07 16:45:00 +02:00
Chi-Hsuan Huang a2813267eb
Fix script version parameter for async chunks (#33332)
* Fix webpack script version parameter for JS chunks
* Fix webpack script version parameter for CSS chunks
2022-06-07 21:35:04 +08:00
Barry Hughes 1bca9327ac
Fixes for the WP CLI Updater (#33264)
* After running db update callbacks, update the `woocommerce_db_version` option.
* Remove dead code.
* Add tests for `wp wc update`.
2022-06-07 13:20:28 +02:00
Paul Sealock 0ed7c90d1b remove temp admin folder 2022-06-07 15:55:52 +12:00
Paul Sealock 475521ea0b Move plugin.php and readme 2022-06-07 15:55:26 +12:00
Paul Sealock b17e51fde8 Split build step into two 2022-06-07 15:37:58 +12:00
Paul Sealock c70e9e1333 Update wp-scripts 2022-06-07 15:33:20 +12:00
Paul Sealock 6ded9053b6 Move admin tester folders to root 2022-06-07 15:18:37 +12:00
Paul Sealock 54c847abb6 Copy git ignores to beta-tester 2022-06-07 15:14:21 +12:00
Paul Sealock dd712f4911 Copy eslint ignores to beta-tester 2022-06-07 15:13:14 +12:00
Paul Sealock bedd27a2eb Declare and install beta-tester dependencies 2022-06-07 15:10:36 +12:00
Paul Sealock 87005ff9ba Move beta tester temp files to Beta Tester plugin 2022-06-07 14:53:01 +12:00
Josh Betz f04e0761a6
Add individual analytics leaderboard endpoints (#33185)
Add individual analytics leaderboard endpoints

Register routes for each of the individual leaderboards.

These leaderboards can be pretty expensive to generate. If you only need
to data from one of them, it can be a pretty significant performance
boost to avoid generating all the leaderboards.
2022-06-06 07:48:30 -05:00
Joshua T Flowers 12625ae615
Add purchase task to experimental task lists (#33178)
* Add purchase task to experimental task lists

* Add changelog entry

* Add purchase header

* Update logic around purchase products list strings

* Add purchase illustration

* Fix up task title tests

* Handle PR feedback

* Fix theme title in purchase task
2022-06-06 07:58:34 -04:00
Deiva Magalhaes c4e068be3b
Product review page in WooCommerce Core (#32763)
Introduce a dedicated admin screen for better management of product reviews.

Co-authored-by: Fulvio Notarstefano <unfulvio@godaddy.com>
Co-authored-by: Adriano Castro <72993300+acastro1-godaddy@users.noreply.github.com>
Co-authored-by: Adriano Castro <adrianostanley@gmail.com>
Co-authored-by: Adriano Castro <acastro1@godaddy.com>
Co-authored-by: Ashley Gibson <agibson@godaddy.com>
Co-authored-by: Ashley Gibson <99189195+agibson-godaddy@users.noreply.github.com>
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-06-05 10:45:28 -07:00
Christopher Allford bb320a935a
Removed `@woocommerce/notices` Internal Prefix (#33283)
Since we're exposing the package in some form,
we cannot rename it since that would break backwards
compatibility.  This commit changes it back.
2022-06-03 16:05:26 -07:00
Moon 5a71268a1d
Remove WCA installation merge test (#33303)
* Remove unnecessary test

* Add changelog
2022-06-03 14:57:57 -07:00
jonathansadowski 35b58245af
Remove changelog file for cherry-picked PRs #33180 and #33300 (#33299)
* Remove changelog file for cherry-picked PR #33180

* Remove changelog file for cherry-picked PR #33300
2022-06-03 11:14:41 -05:00
Joep Schuurkes 7e54b8aea0
Add e2e tests to check shipping costs consistency in cart and checkout (#33208)
* Add e2e tests to check consistency in shipping costs for cart and checkout pages

Goal of these tests it to check if the cart and checkout pages are
consistent in calculuating shipping costs. Three tests added:
- shipping available to country with states
- shipping available to country without states
- no shipping available (fails, see issue #33205)

Reason to add these tests is PR #25916, which reverted PR #25128,
because the original PR worked for the cart page, but not for the
checkout page.

* Update e2e-core-tests changelog

* Skip failing e2e-core-test
2022-06-03 10:01:04 -06:00
Albert Juhé Lluveras 2b85008ae5
Fix broken design of Single Product template in block themes when product had no reviews or additional info (#33308)
Fix broken design of Single Product template in block themes when product had no reviews or additional info
2022-06-03 08:37:30 -07:00
Joshua T Flowers 21f7cea2b6
Add woo install timestamp to server experimental assignment requests (#33300)
* Add woo install timestamp to server experimental assignment requests

* Add changelog entry
2022-06-03 08:25:10 -04:00
Moon 29ddd17e68
Deprecate wcAdminAssetUrl and WC_ADMIN_IMAGES_FOLDER_URL (#33290)
* Fix incorrect URL for the wcAdminAssetUrl and deprecate both wcAdminAssetUrl and WC_ADMIN_IMAGES_FOLDER_URL

* Remove unused wcAdminAssetUrl var

* Remove use of wcAdminAssetUrl

* Add changelog

* Ignore hook PHPCS error -- they are pre-existing
2022-06-02 15:01:37 -07:00
Barry Hughes ea365f9f1a
Bump version number. (#33296) 2022-06-02 14:06:11 -05:00
Joshua T Flowers bec9e92b32
Add total payments volume rule processor for inbox notifications (#33192)
* Add method to get total sales for a timeframe

* Add total payments volume rule processor

* Use start and end dates for total sales method

* Add method to get start and end dates from timeframe

* Update processor rule to use timeframes

* Fix up method calls

* Add tests for timeframes

* Add tests around getting total sales by date

* Add changelog entry

* Use revenue query instead of custom query for total sales

* Update since tag on hook
2022-06-02 08:38:06 -04:00
Tung Du 7de6d18b2e
Fix: Twenty Twenty-Two integration (#32840)
* fix: Twenty Twenty-Two integration

* fix the width for checkout page. remove unnecessary account page width style

* add changelog entry
2022-06-02 11:04:27 +01:00
Chi-Hsuan Huang 5d076cc7d4
Fix obw free extension rules for the marketing task with php 8 (#33291)
* Fix obw free extensions api for marketing task with php8

* Add changelog

* Fix wcpay cbd rule
2022-06-02 13:13:44 +08:00
Hugo Derre c0619dc597
Add : "name" and "id" attributes of input html tags can now be different in wc-admin-settings (#32728)
Support specifying settings fields where the name and IDs can be different.
2022-06-01 15:16:23 -07:00
Fernando be041e0d38
Add/edit products: add new Tracks props (#33177)
* Add props to `product_add_publish

* Add props to `product_update`

* Add changelog

* Add validation to description prop

* Add validation to purchase_note

* Add validation to short_description

* Removed debugger

* Fix `get_dimensions`

* Add validation to upsells

* Changed `cross-sells` and `upsells` checks

* Fix description tracking

* Fix `description_value`

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-06-01 14:44:18 -03:00
louwie17 e02bdd98a0
Remove order/product count from wcSettings (#33064)
* Remove orderCount and publishedProductCount setting and make use of data stores

* Add test

* Add changelog

* Make use of orders data store instead of items data store

* Add users param to reports customers API params to allow filtering by user_id

* Fix invalidateResolution call that was misspelled
2022-06-01 14:15:09 -03:00
Joel Thiessen ddafa8e380
Tasks chaining side panel (#33124) 2022-06-01 10:10:20 -07:00
Roy Ho deed99313a
Remove unused contributors script (#33239)
* Remove unused contributors script

* Add changelog entry
2022-06-01 05:43:54 -07:00
Christopher Allford 112b9ac67a
Prefixed Private JS Packages (#33218)
In order to ease the identification of private packages within the monorepo, this adds an `internal-` prefix to all of the current private packages. This makes it immediately clear when reviewing `packages/js` what is and isn't a private package.
2022-05-31 15:42:00 -07:00
louwie17 c0999d4cf8
Add inbox WP admin link support for remote inbox notifications (#33237)
* Add support for admin url in remote inbox notifications

* Add unit tests for the spec runner action url

* Add changelog
2022-05-31 13:32:13 -03:00
Joshua T Flowers 7590663f3b
Remove the navigation nudge note (#33241)
* Remove the navigation nudge note

* Add changelog entry
2022-05-31 12:09:40 -04:00
Chi-Hsuan Huang cad762197b
Add "built by Woo" label to Pinterest (#33270)
* Set is_built_by_wc to true for pinterest

* Add changelog
2022-05-31 16:46:36 +08:00
Chi-Hsuan Huang 822b4538ad
Update Tax task title (#33269)
Update the tax task title to "Set up tax rates"
2022-05-31 16:45:33 +08:00
Viktor Szépe 983a6cab96
Update required WP version (#33246)
See https://github.com/woocommerce/woocommerce/blob/trunk/plugins/woocommerce/composer.json#L17
2022-05-30 16:12:59 -05:00
Luigi Teschio 9a4f1d93e4
Add check for post_types key #33179 (#33180)
Add check for post_types key
2022-05-30 11:30:45 -07:00
louwie17 61d9d0043f
Add initial tracking for categories, tags, and attribute product pages (#33118)
* Add initial tracking for categories, tracks, and attribute product pages

* Update list action tracks that add new items without page refresh

* Add changelog

* Add extra category tracks

* Rename constant for add a new tag button

* Remove unneeded props from track
2022-05-30 13:14:25 -03:00
louwie17 574e00b6d5
Add/32676 category and tag tracks within products screen (#33121)
* Add logs for the attributes and tags on the product page

* Only trigger attributes_add on product screen when user hits save

* Add extra props to attribute add track

* Add tags delete track and fix count of tags add track

* Update use of wp_localize_script
2022-05-30 10:06:34 -03:00
RJ b051ed88db
Update react-router-dom to v6 for woocommerce-admin (#33156) 2022-05-30 14:51:33 +08:00
erikdemarco d6f2848d8c
Add new filter to product archive description (#31958)
Add new filter to product archive description
2022-05-27 13:31:13 -07:00
Ninos Ego c821ebdc0a
Fixed: Don't show placeholder on transparent product thumbnails (#30959)
Fixed: Don't show placeholder on transparent product thumbnails
2022-05-27 13:26:39 -07:00
jonathansadowski e5bd98dc36
Remove changelog files for PRs cherry-picked into 6.6-RC1 (#33244) 2022-05-27 15:23:40 -05:00
Ian Forrest 13f4e1572a
Add role="presentation" to table within add-to-cart form. (#33123)
Add table role="presentation" for an accessibility enhancement.
2022-05-27 12:58:38 -07:00
Ilyas Foo b85dca4308
Fix unresponsive clicks on product task card elements (#33235)
* Fix clicking on borders for product task card elements

* Changelog
2022-05-27 13:04:17 -05:00
Fernando cb2c09fad7
Fix completed card button (#33238)
* Fix completed card button

* Update sectioned task list to use onboarding data store

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
Co-authored-by: Joshua Flowers <joshuatf@gmail.com>
2022-05-27 12:41:16 -04:00
RJ 0f0b2d5064
Cleanup and fix translation path changes (#33226)
Cleanup translation path changes

- removed temporary codepath since translation paths have been updated
2022-05-27 16:57:43 +08:00
Ilyas Foo 368d8ac4fc
TimeInterval test fix expected 5 weeks instead of 6 (#33227)
* Fix expected 5 weeks instead of 6

* Changelog
2022-05-27 15:08:40 +08:00
Néstor Soriano 64c6803640
Improve unit testing infrastructure (#33140)
* Add infrastructure for mocking globals in unit tests.

- 'get_global' method in LegacyProxy, MockableLegacyProxy and WC().
- 'register_global_mocks' method in MockableLegacyProxy.
- 'register_legacy_proxy_global_mocks' method in WC_Unit_Test_Case.

* Add the DynamicDecorator class, and unit tests for it.

* Add the StringUtil::contains method

* Add unit tests for error logging on PostsToOrdersMigrationController

* Update README file to mention improvements in unit testing infrastructure

- Mention the mechanism to mock globals using the LegacyProxy
- Mention the code hacker and the DynamicDecorator

* Add changelog file
2022-05-27 11:43:31 +05:30
Ilyas Foo ca4e3606b1
Fix dashboard and analytics crashing (#33206)
* Set timezone before calling get_weekstartend and after to preserve original timezone

* Add test for timezone check

* Update calculation to be timezone agnostic and add tests

* Changelog
2022-05-27 10:08:46 +08:00
Chi-Hsuan Huang 4a6c6e739c
Update woocommerce-admin `test:watch` command (#33202)
* Update woocommerce-admin test:watch command

Only watch admin ./client folder

* Add changelog
2022-05-27 10:08:34 +08:00
Matt Harrison 3ac62945c1
Allow filtering of cookie flags, which enables setting of samesite (#33219)
Allow filtering of cookie flags, which enables setting of `samesite`.

* Break out filter so the same filter can be used for any version of PHP.
* Add docblocks and other linting fixes; add changelog.

Props: David Anderson <DavidAnderson684@users.noreply.github.com>
2022-05-26 16:40:16 -07:00
Kathy 8edc32c7fb
Cleanup twentytwenty notice styles. Closes #29529. (#33182)
Cleanup twentytwenty notice notices. Closes #29529.

* Increase width of border for notices
* Make notice buttons black to provide sufficient contrast
* Add changelog.
2022-05-26 16:15:49 -07:00
Joshua T Flowers e4824b9660
Add tracks to new product and edit product screens (#33120)
* Move product list tracks to seperate file

* Change product list tracks to TS

* Check init of tracks on client-side

* Add new product tracks

* Add product screen tracks

* Add product edit tracks

* Localize product screen variable

* Add changelog entry

* Handle PR feedback

* Track date changes on edit
2022-05-26 16:56:22 -04:00
Joshua T Flowers 2294082869
Fix report days calculation to account for DST (#33036)
* Fix report days calculation to account for DST

* Add tests around month with DST

* Update tests to use EST timezone
2022-05-26 16:55:54 -04:00
jonathansadowski bf02f377e6
Prepare trunk for 6.7 (#33215)
* Prepare trunk for 6.7

* Update composer.json and package.json for 6.7
2022-05-26 15:49:37 -05:00
jonathansadowski 0c619cbafe
Remove empty changelog file for updating minimum wp version (#33213) 2022-05-26 15:02:39 -05:00
Paul Sealock 37905dd178
Analyzer CLI: Add Database scanning (#33084) 2022-05-27 07:52:39 +12:00
jonathansadowski 66633dfe1a
Remove changelog files for cherry-picked PRs #32940 and #33171 (#33209) 2022-05-26 12:25:22 -05:00
jonathansadowski cd520c0e53
Update minimum wp version in woocommerce.php (#33194)
* Update minimum wp version

* Add changelog file for minimum wp version update

* Update required WP version in readme.txt
2022-05-26 08:39:24 -05:00
Chi-Hsuan Huang 13fe9b4970
Merge pull request #32644 from woocommerce/update/reports-datastore-date-column
Replace the date_created column name with a class property in the analytics DataStore
2022-05-26 09:24:15 +08:00
Jonathan Lane f70afccec9
Merge pull request #33139 from woocommerce/e2e/rep-playwright-feature-flag
Run Playwright tests behind feature flag
2022-05-25 14:55:23 -07:00
“Chris 58abc685cb Add changelog 2022-05-25 16:36:22 +03:00
Christos Lilitsas d057225e07
Add default value to `db_datetime_format` for back compatibility
Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-05-25 16:26:20 +03:00
louwie17 ddb3239a1c
Merge pull request #33163 from woocommerce/fix/leaderboard-menu-styling
Fix the styling of the frame in the Leaderboard section of Analytics.
2022-05-25 10:14:32 -03:00
AnnaMag 165d3b659a Add changelog 2022-05-25 14:16:20 +02:00
Chi-Hsuan Huang 0240a29eb6
Merge pull request #33168 from woocommerce/dev/migrate-woo-data-options-to-ts
Migrate `@woocommerce/data` options store to TS
2022-05-25 13:20:07 +08:00
Jonathan Sadowski 4ece2489db Add changelog entry for update of Action Scheduler to 3.4.1 2022-05-24 15:48:02 -05:00
Jonathan Sadowski 7fbb8ba1d9 Update Action Scheduler to 3.4.1 2022-05-24 15:42:14 -05:00
Joel Thiessen 5f56ecb9b0
Suppressing warnings for malformed metadata in product template downloads #32971 #32971 2022-05-24 11:12:02 -07:00
jonathansadowski 22375b34f4
Merge pull request #32940 from woocommerce/update/woocommerce-blocks-7.6.0
Update WooCommerce Blocks package to 7.6.0
2022-05-24 09:25:51 -05:00
Chi-Hsuan Huang 4d9e07bbd4 Add changelogs 2022-05-24 21:41:36 +08:00
Chi-Hsuan Huang 55dfa78ebb Fix type errors in ./client after migrating options store to TS 2022-05-24 21:41:36 +08:00
Peter Fabian 59f6ffa027
Merge pull request #33130 from woocommerce/add/schema-output
Add script to get db schema from CLI
2022-05-24 15:20:56 +02:00
Joshua T Flowers 97eecfdcc4
Use term ID to query category IDs in analytics (#33164)
* Use term ID to query category IDs in analytics

* Add changelog entry
2022-05-24 09:10:58 -04:00
Chi-Hsuan Huang 773ab10c61 Add translator domain to texts 2022-05-24 17:24:54 +08:00
Chi-Hsuan Huang 1b8e90b529 Remove unnecessary completion time track 2022-05-24 17:09:53 +08:00
Chi-Hsuan Huang 8ff2c334d7 Fix missing translation domain 2022-05-24 16:56:16 +08:00
Chi-Hsuan Huang 3613ccb23e Add changelog 2022-05-24 15:43:29 +08:00
Chi-Hsuan Huang e2cc91dd60 Add confirmation dialog before loading the sample products 2022-05-24 15:43:27 +08:00
Chi-Hsuan Huang 86553fbe1f Add load sample product confirm modal 2022-05-24 15:00:17 +08:00
Ilyas Foo 78f96109da
Fix PHP notice when `woocommerce_admin_disabled` filter is used (#33154)
* Add array key check

* Changelog
2022-05-24 12:14:28 +08:00
Paul Sealock 3b51144011 add wc- namespace 2022-05-24 14:22:03 +12:00
AnnaMag af7f738704 Fix the styling of the frame in the Leaderboard section of Analytics. 2022-05-23 17:30:47 +02:00
Chi-Hsuan Huang c83dedd849
Merge pull request #33153 from woocommerce/dev/33132-migrate-woo-onboarding-to-ts
Migrate `@woocmmerce/onboarding` to TS
2022-05-23 18:33:00 +08:00
Néstor Soriano 484e790d99
Merge pull request #32864 from woocommerce/add/32385-cot-admin-list-table
Admin list table [COT]
2022-05-23 12:05:52 +02:00
Néstor Soriano 7c9eddf251
Merge pull request #26965 from RiLaRos/master
Update add precision function when pass empty string parameter
2022-05-23 09:13:49 +02:00
Chi-Hsuan Huang 637ea244ea Add changelog 2022-05-23 13:28:31 +08:00
Chi-Hsuan Huang 485d858fc3 Remove onboarding task @ts-expect-error and fix related type errors 2022-05-23 13:27:11 +08:00
Jonathan Sadowski d2eefc4467 Remove pending 6.6 changelog files 2022-05-20 13:58:09 -05:00
barryhughes c9ebffda40 Improve menu integration (classic as well as the new WC Admin nav feature). 2022-05-20 13:52:40 +00:00
barryhughes 715544f811 Resolve conflicts. 2022-05-20 13:51:41 +00:00
barryhughes b30bd2a85a Tighten baseline order query to only fetch regular orders (not refunds). 2022-05-20 13:44:50 +00:00
barryhughes 9f58514350 Add changelog. 2022-05-20 13:44:50 +00:00
barryhughes e1c771337f Add enhanced (Marketplace-ready) 'no results' view. 2022-05-20 13:44:50 +00:00
barryhughes 6dde512e79 Do not remove WC Admin nav from existing CPT admin list table. 2022-05-20 13:44:50 +00:00
barryhughes 1aa6265544 Tidy. 2022-05-20 13:44:50 +00:00
barryhughes 0ecffb416f Tweak logic responsible for registering COT admin list table. 2022-05-20 13:44:50 +00:00
barryhughes 8b30cf2639 Connect new list table with WC Admin nav. 2022-05-20 13:44:50 +00:00
barryhughes e27b89a7e8 Align column names with original WP List Table (for better back-compat). 2022-05-20 13:44:50 +00:00
barryhughes 77197d3f85 Retain state when filtering. 2022-05-20 13:44:49 +00:00
barryhughes aaefb3b5d5 Per existing order admin list, hide various columns by default. 2022-05-20 13:44:49 +00:00
barryhughes a954aae826 Utilize existing CSS, class-names, JS. 2022-05-20 13:44:49 +00:00
barryhughes 11c2e0c061 Table pagination. 2022-05-20 13:44:49 +00:00
barryhughes 0eabe18b79 Add (dates, customers) filters. 2022-05-20 13:44:49 +00:00
barryhughes 8d44bfb9eb Add bulk actions dropdown. 2022-05-20 13:44:49 +00:00
barryhughes bde166db3d Add table views. 2022-05-20 13:44:49 +00:00
barryhughes e07b0a3b10 Address and reduce code duplication across list table implementations. 2022-05-20 13:44:49 +00:00
barryhughes f95834f095 Create a baseline admin list table implementation that is data-store agnostic. 2022-05-20 13:44:49 +00:00
vedanshujain e3d0de1065 Removed unused import. 2022-05-20 16:36:56 +05:30
vedanshujain ef03e5e0dd Add changelog. 2022-05-20 16:34:51 +05:30
vedanshujain b9f1a05c85 Add methods and fixes that were removed due to merge conflicts. 2022-05-20 15:42:38 +05:30
vedanshujain 781f97242d Remove back-compat support for _date_paid and _date_complete as it conflicts with verify data logic. 2022-05-20 15:41:02 +05:30
Rodel 4da670cc82 Add patch changelog to ignore e2e changes 2022-05-20 16:16:55 +08:00
Rodel 32604a0acc Update html output folder location 2022-05-20 16:02:43 +08:00
Rodel 3a6a546daa Update base url in playwright config 2022-05-20 15:58:54 +08:00
Néstor Soriano 4f76d76d1f
Add changelog file. 2022-05-20 09:55:58 +02:00
Rodel 381c5507da Add allure-playwright config 2022-05-20 15:33:42 +08:00
Rodel 7b66d06c91 Checkout e2e folder from add/playwright-e2e branch 2022-05-20 15:30:28 +08:00
Rodel f79c684c4b Install allure-playwright dependency 2022-05-20 15:26:48 +08:00
Rodel 0429f2abfc Install @woocommerce/woocommerce-rest-api dependency 2022-05-20 15:26:19 +08:00
Rodel 29afe4971e Install playwright dependency 2022-05-20 15:24:46 +08:00
Rodel 86d604756c Checkout .eslintrc.js from add/playwright-e2e 2022-05-20 15:16:50 +08:00
Nestor Soriano 59a6a54891
Add changelog file for #33034 2022-05-20 09:09:14 +02:00
Rodel 99796df9d4 Ignore Allure directories globally 2022-05-20 15:08:01 +08:00
Vedanshu Jain c771121459
Merge pull request #33034 from woocommerce/add/logging_for_posts_to_cot_migration
[COT] Log errors during the posts to orders table migrations
2022-05-20 12:32:00 +05:30
Paul Sealock 71252cac9b changelog 2022-05-20 14:16:06 +12:00
Moon 0b35ad678d
Merge pull request #33027 from woocommerce/update/update-history-package
Update history package to the latest 5.3.0 version
2022-05-19 18:27:12 -07:00
Paul Sealock 7cfdbe4922 add get-schema 2022-05-20 11:48:27 +12:00
Joel T 9e62fb58b8 Updating references to old album-1 image 2022-05-19 16:05:23 -07:00
Paul Sealock 373ad382b5
Analyzer CLI: Refactor main file (#33081) 2022-05-20 10:02:40 +12:00
moon 29fcbfaf68 Fix the failing test 2022-05-19 15:02:04 -07:00
Barry Hughes e62a338826
Merge pull request #31417 from woocommerce/fix/add_filter_to_wc_create_refund
Introduce a filter to control whether an order is partially refunded in `wc_create_refund`
2022-05-19 12:18:11 -07:00
barryhughes 277e3635ab Update @version to 6.7.0. 2022-05-19 18:36:29 +00:00
Jorge A. Torres f64dc181fd
Merge pull request #32953 from Pross/patch-1
Make sure variable is set in `system_status` endpoint.
2022-05-19 17:43:56 +01:00
Sonhui 1376f8acda
Hide post code for Belize, and make state optional (#32731) 2022-05-19 16:01:24 +01:00
“Chris d569cf463a Add docblock 2022-05-19 17:41:09 +03:00
Jorge A. Torres d2d8efa7fc
Merge pull request #32857 from woocommerce/cot/backfill
Implement backfill for update posts records from COT
2022-05-19 15:00:15 +01:00
Adrian Duffell d1fdc2aecc
Update Icon for TikTok for WooCommerce extension (#33112)
* Add tiktok onboarding icon

* Change tiktok extension icon to normal logo

* Remove tiktok for business icon

* Add changelog
2022-05-19 20:00:35 +08:00
Nestor Soriano 71e0fd92d6
Move the base table migration classes outside CustomOrderTable directory
These classes are generic and don't depend on the custom orders table
functionality, so they are moved from src/Database/Migrations/CustomOrderTable
to just src/Database/Migrations.
2022-05-19 10:26:59 +02:00
Nestor Soriano 469c5a1aea
Change references to "orders" to "entities" in generic table migrators 2022-05-19 09:48:04 +02:00
Nestor Soriano c4b498d13f
Remove the MigrationErrorLogger class as it's not used. 2022-05-19 09:43:41 +02:00
Nestor Soriano 9e42028c98
Add changelog file 2022-05-19 09:20:10 +02:00
Nestor Soriano dbbef8ff8a
Move the DatabaseUtil class to the proper directory
The class is in the Automattic\WooCommerce\Internal\Utilities namespace,
but it was wrongly placed in the src/Utilities directory. It has been
moved to usr/Internal/Utilities without changing the namespace, thus
no code changes are required.
2022-05-19 09:12:51 +02:00
Vedanshu Jain 5ab229d217
Merge pull request #32957 from woocommerce/add/experiment-subscriptions-admin-menu-1 2022-05-19 08:32:15 +05:30
James Allan 3cecb3d72c Introduce susbcriptions menu item slug constant 2022-05-19 11:14:32 +10:00
James Allan 3aa2294968 Use date created and status order filter for order eligiblity check
Using these two order properties instead of the paid_date field is more performance friendly
as both fields are in the wp-posts table - not in the post_meta table.

ref: 71e9657e52 (r875545984)
2022-05-19 10:42:53 +10:00
Chris Aprea 98e23a8156 Only add the inline script if the store is eligible for the experiment 2022-05-19 10:11:27 +10:00
Moon 9b7bf2cf16
Merge pull request #32974 from woocommerce/update/32410-deprecated-wca-classes-have-wca-versions
Use the core version for the @deprecated tags in WCA
2022-05-18 16:11:10 -07:00
Barry Hughes 2b6097535b
Merge pull request #33091 from DavidAnderson684/patch-8
Check results of calling WP_Filesystem()
2022-05-18 15:07:43 -07:00
barryhughes a642db3d41 Add changelog. 2022-05-18 21:38:34 +00:00
David Anderson dbd3c71ee8
Update plugins/woocommerce/includes/integrations/maxmind-geolocation/class-wc-integration-maxmind-geolocation.php
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-05-18 21:22:13 +00:00
barryhughes a1279e67c6 Switch to cast to coerce values into floats. 2022-05-18 20:43:38 +00:00
Barry Hughes 1ce91eb70f
Merge pull request #33078 from woocommerce/add/pay-for-order-express-checkout-action
Adding the action to the Pay for Order shortcode
2022-05-18 11:46:35 -07:00
Radoslav Georgiev 303e7e27a1 Adding available_gateways to the filter 2022-05-18 20:57:00 +03:00
Radoslav Georgiev 1c813ea3fb Adding a docblock to the order button filter as well 2022-05-18 18:16:25 +03:00
Radoslav Georgiev f73cbb6671 Adding a @since to the docblock comment. 2022-05-18 18:05:27 +03:00
David Anderson 01b248c8df
Check results of calling WP_Filesystem() 2022-05-18 10:36:48 +00:00
Ilyas Foo 045b9e6cf3
Fix nested link in products import task (#33088)
* Fix nested links by using onClick event instead

* Changelog
2022-05-18 17:57:25 +08:00
vedanshujain 7ff0ba8061 Applied coding standards. 2022-05-18 13:24:42 +05:30
RJ f637dd2bb7
Add: temporary workaround to add experiment metadata for task_view (#33052)
rigged a workaround to let products task report its experimental assignment
2022-05-18 15:24:48 +08:00
RJ 31922c1da9
Merge pull request #33083 from woocommerce/fix/broken-events-tracking-assignment-to-const
fix: broken event tracking due to assignment to const
2022-05-18 11:16:02 +08:00
Chi-Hsuan Huang 9a15f68f3f
Merge pull request #33068 from woocommerce/update/33062-subscriptions-product-type-only-in-the-us
Update add product task to only show "subscriptions" product type for stores in the US
2022-05-18 11:12:52 +08:00
RJChow b8bd4bb5ca fix: broken event tracking due to assignment to const 2022-05-18 10:28:27 +08:00
Chi-Hsuan Huang 3ba19b3ab5 Add changelog 2022-05-18 10:21:49 +08:00
Chi-Hsuan Huang 1a87301894 Fix payment settings banner tos link 2022-05-18 10:21:29 +08:00
Chi-Hsuan Huang c551477248 Hide subscription product type when store country is unknown 2022-05-18 10:18:57 +08:00
Chi-Hsuan Huang 103afc0c6d Add changelog 2022-05-18 10:15:45 +08:00
Chi-Hsuan Huang 017d8c2a80 Update product task to only show subscription product type for merchants in the US 2022-05-18 10:15:44 +08:00
Chi-Hsuan Huang 657e40ed98 Convert getProductTypes method to use object param 2022-05-18 10:15:17 +08:00
Chi-Hsuan Huang c8146d6c5d
Merge pull request #33071 from woocommerce/fix/33055-skip-payment-welcome-screen-for-wcpay-setup
Skip payment welcome screen for WCPay banner experiment
2022-05-18 10:07:00 +08:00
Chi-Hsuan Huang dc9b545a30
Merge pull request #33058 from woocommerce/add/view-more-product-type-track
Add view more product type click event track for the add product task
2022-05-18 09:51:49 +08:00
Chi-Hsuan Huang 29fe251bb1
Merge pull request #33030 from woocommerce/update/system-status-report
Report the status of admin items in SSR
2022-05-18 09:50:27 +08:00
James Allan 71e9657e52 Fix typo 2022-05-18 11:21:41 +10:00
James Allan 91669281ec Rename component class names with BEM standard names 2022-05-18 10:56:06 +10:00
Chris Aprea 0cd63cf130 Only register the the subscriptions page if tracking is allowed 2022-05-18 09:21:39 +10:00
Moon d066266fbf
Merge pull request #33023 from woocommerce/update/33022-update-explat-with-examples
Update ExPlat with more examples
2022-05-17 16:20:09 -07:00
louwie17 e822a4a7f4
Merge pull request #32538 from woocommerce/feature/32158_complete_task_list_card_with_feedback
Feature/32158 complete task list card with feedback
2022-05-17 17:39:14 -03:00
Radoslav Georgiev 2ae5d90088 Adding the changelog entry 2022-05-17 20:32:04 +03:00
Lourens Schep 23d64d0bc2 Rename showCustomerEffortScore prop 2022-05-17 14:25:06 -03:00
Radoslav Georgiev 3cb59ebc8f Adding the action to the Pay for Order shortcode 2022-05-17 20:24:24 +03:00
Joshua T Flowers 07b02fb858
Add filtered tracks properties to client-side tracks (#32690)
* Add filtered tracks properties to client-side tracks

* Add changelog entry

* Fix up tracks errors

* Update vars to const
2022-05-17 13:12:52 -04:00
Joshua T Flowers 0702433531
Add tracks to products list page (#32949)
* Add tracks to products list page

* Remove duplicate tracks

* Add changelog entry

* Check for fields before getting values

* Add bulk actions cancel button

* Check for element before binding event listener

* Check for search input before getting value
2022-05-17 11:52:44 -04:00
vedanshujain 2ca4b42846 Modify tests to skip reading meta_ids 2022-05-17 20:12:47 +05:30
vedanshujain ad30c61463 Multiple fixes for reading order data.
Some meta items cause issues when testing, such as having trailing zeros. This commit fixes, along with adding compatibility with WC < 2.6.
2022-05-17 20:10:40 +05:30
Lourens Schep 5494f4970d Renamed some of the variables to remove some ambiguity 2022-05-17 09:59:11 -03:00
Vedanshu Jain 58eaa73d39
Merge pull request #33051 from woocommerce/pr/32980
From PR 32980, Update IN PIN Code
2022-05-17 17:28:35 +05:30
vedanshujain 37a41423fe Add changelog. 2022-05-17 16:48:03 +05:30
vedanshujain 253e8424ea Add backfill method to support update post and postmeta data. 2022-05-17 16:47:59 +05:30
vedanshujain 22f81c9693 Add test for backfill from COT to wp_post and wp_postmeta. 2022-05-17 16:47:17 +05:30
Chi-Hsuan Huang 27ed682980 Add changelog 2022-05-17 17:40:59 +08:00
Chi-Hsuan Huang d4af17d3a3 Skip payment welcome screen for wc pay banner experiment 2022-05-17 17:40:59 +08:00
RJ b524b82816
Merge pull request #33047 from woocommerce/fix/wrap-import-products-under-experiment
Wrap product task import around experiment
2022-05-17 14:57:29 +08:00
vedanshujain ea1594bab9 Add changelog. 2022-05-17 11:40:49 +05:30
Chi-Hsuan Huang 902dcf3369 Check if woocommerce_admin_install_timestamp > 0 for SSR & remove extra space 2022-05-17 14:07:39 +08:00
Chi-Hsuan Huang 9bddfbb84e Add changelog 2022-05-17 13:58:33 +08:00
Chi-Hsuan Huang c4c1cc4da7 Add admin items to system status report 2022-05-17 13:58:33 +08:00
vedanshujain 2ad4a54e10 Merge branch 'trunk' into pr/32743 2022-05-17 11:26:38 +05:30
Chi-Hsuan Huang 9ff7f887d1 Add changelog 2022-05-17 13:06:55 +08:00
Chi-Hsuan Huang 2520781c7e Add tasklist_view_more_product_types_click track event for add product task 2022-05-17 13:06:55 +08:00
Moon c6d198723f
Merge pull request #33066 from woocommerce/update/33056-update-the-wcpay-description
Redirect users to the WC Pay connect page if the WC Pay is already installed
2022-05-16 20:17:29 -07:00
Chris Aprea 0afc9dd2de Merge branch 'trunk' into add/experiment-subscriptions-admin-menu-1 2022-05-17 13:12:21 +10:00
moon 285047fde8 Update the description and make the button to redirect the users to the WC Pay connect page when the WC Pay is already installed 2022-05-16 15:37:38 -07:00
moon 362e98489a Set icon width to 51px 2022-05-16 14:00:43 -07:00
Roy Ho 02ef6c534e
Merge pull request #33037 from woocommerce/prep/post-6.5.1
Update changelog to reflect 6.5.1 release
2022-05-16 12:49:30 -07:00
Tam Mullen e8740f8b73
Merge pull request #33044 from woocommerce/update/k6-merch-wc-home-assert
Updated assertion for k6 merchant wc home request
2022-05-16 17:50:52 +01:00
Vedanshu Jain 7c537b342c
Merge pull request #32577 from davefx/patch-14
Avoid exception when serializing context
2022-05-16 19:54:36 +05:30
Lourens Schep d1bf5c5719 Address the majority of the PR feedback 2022-05-16 10:03:46 -03:00
Chris Aprea 1fa3060697
Merge pull request #32958 from woocommerce/add/experiment-subscriptions-admin-menu-experiment-framework
Add experiment functionality to the WooCommerce → Subscriptions page
2022-05-16 22:31:22 +10:00
vedanshujain f830968c04 Add changelog. 2022-05-16 17:17:33 +05:30
vedanshujain 1eba660503 Merge branch 'trunk' into pr/32577 2022-05-16 17:06:22 +05:30
Néstor Soriano 4b0d5550ed
Merge branch 'trunk' into add/logging_for_posts_to_cot_migration 2022-05-16 12:53:13 +02:00
Vedanshu Jain 7c37c9187a
Merge pull request #32925 from woocommerce/issue/32843
Add `_recorded_sales` meta to COT
2022-05-16 16:04:14 +05:30
Nestor Soriano 33791e4fcd
Fix: MetaToMetaTableMigrator attempting to migrate empty datasets
That caused an invalid SQL query to throw an error.
2022-05-16 12:27:58 +02:00
rodelgc 6cda659980
Publish API test reports to GitHub Pages
- Added workflow to publish API tests
2022-05-16 17:59:40 +08:00
Chi-Hsuan Huang 03ba7bc794
Merge branch 'trunk' into add/32859-fashion-sample-products 2022-05-16 17:18:26 +08:00
Chi-Hsuan Huang 697eb185b1
Merge pull request #33049 from woocommerce/update/enable-feature-flags-for-product-task
Enable feature flags for add product task
2022-05-16 16:38:01 +08:00
Vedanshu Jain b8e2de8520
Merge pull request #32938 from woocommerce/cot/32917
Add CLI support to run migrations.
2022-05-16 12:34:15 +05:30
vedanshujain d5aa1a11ec Add changelog. 2022-05-16 12:24:06 +05:30
Chi-Hsuan Huang 213b987981 Update fashion sample product file 2022-05-16 14:53:46 +08:00
Roxanne S 05c1dade0c Update IN PIN Code
This fixes https://github.com/woocommerce/woocommerce/issues/32965
2022-05-16 12:21:40 +05:30
Chi-Hsuan Huang 71dabded8a Enable experimental-fashion-sample-products feature 2022-05-16 12:28:43 +08:00
Ilyas Foo 40a1eb5a01 Move out logic to be reusable 2022-05-16 12:00:09 +08:00
Chi-Hsuan Huang f5e4f1ade6 Add changelog 2022-05-16 11:40:28 +08:00
Chi-Hsuan Huang 88068a4cd0 Enable feature flags for add product task 2022-05-16 11:39:46 +08:00
Ilyas Foo 68c7de6c5e
Fix janky product task items on hover (#33043)
* Fix hover border size

* Changelog
2022-05-16 11:32:37 +08:00
Ilyas Foo 120029e078 Changelog 2022-05-16 10:59:46 +08:00
Moon 1ef9b2d2ba
Merge pull request #32850 from woocommerce/add/32778-tiktok-marketing-task
Add TikTok marketing task
2022-05-15 19:55:57 -07:00
Ilyas Foo ebec562699 Wrap product task import around experiment 2022-05-16 10:49:49 +08:00
Tam Mullen dff5d18c4c Updated assertion for admin.php?page=wc-admin k6 performance request 2022-05-15 22:13:52 +01:00
Tam Mullen cd0a491094 Updated assertion value for admin.php?page=wc-admin k6 performance request 2022-05-15 13:18:16 +01:00
moon fded54dd81 Revert back google ad image 2022-05-13 15:44:11 -07:00
Barry Hughes c08585ab69
Update fix-products-api-method-visibility
No changelog needed (place explanation in comment field)
2022-05-13 15:36:04 -07:00
moon 7d1c1b7894 Add . 2022-05-13 15:34:35 -07:00
moon b85f0b0aa7 Add Changelog 2022-05-13 15:33:47 -07:00
moon 3431c73046 Add tiktok marketing task to the default free extensions list 2022-05-13 15:26:00 -07:00
Corey McKrill 6229dfcb59
Add changelog 2022-05-13 15:24:42 -07:00
Corey McKrill 634c96d29c
Products API: revert get_objects method to `protected`
In 029257b I inadvertently changed the visibility of the get_objects
method to public. There is no need for its visibility to differ from
the parent class, and it ended up causing fatal errors for other classes
that are extending WC_REST_Products_Controller. This simply changes
the visibility back to protected.
2022-05-13 15:09:41 -07:00
roykho 1e7466ade3
Add changelog entry 2022-05-13 12:05:37 -07:00
roykho 9f41cf7609
Update changelog to reflect 6.5.1 release 2022-05-13 11:56:55 -07:00
Nestor Soriano 500db3cdba
Log all db errors and exceptions in the posts to orders migrators.
To achieve this:

- A new class is added, TableMigrator, containing basic in-memory
  error storage methods, and auxiliary db_query and db_get_result
  methods.
- MetaToCustomTableMigrator and MetaToMetaTableMigrator classes
  now extend TableMigrator and use these db_* methods.
- process_migration_batch_for_ids is now a method in TableMigrator,
  it just calls the abstract process_migration_batch_for_ids_core,
  catches exceptions, and returns an array of errors.
- PostsToOrdersMigrationController now logs all the errors returned
  by process_migration_batch_for_ids in all the migrator classes.
- New utility method: ArrayUtil::to_ranges_string
2022-05-13 16:29:55 +02:00
Nestor Soriano 087e8ecacf
Fix issues in error handling in the MetaToCustomTableMigrator class
There were some inconsistencies, such as trying to treat an error
array as a string, or accessing to a non-existing column from a
dataset retrieved from the db on error.
2022-05-13 16:25:03 +02:00
Nestor Soriano d0e3035cc8
Adjust visibility of methods in the orders table migrator classes.
Many methods were public/protected when they could be protected/private
instead. All methods are adjusted to the minimum visibility required
for the current implementation to work.

Also minor adjustments for phpcs, such as "ignore" comments.
2022-05-13 16:16:04 +02:00
Lourens Schep 780fbffc68 Fix merge conflict type issue 2022-05-13 10:29:21 -03:00
Lourens Schep 03cb7e5a42 Fix completed image display in two column layout 2022-05-13 10:29:21 -03:00
Lourens Schep fe1e814a41 Fix customer effort types and add timeout to thank you message 2022-05-13 10:29:21 -03:00
Lourens Schep b441a84d9d Keep score displayed if user cancels out of CES Modal 2022-05-13 10:29:21 -03:00
Lourens Schep 45dfda2b65 Move CES show logic to the back end, so there is no loading delay 2022-05-13 10:29:21 -03:00
Lourens Schep 4b27f831f7 Add CES submission 2022-05-13 10:29:21 -03:00
Lourens Schep 7aa37d609f Added new completed header and customer feedback component 2022-05-13 10:29:20 -03:00
vedanshujain 07977131e1 Address PR feedback - function name for readability, indentation etc. 2022-05-13 16:37:34 +05:30
vedanshujain 7b0564a44e Add support to migrate meta tables. 2022-05-13 16:37:34 +05:30
Vedanshu Jain ac4367f7ef Correct formatting for comment.
Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-05-13 16:37:33 +05:30
vedanshujain 07f9d2cd2a Rename count to count_unmigrated for better readability. 2022-05-13 16:37:33 +05:30
vedanshujain 71cc54522d Applied PR feedback. 2022-05-13 16:37:33 +05:30
vedanshujain ea29eb8c49 Increase batch size to 500 for faster processing. 2022-05-13 16:37:33 +05:30
vedanshujain 1722793c80 Add testing instructions link. 2022-05-13 16:37:33 +05:30
vedanshujain 05dae81030 Removed unused export. 2022-05-13 16:37:33 +05:30
vedanshujain 75f5528445 Addressed feedback comments. 2022-05-13 16:37:33 +05:30
vedanshujain 99a76bf7d4 Add verify command in CLI to verify migrated orders. 2022-05-13 16:37:33 +05:30
vedanshujain d2e6689407 More defensive checks for date_epoch data type. 2022-05-13 16:37:33 +05:30
vedanshujain 8c148e7e4b Use `+` to preserve order ID index. 2022-05-13 16:37:33 +05:30
vedanshujain 3578b02b0c Add function to verify migrate orders for COT migration. 2022-05-13 16:37:33 +05:30
vedanshujain 8876ddd5ca Add verification support to custom table migrators. 2022-05-13 16:37:33 +05:30
vedanshujain 31e5e08330 Add changelog. 2022-05-13 16:37:33 +05:30
vedanshujain 1750590822 Add CLI support to run migrations. 2022-05-13 16:37:33 +05:30
Ilyas Foo 1b0ee6f5da
Remove WCAdmin deactivation note (#33028)
* Add wc-admin-deactivate-plugin to list of obselete notes

* Changelog
2022-05-13 13:59:19 +08:00
RJ 2c5f47a91d
Merge pull request #32944 from woocommerce/add/tracks-experimental-products
Add tracks for experimental products page
2022-05-13 12:41:48 +08:00
Chi-Hsuan Huang 55884d841e Add changelog 2022-05-13 12:10:00 +08:00
Chi-Hsuan Huang 3d55bfb2be Add fashion sample products for product task 2022-05-13 12:10:00 +08:00
Chi-Hsuan Huang 12e3a2f27d Add a feature flag for fasion sample products 2022-05-13 12:10:00 +08:00
Chi-Hsuan Huang eb5ef8dfc6
Merge pull request #32973 from woocommerce/fix/32956-notice-on-empty-product-page
Fix notice on empty product page
2022-05-13 10:33:28 +08:00
moon 8adcae1072 Remove @types/history -- it is part of history 5.3.0 2022-05-12 18:34:13 -07:00
moon e40f73a555 Add changelog 2022-05-12 18:32:06 -07:00
moon aa7853edbd Update history package to the latest 5.3.0 version 2022-05-12 18:28:43 -07:00
RJChow f3cc00ff8b changelogs 2022-05-13 06:20:11 +08:00
RJChow 05cd1c30de Added tracks events to experimental products pages 2022-05-13 06:16:28 +08:00
roykho 7b0e30d852
Add changelog entry 2022-05-12 14:58:49 -07:00
roykho d69eeba36e
Bumping WP tested up to version to 6.0 2022-05-12 14:55:15 -07:00
moon f3035c65c7 Add changelog 2022-05-12 14:39:37 -07:00
moon aaf9282277 Add Experimental_Abtest usage 2022-05-12 14:34:41 -07:00
moon daeebfc622 Add comment for the hook 2022-05-12 14:17:05 -07:00
moon bf4d777704 Add changelog 2022-05-12 14:10:00 -07:00
Joel Thiessen cb8076966e
Adding badge to legacy admin menu to indicate remaining onboarding tasks 2022-05-12 12:29:45 -07:00
louwie17 f05d8959c9
Merge pull request #32981 from woocommerce/fix/32962_multisite_disable
Make sure we also disable WooCommerce Admin on a multi site
2022-05-12 15:59:16 -03:00
Lourens Schep efc11d7fe2 Add changelog 2022-05-12 13:31:19 -03:00
Peter Fabian d88d01a982
Merge pull request #32919 from YordanSoares/fix-broken-urls-unicode
Fix broken URLs of recommendations from Unicode
2022-05-12 15:21:52 +02:00
Lourens Schep 7d23a2b7c8 Make sure we also disable WooCommerce Admin on a multi site 2022-05-12 10:06:25 -03:00
Chi-Hsuan Huang 4992899d84
Merge pull request #32975 from woocommerce/fix/32959-product-task-text-shown-before-accordion-is-expanded
Fix product task text shown before accordion is expanded on stack layout
2022-05-12 15:26:04 +08:00
Chi-Hsuan Huang 8440400f3c Set fixed width for experimental product layout 2022-05-12 14:08:03 +08:00
Chris Aprea 3e1d7ac99b Copy changes and remove console log 2022-05-12 14:46:06 +10:00
Chris Aprea c6836e270e Hardcode experiment name. 2022-05-12 13:11:42 +10:00
Ilyas Foo 713198f5ed Renames to increase clarity 2022-05-12 10:41:15 +08:00
Ilyas Foo f7263c60ff Changelogs 2022-05-12 10:41:15 +08:00
Ilyas Foo 481b1e8566 Add backend experiment logic 2022-05-12 10:41:15 +08:00
Ilyas Foo 16c36e1f7d Import hook from onboarding 2022-05-12 10:41:15 +08:00
moon 14ff4f63ee Add changelog 2022-05-11 19:12:35 -07:00
moon 7c06b4325b Use the core version for the @deprecated tags 2022-05-11 19:11:16 -07:00
Chi-Hsuan Huang 5453737747 Fix product task text shown before accordion is expanded on stack layout 2022-05-12 09:56:53 +08:00
Chi-Hsuan Huang 1ccacd95ab Add changelog 2022-05-12 09:24:37 +08:00
Chi-Hsuan Huang 03731c64d5 Fix notice on emptry product page 2022-05-12 09:24:08 +08:00
Chris Aprea 022c60f9e5 Tidy up experiment code and conditional rendering for the onboarding steps component. 2022-05-12 10:32:54 +10:00
Joel T 8e04383fb0 Enabling reminder bar for both experiments and control 2022-05-11 16:18:51 -07:00
Joel T 27cecd9b83 Hiding badge when remaining tasks is now zero 2022-05-11 16:18:51 -07:00
Joel T 29e521dca0 Reworking condition to allow reminder badge with corret list for all experiment states and control 2022-05-11 16:18:51 -07:00
Joel T 46d6e6dd3e Updating badge for tasks that complete with no page refresh 2022-05-11 16:18:50 -07:00
Joel T 3b28616640 Altering badge logic to function based on experiments instead of feature flag 2022-05-11 16:18:50 -07:00
Joel T 6693e9fba8 Correcting spacing manually since autoformatter isn't working 2022-05-11 16:18:50 -07:00
Joel T cd2b9732dd Adding changelog 2022-05-11 16:18:50 -07:00
Joel T 3a443234ea Adding basic support for tasks badge to woo navigation 2022-05-11 16:18:50 -07:00
Joel T 18e0af4c29 Adding badge to legacy menu for onboarding tasks remaining 2022-05-11 16:18:50 -07:00
Joel T 697278b69c Updating changelog 2022-05-11 16:14:26 -07:00
Joel T 9cd5a05237 Adding changelog 2022-05-11 16:11:56 -07:00
Joel T 2ac65955a3 Supressing warnings originating from metadata functions 2022-05-11 15:59:49 -07:00
Jorge A. Torres 82e6e31903
Merge pull request #32968 from woocommerce/fix/download_dir_table_key
Fix/download dir table key
2022-05-11 18:25:56 -03:00
louwie17 ed2adee551
Merge pull request #32966 from woocommerce/fix/32962_fatal_error_wc_admin_conflict
Add FeaturePlugin facade under the Admin namespace to avoid conflict WCA conflict
2022-05-11 17:57:12 -03:00
barryhughes d3bf32a147 Prefer get_var() over get_col(). 2022-05-11 20:12:20 +00:00
Moon 9720874f50
Merge pull request #32954 from woocommerce/update/32883-update-react-dates-dependency
Update react-dates to 21.8.0
2022-05-11 12:49:16 -07:00
Lourens Schep ce292870c3 Add changelog 2022-05-11 16:41:58 -03:00
barryhughes 44bb55452a Update install versions test :-/ 2022-05-11 19:28:41 +00:00
barryhughes 0d1da4e8bf 6.5.1 update routine for approved download directories. 2022-05-11 18:32:55 +00:00
Lourens Schep 4a2a94eb8c Add FeaturePlugin facade under the Admin namespace to avoid conflict WCA conflict 2022-05-11 14:54:02 -03:00
barryhughes f994ba1839 Apply max size to URL col in download directories table. 2022-05-11 17:07:32 +00:00
Jorge A. Torres 4ef86419da Add changelog entry 2022-05-11 11:42:35 -03:00
Jorge A. Torres 992f936fae Check for `recorded_sales` op data in COT migration tests 2022-05-11 11:42:35 -03:00
Chris Aprea aa8835bfce Merge branch 'trunk' into add/experiment-subscriptions-admin-menu-1 2022-05-11 17:04:29 +10:00
Chris Aprea f66a8c5b0f Add basic experiment functionality. 2022-05-11 15:37:14 +10:00
Ilyas Foo 016a23f202
Merge pull request #32941 from woocommerce/dev/32635-implement-product-task-experiment
Add ExPlat call for product task experiment
2022-05-11 13:03:27 +08:00
James Allan 5eb81985e4 Add changelog 2022-05-11 12:11:32 +10:00
Chi-Hsuan Huang edbfd5bf93
Merge pull request #32937 from woocommerce/update/convert-woo-tracks-to-ts
Convert `@woocommerce/tracks` to TS
2022-05-11 09:57:27 +08:00
James Allan 077d68eecd Remove unused maestro card SVG file 2022-05-11 11:57:08 +10:00
Chi-Hsuan Huang 79814ccccf
Merge pull request #32936 from woocommerce/update/memoize-one
Remove `memoize-one` from woo admin & update it to ^6.0.0 for woo components
2022-05-11 09:55:40 +08:00