Mike Jolley
9f57025a1e
Remove unnecessary stock notice
...
Closes #7990
2015-04-23 11:04:16 +01:00
Mike Jolley
9debd84a7f
Merge pull request #7978 from InoPlugs/patch-3
...
[2.3] Update abstract-wc-order.php
2015-04-20 11:12:25 +01:00
InoPlugs Webdesign
520282ff16
Update abstract-wc-order.php
...
Using a wrong key name -> 'cart_discount_tax' is calculated wrong a few lines below (= $cart_subtotal_tax)
2015-04-18 14:44:39 +02:00
Spreeuw
1e2d0775c4
tax text for negative shipping (refunds)
2015-04-17 12:45:32 +02:00
Spreeuw
3f0b589797
Make get_shipping_to_display compatible with refunds
2015-04-17 12:38:08 +02:00
Mike Jolley
467a269175
Only set author for user added notes so system notes can be distinguished
2015-04-17 11:23:09 +01:00
Mike Jolley
9f65d2a1fc
Added priorities for shipping methods to give more control over defaults.
...
Closes #7871
2015-04-13 15:32:57 +01:00
Mike Jolley
06f2ac2f09
[2.3] Remove rounding from shipping cost to greater precision with taxes
2015-03-31 13:59:17 +01:00
Mike Jolley
c410771de2
[2.3] Calculate taxes should save _line_tax_data
2015-03-31 13:21:10 +01:00
Mike Jolley
c6dae2b286
Merge pull request #7834 from SiR-DanieL/scrutinizer-issues
...
Small tweaks and style fixes
2015-03-30 10:33:27 +01:00
Nicola Mustone
95cdb0390f
fix related products error
2015-03-27 17:52:21 +01:00
Nicola Mustone
214a0b669f
splitted get_related for complexity
2015-03-27 17:28:26 +01:00
Nicola Mustone
d2af01df5b
scrutinizer suggested tweaks
2015-03-27 16:15:40 +01:00
Mike Jolley
23932dbfca
Default calculate_taxes to base
...
Closes #7765
2015-03-27 10:42:26 +00:00
Mike Jolley
ca934ba0d9
Add get methods for length, width, height and add filters
...
Closes #7617
2015-03-24 16:52:26 +00:00
Mike Jolley
70bf6fc842
[2.3] prices_include_tax boolean fix
...
Closes #7788
2015-03-23 13:35:40 +00:00
Mike Jolley
f04ebeb78e
has_enough_stock - use get_stock_quantity
...
Closes #7779
2015-03-20 10:40:53 +00:00
Mike Jolley
70d125ae96
[2.3] Fix - get_total_discount() function with certain tax setups.
...
Revised how discounts/discount taxes are stored for consistency. Always
store ex. tax to make data retrieval easier, and to ensure totals are
correct after settings changes. Backwards compatibility maintained
through use of order versioning.
#7728
2015-03-16 12:17:09 +00:00
Mike Jolley
d49b5eb182
pass args to order amount filters
...
Closes #7718
2015-03-13 10:03:08 +00:00
Mike Jolley
6447d4081f
Prevent notice
...
Closes #7705
Fixes #7704
2015-03-13 09:25:24 +00:00
Mike Jolley
c44100f9e7
wc_sanitize_tooltip
2015-03-13 09:14:28 +00:00
Mike Jolley
8554796c4b
Show calculate total when shipping is needed, but shipping is hidden.
...
Closes #7650
2015-03-10 16:57:43 +00:00
Barry Kooij
44d8bee22c
Use round instead of number_format
2015-03-09 18:10:49 +01:00
Barry Kooij
245a2cf4e7
Added the option to not round the line total.
2015-03-09 18:06:31 +01:00
Mike Jolley
3fc7a0ae65
Allow wc_attribute_label to support product-level attribute names.
...
Closes #7662
2015-03-09 13:40:07 +00:00
Mike Jolley
fa0be55b01
transient cache dashboard reports
...
Closes #7641
2015-03-09 11:07:49 +00:00
Tamara Zuk
d4b08daa64
Avoid 'division by zero' warnings
...
SHA 85befad283
does not avoid these
warnings if `$inc_tax` is `false`.
2015-03-06 17:46:31 -05:00
Mike Jolley
568a0fe4fa
Tweak international delivery
...
Fixes #7651
2015-03-06 14:45:04 +00:00
Barry Kooij
c45c4fd1a2
optimize PR#7605
2015-03-06 15:06:24 +01:00
Tamara Zuk
0e4cea8e85
Introduce `WC_Order::get_cancel_order_url_raw()` method
2015-03-03 02:01:17 -05:00
Claudio Sanches
f2fc3b151f
Merge pull request #7562 from tjuris/get-related-terms-filters
...
Apply filters to product/tag terms when querying related products
2015-03-02 10:39:31 -03:00
Tanel Jüris
fe60425eeb
Rename filter prefix from wc_ to woocommerce_
2015-03-02 12:09:24 +02:00
Mike Jolley
d98569327d
Check payment title exists before output.
2015-03-02 10:03:30 +00:00
Barry Kooij
ffc436957b
Removed double @property comment
2015-02-26 17:14:06 +01:00
Tanel Jüris
d9a568bbea
Apply filters to product/tag terms when querying related products
2015-02-25 16:02:31 +02:00
Mike Jolley
26487a5734
Fix - Settings API - allow multiselect fields to be emptied.
...
Closes #7542
2015-02-24 12:12:42 +00:00
Mike Jolley
d9455994c8
Use 30 days instead of year for transients to avoid bugs in memcache plugins.
...
Closes #7520
2015-02-24 12:02:56 +00:00
Mike Jolley
4c411a69e7
* Fix - Saving an order needs to save the discount amount ex. tax like
...
the cart.
* Tweak - Show discounts inc. tax when showing order totals inc. tax.
Closes #7532
@barrykooij @claudiosmweb How does this look? Looks like we were saving
order discounts inconsistent with the cart/checkout
2015-02-23 17:39:57 +00:00
Mike Jolley
6c9562112f
Fix Related post offset.
2015-02-20 16:17:45 +00:00
Mike Jolley
44cf2c2b70
Filter before max_related_posts
2015-02-16 16:48:11 +00:00
Mike Jolley
5c1a0d92e8
Related posts - replace ORDER BY RAND() with random offset.
...
Closes #7436
2015-02-16 13:16:18 +00:00
Mike Jolley
969e2d3b18
Stock status when updating out of stock product.
...
Fixes #7402
2015-02-16 12:14:10 +00:00
Paul Wilde
c913316f8b
Introduce wc_get_page_permalink.
2015-02-15 19:13:22 +00:00
Mike Jolley
30abed2f9e
Merge pull request #7375 from tamarazuk/rating-count-fix
...
Fix average product rating when ratings are not required
2015-02-12 00:04:26 +00:00
Tamara Zuk
7eaae2d561
Fix average product rating when ratings are not required
...
If ratings are not required, the total rating count was counting all
reviews which skewed the average rating. In other words, reviews with
no rating were counted as a “zero” rating in the average rating
calculation. This bug was introduced in
83a457b29c
which provided a fix for #6839 .
This change introduces a new product method `get_review_count()` which
can be used to accurately calculate the total number of reviews for a
product. Some instances of `get_rating_count()` were replaced with
`get_review_count()` where appropriate. Additionally, the
`single-product/rating.php` template was adjusted to display the
correct number of customer reviews and ratings in rich snippets. I’ve
also included the `bestRating` rich snippet detailed
[here](http://schema.org/AggregateRating ). The version number was
adjusted to 2.3.2 on that template as I think this is a larger change.
2015-02-11 17:55:16 -05:00
Mike Jolley
43c24feffd
Item meta removal query in order class.
2015-02-11 22:14:24 +00:00
Brent Shepherd
f1fa927f57
Fix WC_Order::payment_complete() on back-end
...
SHA: c038001eab
changed `WC_Abstract_Order::payment_complete()` to use
WC()->session->set( 'order_awaiting_payment' ) instead of
`WC()->session->order_awaiting_payment`, but `WC()->session` is only
set on front-end requests, meaning any extension that tries to complete
payment on an order from the back-end would cause a fatal error.
2015-02-10 16:55:47 -08:00
Claudio Sanches
22c4f02bbf
Used filtered comment for woocommerce_new_customer_note action, closes #7349
2015-02-10 14:44:28 -02:00
Claudio Sanches
0558c3c286
Added woocommerce_product_get_rating_html filter for WC_Product class, closes #7337
2015-02-10 13:01:04 -02:00
Mike Jolley
840efcaa00
is_on_sale should compare type Fixes #7344
2015-02-10 12:34:53 +00:00
Mike Jolley
893babaaef
woocommerce_product_get_weight filter Closes #7319
2015-02-10 11:18:38 +00:00
Mike Jolley
037242a9a2
More docblock tweaks
2015-02-03 16:03:28 +00:00
Mike Jolley
74abdf27c9
Cast to array
2015-02-03 15:06:08 +00:00
Mike Jolley
f032a9c7dd
Missing props
2015-02-03 14:44:57 +00:00
Mike Jolley
f93e027b09
validate_multiselect_field had dead var
2015-02-03 14:05:09 +00:00
Mike Jolley
f711ef32ce
Missing bracket in previous commit #copypastefail
2015-02-03 13:16:41 +00:00
Mike Jolley
7c019c0c50
More docblocks; the check for WP_POST isn't needed as the second case (isset) runs regardless and is true for posts
2015-02-03 13:13:07 +00:00
Mike Jolley
c038001eab
Docblocks for order/product
2015-02-03 12:57:08 +00:00
Mike Jolley
dc5b8d9710
@var
2015-02-03 12:28:15 +00:00
Mike Jolley
6bc269858a
tweak docblock
2015-01-30 14:30:10 +00:00
Claudio Sanches
d6023818fd
Fixed the increase and decreate of coupons usage count
2015-01-30 12:14:34 -02:00
Claudio Sanches
def250e912
Display taxes labels in order totals when order has refunded, closes #7229
2015-01-29 18:50:08 -02:00
Claudio Sanches
c995f23354
Fixed WC_Abstract_Order coupon methods
...
@mikejolley
2015-01-26 16:48:03 -02:00
Claudio Sanches
8ff08e70af
Fixed the WC_Abstract_Order::get_user_id() return type and fixed the orders customer_id
2015-01-26 14:41:19 -02:00
Mike Jolley
54e025939b
Use get_post_status to avoid out of date order data.
...
Partly related to #7208
2015-01-26 13:07:29 +00:00
Brent Shepherd
95d87e28d6
Do not set property when calling __get()
...
SHA: 100b95a
tweaked the `__get()` magic method in `WC_Product` to:
* only call `get_post_meta()` once; and
* set `$this->$key` to save the overhead of calling `__get()` every
time that property needs to be accessed.
However, in the process, it also set an empty value (`''`) - the default
return value of `get_post_meta()` for every single value accessed on
the product object, meaning that any calls to `isset()` after attempting
to get that value would return `true`, even if `metadata_exists()` for
that property would return false (and no value is set in memory).
2015-01-23 15:01:10 -08:00
Claudio Sanches
04c584ccf6
Added properties docs for abstract product class
2015-01-23 15:51:33 -02:00
Scrutinizer Auto-Fixer
19f660171e
Scrutinizer Auto-Fixes
...
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2015-01-23 14:37:20 +00:00
Mike Jolley
7f2a943075
Docblocks
2015-01-23 14:35:17 +00:00
Mike Jolley
2584041700
wc_price enhancements
...
- Renamed some 2.3 methods for consistency
- Allow more args to be passed to wc_price to control output
- Filter wc_price args which Closes #7188
- wc_get_price_decimal_separator function
- wc_get_price_thousand_separator function
- wc_get_price_decimals function
2015-01-23 11:50:32 +00:00
Mike Jolley
91de767442
Product constructor setting post incorrectly
2015-01-20 14:00:30 +00:00
Mike Jolley
5404006b29
MAP Url method
2015-01-20 13:31:02 +00:00
Mike Jolley
de4129f9b2
WP_POST docs
2015-01-20 13:20:22 +00:00
Mike Jolley
5ab35bf212
Protected variables
2015-01-20 13:01:19 +00:00
Mike Jolley
baea8f9ad4
Product class properties
2015-01-20 13:00:56 +00:00
Mike Jolley
b941636068
Deprecate unused and pointless get_billing_address() get_shipping_address() methods
...
@claudiosmweb
2015-01-20 12:39:21 +00:00
Mike Jolley
df66e0bcc8
Docblocks and code fixes in order class
2015-01-20 12:34:40 +00:00
Mike Jolley
2e624995b4
More magic properties and variable declarations in order class
2015-01-20 12:07:33 +00:00
Mike Jolley
ea13b90340
Define magic properties for address data
2015-01-20 11:23:17 +00:00
Mike Jolley
c0bea39c95
Seeing if magic properties are recognised
2015-01-20 11:06:15 +00:00
Mike Jolley
a494bf84de
Check if already set before setting in WC_Session.
...
Prevents unintended dirty sessions. Fixes #6846
2015-01-20 09:46:57 +00:00
Mike Jolley
3716329b16
Prevent error when user does not exist
2015-01-19 14:50:06 +00:00
Mike Jolley
fef41c149c
@uses WP_POST
2015-01-15 15:03:12 +00:00
Mike Jolley
dc902ecfed
form_fields docblock
2015-01-15 15:03:12 +00:00
Claudio Sanches
22da603567
Simplify commerce hosted payments feature
2015-01-13 13:40:43 -02:00
Andrew Benbow
fa8aeb605c
Update abstract-wc-order.php
2015-01-12 12:34:53 +00:00
James Koster
9cf1a8e7e8
is_sold_individually() tweak. closes #7041
2015-01-07 10:03:49 +00:00
Claudio Sanches
d1f9cbfcf2
Merge pull request #6954 from SiR-DanieL/patch-2
...
Introduced woocommerce_get_product_attributes filter
2015-01-05 13:39:25 -02:00
Mike Jolley
cab9e14fcd
Use number format instead of round in get_item_subtotal()
...
Closes #6913
2015-01-05 11:42:10 +00:00
Mike Jolley
f847b92a0f
Merge branch 'wc-geolocation'
2015-01-05 10:18:25 +00:00
Claudio Sanches
b4cc3cfcd5
Improved the widget title
2015-01-02 11:05:06 -02:00
Mike Jolley
7ef8f4d156
Invalidate unknown product transients Closes #6815
2014-12-30 15:27:08 +00:00
Mike Jolley
6800ee0ec3
Base vs default
2014-12-23 17:34:05 +00:00
Nicola Mustone
d6bf1e81f9
added variation ID in order stock notes
2014-12-23 12:01:11 +01:00
Bryce
1c31af94f5
remove var keyword in WC_Shipping_Method
2014-12-16 18:38:58 +07:00
Nicola Mustone
7cec3c9f0b
introduced woocommerce_get_product_attributes filter
2014-12-15 14:40:23 +01:00
Mike Jolley
100b95ae4f
Tweak the get magic method in product class
2014-12-11 14:54:56 +00:00
Claudio Sanches
a579ce4578
Merge pull request #6894 from franticpsyx/add_shop_prices_in_variation_data_array
...
Add display_prices in available_variations array
2014-12-10 15:52:57 -02:00
Mike Jolley
fd15ac4c64
Allow a cancelled order to be marked paid, if there is a payment delay
...
Closes #6810
2014-12-10 16:54:08 +00:00
Claudio Sanches
ec30dab6c4
Improved the colorpicker field
2014-12-09 10:10:59 -02:00