Gerhard Potgieter
b1d9363918
Add wc payments to extensions addons page.
2020-11-09 14:19:11 +02:00
Christopher Allford
e711a447fe
Fixed order account creation
2020-11-04 16:56:32 -03:00
Néstor Soriano
6e5cc0c2f2
Merge pull request #28052 from woocommerce/php8_tighten_non-strict_date_comparison
...
PHP 8.0 - Use strict comparison to compare post dates
2020-11-04 15:23:16 +01:00
Néstor Soriano
09e066fc6e
Update includes/data-stores/class-wc-data-store-wp.php
...
Update `@since` in new function to 4.8.0
2020-11-04 13:09:52 +01:00
David Marín
c3ba17ae71
Fixing spaces in empty lines
2020-11-03 13:53:19 +01:00
David Marín
9c1de7ca96
Optimizing memory usage
...
Removing the potential undesired retrieval of hundreds or thousands of unreadable WC_Product objects into memory just to filter them out immediately.
This change prevented some out-of-memory situations in our site.
2020-11-03 11:34:34 +01:00
James Allan
82b68b4914
Use strict comparison to compare post dates
...
With PHP 8.0, non-strict comparisons between integers and strings containing
non-numeric characters are being tightened. This affects comparisons like:
0 < '0000-00-00 00:00:00'
PHP 8.0 that equates to true whereas prior to 8.0 it would be false.
More details of this change can be found at: https://wiki.php.net/rfc/string_to_number_comparison
2020-11-02 11:10:30 +10:00
jozeflambrecht
6c86950075
Update class-wc-validation.php
...
Add support for validation BE postcodes
https://github.com/woocommerce/woocommerce/issues/28144
2020-10-29 19:11:36 -04:00
Rodrigo Primo
e38d0dfdb1
Merge pull request #28005 from woocommerce/fix/issue-27945
...
Replace jQuery.ready function with recommended way since jQuery 3.0 c…
2020-10-29 18:06:02 -03:00
Rodrigo Primo
b612c4f041
Merge pull request #28064 from woocommerce/fix/27087
...
Improves i18n of string displayed during checkout
2020-10-29 17:55:02 -03:00
Néstor Soriano
604958c4a8
Merge pull request #28103 from woocommerce/fix/issue-27756
...
Fix/issue 27756
2020-10-28 10:06:55 +01:00
Roy Ho
5007d17596
Merge pull request #27514 from helgatheviking/has_options
...
Add woocommerce_product_has_options filter to has_options() method
2020-10-27 09:48:26 -07:00
roykho
4abdf2d78b
Remove underline tag and allow themes to style to their liking
2020-10-27 09:10:13 -07:00
Roy Ho
99fcafee8f
Merge pull request #28027 from woocommerce/pp_response_check_for_cart
...
Check the cart exists before emptying it after handling PayPal response
2020-10-27 08:54:56 -07:00
roykho
4c079ea99e
Update SSR version to check against major versions only closes #27972
2020-10-27 08:16:35 -07:00
roykho
3b022be68b
Prevent variable product from adding to cart when no variations are selected closes #27756
2020-10-26 11:21:28 -07:00
Shiki
94ecfcab34
Orders API: Add parent_name to schema
2020-10-26 13:28:04 -03:00
Shiki
48d595ed71
Orders API: Reorganize and place parent_name in a separate section
2020-10-26 13:28:04 -03:00
Shiki
52739ba9ee
Orders API: Add parent_name to line_items for variable products
2020-10-26 13:28:04 -03:00
Claudio Sanches
19e4c7ac7c
Merge pull request #28094 from woocommerce/revert/27289
...
Revert changes introduced in #27289
2020-10-26 12:39:11 -03:00
Roy Ho
c96a642e8a
Merge pull request #28067 from woocommerce/fix/27529
...
Fix: use the correct parameter when calling get_avatar()
2020-10-26 07:46:51 -07:00
Claudio Sanches
c5ff759d61
Revert changes introduced in #27289
2020-10-26 10:26:29 -03:00
Rodrigo Primo
80c3f343a4
Merge pull request #28062 from PlexusLLC/fix-sorting-capability
...
Fix incorrect capability for product sorting link
2020-10-24 15:10:00 -03:00
Rodrigo Primo
1b40e13f99
Merge pull request #27856 from sudoshreyansh/fix/27831
...
Fixed update term message. Issue: #27831
2020-10-24 14:57:06 -03:00
Rodrigo Primo
92153ac3b3
Merge pull request #27723 from alexstewartja/master
...
Introduced fine-grained cultural adaptation for Jamaican-based WooCommerce stores
2020-10-24 14:44:07 -03:00
Rodrigo Primo
3ed300a4aa
Merge pull request #27607 from wpdesk/bugfix/cart-weight-float
...
Fixed cart weight return type.
2020-10-24 14:12:03 -03:00
Claudio Sanches
1427a39be1
Merge pull request #28074 from shahlin/master
...
Minor docblock grammar/typo/casing fixes
2020-10-23 17:33:41 -03:00
Roy Ho
ecd08277f9
Merge pull request #28070 from NicholasMacedo/patch-1
...
Update class-wc-product-variable.php
2020-10-23 13:12:04 -07:00
Shahlin Ibrahim
e06466b2b7
Minor docblock grammar/typo/casing fixes
2020-10-23 17:27:39 +04:00
Nicholas Macedo
815fd01a98
Update class-wc-product-variable.php
...
Fix the typo on line 416 according to Issue #28066
2020-10-22 20:37:36 -04:00
Rodrigo Primo
09faf8ba84
Fix: use the correct parameter when calling get_avatar()
...
`WC_Admin_Dashboard::recent_reviews()` was calling `get_avatar()` passing `$comment->comment_author` which is not one of the list of parameters that the function accepts to get the avatar. As a result, the widget that displays the recent reviews in the admin dashboard was never displaying the avatar of the user that left the review. This commit fixes this issue by passing `$comment->comment_email` instead. I opted to use `$comment->comment_author` as it should be available for reviews left both by authenticated and anonymous users and because getting the comment object wouldn't be so simple (either we need to perform an extra query for each review or deprecate the `woocommerce_report_recent_reviews_query_from` filter).
2020-10-22 17:43:59 -03:00
Rodrigo Primo
e91872c1a8
PHPCS fixes
2020-10-22 17:34:47 -03:00
Rodrigo Primo
6bde9fd8a5
Replace WPCS deprecated syntax
...
Using the WPCS native whitelist comments is deprecated. So this PR just replaces all instances of `// WPCS: XSS ok.` found in `includes/wc-cart-functions.php` with the PHPCS native "// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped". I found this while working on another issue in the same file.
2020-10-22 16:03:34 -03:00
Rodrigo Primo
4e5fb5724c
Improves i18n of string displayed during checkout
...
This commit improves the i18n of a string displayed during checkout showing the total amount of the order when the store is configured to display prices inclusive of taxes.
Before string concatenation was used to build the final string which is almost always a bad practice from i18n point of view (https://codex.wordpress.org/I18n_for_WordPress_Developers#Best_Practices ). This commit uses sprintf() and two separate strings to make translation easier.
2020-10-22 15:38:07 -03:00
pjv
f03bfb85da
Fix incorrect capability for product sorting link
...
Fixes #28049
2020-10-22 13:03:35 -05:00
Rodrigo Primo
05cc0882e5
Replace deprecated jQuery code in includes/emails/class-wc-email.php
...
This commit replaces a call to the now deprecated jQuery.fn.toggle(handler, handler...) (https://api.jquery.com/toggle-event/ ) with a jQuery.click(). The deprecated call was used in the page where admins can edit e-mail templates (example: wp-admin/admin.php?page=wc-settings&tab=email§ion=wc_email_customer_on_hold_order) to show or hide the contents of the template and at the same time change the label of the button. We are now using jQuery.click() with a if statement inside to decide which label to use.
2020-10-22 09:28:06 -03:00
James Allan
b1a2fa01a6
Check the cart exists before emptying it after PayPal response
2020-10-21 10:32:37 +10:00
Claudio Sanches
f7ecbbeb35
Prepare default branch to 4.8
2020-10-20 15:20:52 -03:00
Claudio Sanches
631c06020c
Merge pull request #27800 from gbiorczyk/fix/field-label-escaping
...
Escaping output for field label
2020-10-19 20:26:38 -03:00
roykho
8c73c5f2f8
Replace jQuery.ready function with recommended way since jQuery 3.0 closes #27945
2020-10-19 06:47:55 -07:00
Rodrigo Primo
0a81188e42
Merge pull request #27987 from woocommerce/php8/fix-required-parameters-after-optional-take-2
...
[PHP 8] Convert optional-before-required parameters into required parameters (take 2)
2020-10-17 09:42:20 -03:00
roykho
e8bcd464db
Update escape based on suggestion
2020-10-16 06:00:34 -07:00
Nestor Soriano
63ced34e2d
Convert optional-before-required arguments to required (take 2)
...
In PHP 8 required parameters after optional parameters in
function/method signatures trigger a deprecation notice. These type
of parameters are pointless since a value needs to always be
provided for them anyway, so they are actually de-facto required.
This commit converts all these not-so-optional parameters into
truly required parameters by removing their default values.
2020-10-16 13:08:31 +02:00
roykho
800cbdbc7e
Add missing escapes
2020-10-15 16:31:56 -07:00
roykho
ace411aacd
Fix billing email being parsed as a URL link when beginning of email contains www closes #25099
2020-10-15 14:25:03 -07:00
Rodrigo Primo
9155a78043
Merge pull request #27858 from Rowayda-Khayri/fixes
...
Add punctuation mark to function's docblock
2020-10-15 15:09:21 -03:00
Néstor Soriano
e4a109f0d1
Merge pull request #27763 from woocommerce/fix/27445
...
Remove protection as we already diff and update only if needed.
2020-10-15 10:01:34 +02:00
Claudio Sanches
e34681dbb4
Merge pull request #27696 from woocommerce/fix/version-race-conditions
...
Fix some race conditions in WC_Install
2020-10-14 20:18:47 -03:00
Claudio Sanches
d211f6ee5c
Merge pull request #27516 from KoolPal/patch-2
...
Renamed Postcode / ZIP to Pin code & renamed State / County to State for India
2020-10-14 19:51:46 -03:00
Claudio Sanches
0b41aff81b
Merge pull request #27546 from KoolPal/patch-1
...
Updated - Added postcode validation for India
2020-10-14 19:25:32 -03:00
Claudio Sanches
e581ffce27
Fixed missing "break"
2020-10-14 19:22:19 -03:00
Claudio Sanches
136c6e2916
Merge pull request #27779 from zzap/patch-2
...
Update properties for Serbia.
2020-10-14 18:09:56 -03:00
Claudio Sanches
23fe4f71bb
Merge pull request #27842 from sudoshreyansh/fix/27839
...
Fixed </strong> closing tag position. Issue: #27839
2020-10-14 18:06:10 -03:00
Claudio Sanches
537ec5d0e9
Merge pull request #27893 from dominic-ks/update-needs-payment-check
...
issue #24631 - Updated needs payment check to use order
2020-10-14 16:29:25 -03:00
Claudio Sanches
27e4288eab
Merge pull request #27934 from woocommerce/remove_get_product_from_item
...
Remove the remaining uses of $order->get_product_from_item()
2020-10-14 16:18:29 -03:00
Claudio Sanches
c530fc0d55
Merge pull request #27908 from woocommerce/fix/template-attachment-ids
...
restore $attachment_ids for product thumbnails template
2020-10-14 15:38:19 -03:00
Claudio Sanches
6ad79cf050
Fixed PHP notice
...
> PHP Notice: compact(): Undefined variable: gallery_image_ids in includes/wc-template-functions.php on line 1487
2020-10-14 15:37:12 -03:00
Claudio Sanches
47a7c6648a
Update includes/wc-template-functions.php
2020-10-14 15:29:24 -03:00
Vedanshu Jain
f65491d1b2
Merge pull request #27898 from woocommerce/add/allow-customise-reset-password-page-title
...
Use "Set Password" page title for lost-password endpoint when setting a password
2020-10-14 23:24:27 +05:30
Claudio Sanches
be4aacee93
Merge pull request #27483 from woocommerce/fix/27475
...
prevent regenerate image filter loop
2020-10-14 14:03:00 -03:00
Claudio Sanches
7d1ff1a655
Merge pull request #27310 from woocommerce/fix/27215
...
Fix deleting a tax class via WP CLI.
2020-10-14 14:00:33 -03:00
Ron Rennick
9cf2d81f60
Merge branch 'master' into fix/template-attachment-ids
2020-10-14 12:40:57 -03:00
Ron Rennick
8ec54fabe0
phpcs fixes
2020-10-14 10:27:58 -03:00
Ron Rennick
cd20044b13
Merge branch 'master' into fix/27215
2020-10-14 10:16:36 -03:00
vedanshujain
c01f32a390
Use default value if formatted value is not available
2020-10-14 14:51:19 +05:30
vedanshujain
8e12de5d3c
Merge branch 'fix/api/229-unit-test' of https://github.com/shiki/woocommerce into fix/api/229
2020-10-14 13:53:03 +05:30
Rua Haszard
95f4b5b81e
restore original comment (related changes are gone)
2020-10-14 12:35:32 +13:00
Rua Haszard
5e3713da75
check password-set user token before redirecting to set password form:
...
- this prevents the password reset process earlier (before the redirect)
- also now shows a notice informing the user that they need to log out
of (other) account
2020-10-14 12:26:51 +13:00
Rua Haszard
1f5601f0fe
ensure lost-password form only resets password for correct user:
...
- if a user is logged in, check their ID matches the ID in the reset
key / token
2020-10-14 12:12:01 +13:00
Rua Haszard
5e5d06cfab
show lost-password form when logged-in user:
...
- in the checkout signup use case, the user may be setting their
password in a logged-in browser session; they need to be able to set an
initial account password
2020-10-14 09:50:36 +13:00
Rua Haszard
b34ad5be5c
improve PHPdocs for get_endpoint_title and related hook:
...
- add @since (original since based on git blame)
- document all params
- add @since for newly-added params
- add docs for woocommerce_endpoint_{$endpoint}_title
2020-10-14 09:50:36 +13:00
Rua Haszard
6032962e59
use "Set password" title for lost-password endpoint for more actions:
...
- 'rp' and 'resetpass' are used in WordPress core
1079647d30/wp-login.php (L913)
- using 'newaccount' for checkout signup case
2020-10-14 09:50:36 +13:00
Rua Haszard
1eb02845aa
support overriding/customising password reset page title via `action`:
...
- get_endpoint_title now takes an extra `action` param
- this also is passed to the relevant hook (as an additional arg)
- woocommerce_endpoint_{$endpoint}_title
- for `lost-password?action=rp`, use `Set password`
- pass action query param through when using get_endpoint_title
2020-10-14 09:50:36 +13:00
Claudio Sanches
e655b44717
Fixed coding standards
2020-10-13 22:32:32 +05:30
Shiki
2e165e7558
Orders: Make display_key and _value meta available for v3 and v3
...
This resolves the intentionally failing
WC_Tests_API_Orders_V2::test_get_item_with_line_items_meta_data.
2020-10-13 22:32:31 +05:30
Shiki
a3f46e5526
Schema: Make display_key and *_value available for v3 and v2
...
This is just the schema and the actual functionality isn't implemented yet.
2020-10-13 22:32:30 +05:30
Shiki
b9ae830da5
Fix formatting in Orders V2 unit test
2020-10-13 22:32:30 +05:30
Shiki
f45e8b884b
Orders V3: Reuse WC_Order_Item->get_formatted_meta_data
...
Previously, I was using my own function. This time, we're using the function
available in WC_Order_Item but sanitizing the results after.
2020-10-13 22:32:30 +05:30
Shiki
2e92460df2
Orders V3: Include display_key and display_value in item meta_data
2020-10-13 22:32:30 +05:30
Shiki
d8ac282c80
Orders V3 Schema: Add display_key and display_value for meta props
2020-10-13 22:32:29 +05:30
James Allan
1fcedb5279
Removes the remaining uses of $order->get_product_from_item
2020-10-13 11:24:48 +10:00
sudoshreyansh
f1d89e6e78
Fixed taxonomy term message
2020-10-09 13:16:40 +05:30
Néstor Soriano
c15488d840
Merge pull request #27830 from woocommerce/php8/fix-round-function-with-non-numeric-argument
2020-10-09 08:01:44 +02:00
Rodrigo Primo
6861fdab5d
Update @version in which a filter was added
2020-10-08 17:03:09 -03:00
Jon Campbell
0fedb0db7a
Added filter for low stock notification emails ( #27819 )
...
* Adding new filter for low stock notification
* Update class-wc-emails.php
fixing whitespace
2020-10-08 17:02:09 -03:00
Ron Rennick
4a8898dfbd
restore $attachment_ids for product thumbnails template
2020-10-08 15:08:03 -03:00
Néstor Soriano
e4b78cedbf
Merge pull request #27748 from woocommerce/remove-leftovers-from-improved-filtering-by-attribute-for-variations
...
Remove leftovers from the reverted improved filtering mechanism for variations
2020-10-08 15:45:09 +02:00
Rodrigo Primo
0771138604
Merge pull request #27707 from dd32/php8/warnings
...
PHP8 Warning: Change __wakeup() to a public method
2020-10-08 10:01:21 -03:00
Néstor Soriano
ab529835fa
Merge pull request #27840 from woocommerce/php8/fix-required-parameters-after-optional
...
[PHP 8] Convert optional-before-required parameters into required parameters
2020-10-08 14:22:52 +02:00
Vedanshu Jain
8a9fa0d27b
Merge pull request #27587 from om4james/fix/26847-rest-api-auth
...
Fix HTTP 401 `woocommerce_rest_cannot_view` `Sorry, you cannot list resources` REST API response
2020-10-08 16:32:03 +05:30
Nestor Soriano
b71f876cba
Reintroduce the dependency injection related code.
...
After the League's Container package has been reintroduced, all the
code that implements the dependency injection mechanism in woocommerce
can be brought back as well.
2020-10-08 09:28:05 +02:00
James Collins
79dd557b77
Return true to indicate that authentication using this method was successful
2020-10-08 09:33:33 +08:00
Ron Rennick
175499b40a
Merge branch 'master' into fix/27215
2020-10-07 15:59:19 -03:00
Ron Rennick
577494796c
Merge pull request #27736 from woocommerce/fix/27681
...
Update taxonomy template file names to `-`
2020-10-07 15:23:11 -03:00
Ron Rennick
24ec59cf26
fix merge conflict
2020-10-07 15:19:05 -03:00
Ron Rennick
67a54b3aa3
Merge pull request #27289 from woocommerce/fix/27222
...
use first gallery image on single product when image not assigned
2020-10-07 15:06:30 -03:00
Dominic Vermeulen-Smith
c054a2803b
issue #24631 - Updated needs payment check to use order
2020-10-06 17:38:07 +01:00
Knyazevich
ce59afb2b9
Simplify drafts excluding logic (ref #24136 )
2020-10-06 18:11:58 +03:00
Knyazevich
f551c6c792
Exclude drafts from the "Shop page" select (ref #24136 )
2020-10-06 06:42:56 +03:00
Ron Rennick
ab4a46e32e
Merge pull request #27299 from woocommerce/fix/27116
...
allow variation image to be removed via REST API
2020-10-05 09:33:50 -03:00