Commit Graph

102 Commits

Author SHA1 Message Date
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 7ef8f4d156 Invalidate unknown product transients Closes #6815 2014-12-30 15:27:08 +00: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
Manos Psychogyiopoulos 4b04701cc8 add display_prices in variation data
The commit introduces 3 changes:
1. It adds 2 extra fields to the available_variations array,
display_price and display_regular_price, to be used by extensions in
cases like
https://github.com/woothemes/woocommerce-product-addons/issues/19
2. Introduces a get_display_price() function in WC_Product to retrieve
product prices incl or excl tax relative to the
woocommerce_tax_display_shop setting.
3. Fixes a minor issue where passing a 0 price to
get_price_including_tax() or get_price_excluding_tax() results in a
wrong output.
2014-12-03 11:28:04 +02:00
claudiosmweb 676549b4ab Fixed docblock for WC_Product::get_categories() 2014-12-01 22:09:42 -02:00
Bryce 83a457b29c improve get_rating_count() for rating-less reviews
Should close #6839.

According to `woocommerce_enable_review_rating` &
`woocommerce_review_rating_required`, it will do a different DB query,
so that when reviews without ratings are allowed, it will do a query
that counts those comments as reviews.
2014-11-27 14:32:09 +07:00
Barry Kooij 47cc448028 Added correct docblock. 2014-11-21 22:34:30 +01:00
Barry Kooij 4b539e7a9a Merge branch 'master' of github.com:woothemes/woocommerce 2014-11-21 22:31:17 +01:00
Barry Kooij 6ebadd572a Added correct docblock. 2014-11-21 22:31:09 +01:00
Michael Tieso 70d5fc834a Spelling correction - calculdate to calculate 2014-11-21 13:26:32 -08:00
claudiosmweb 74ba11c189 Removed some unused code 2014-11-19 21:36:47 -02:00
claudiosmweb e87aefc8e0 Fixed missing initial $query = array() 2014-11-19 16:26:10 -02:00
claudiosmweb f34cead914 Removed old code in favor of wc_tax_enabled() and wc_prices_include_tax() 2014-11-18 14:45:29 -02:00
Tamara Zuk 20655d367d Introduce `woocommerce_product_is_on_sale` filter
This filter is useful for extensions like Measurement Price Calculator
which alter the product price quite a bit, but would still like the
sale badge to appear :)

Current workaround is to use three filters ( `woocommerce_get_price`,
`woocommerce_get_regular_price`, and `woocommerce_get_sale_price` )
which most extension may be using already, but not all need/want to
alter these prices.
2014-11-14 18:00:03 -05:00
Mike Jolley cb8fe34b4c get_base_tax_rates() + filter. Closes #6668 2014-11-11 11:56:17 +00:00
Mike Jolley e4b212cb3a [2.2] Fix stock report queries Closes #6565 2014-10-21 14:50:18 +01:00
Mike Jolley 8766cfa6df Tweak woocommerce_get_price_html_from_to in #6455 2014-10-17 16:25:54 +01:00
Mike Jolley 2668f0b8dd Merge pull request #6455 from paulwilde/from-to-filters
Introduce filters to get_price_html_from_text() and get_price_html_from_to()
2014-10-17 16:25:16 +01:00
Tamara Zuk f34187d5d3 Allow for non-integer stock quantities
It looks like a3b522aff8 removed this
ability.
This would be very useful for extensions like Measurement Price
Calculator.
2014-10-17 00:52:56 -04:00
Paul Wilde 279c01d005 Introduce filters to get_price_html_from_text() and get_price_html_from_to(). 2014-10-02 20:11:34 +01:00
Illimar Tambek fb19f5b9c5 Improve naming & comments 2014-09-17 11:27:43 +03:00
Illimar Tambek 386011ffae Allow getting rating count for a specific rating number 2014-09-17 11:03:10 +03:00
Mike Jolley a3b522aff8 Prepare update queries. 2014-09-16 10:45:28 +01:00
Mike Jolley 3a4ba6e4c8 For regular products, ensure stock level saves on product creation. 2014-09-10 23:55:40 +01:00
Mike Jolley c4ef86d44e scrutinizer patches 2014-09-08 00:37:55 +01:00
Tamara Zuk 9c7826319c Coding Standards: Abstract classes
* fixed indentation - swapped spaces for tabs at start of line, swapped
tabs for spaces min-line for alignment
* removed instances of `@return void` and `@access public`
* improved readability

@see http://make.wordpress.org/core/handbook/coding-standards/php/
2014-08-31 01:49:58 -04:00
Mike Jolley c51fac23e0 Availability with backorders not requiring notification. 2014-08-15 15:29:14 +01:00
Mike Jolley 3f53512c7f Fix up visibility of stock options, drop downs, and get_availability() when parent is managing stock for a variation.
Fixes #6017
2014-08-13 15:03:30 +01:00
Mike Jolley 760cd6861c Small refactor of is_visible
Also returns false for non-published products and fixes #5955
2014-08-04 11:19:58 +01:00
Mike Jolley 029bbbec39 Updated reports 2014-07-25 15:46:19 +01:00
Mike Jolley 5e1bc4aeb1 Tweak get_availability 2014-06-27 14:46:39 +01:00
Mike Jolley c2475c2073 Merge pull request #5745 from claudiosmweb/4164-feature-products-api
Products API - PUT/POST/DELETE
2014-06-27 13:14:20 +01:00
Mike Jolley 50a4c5bd23 Merge branch 'variation-stock-management'
Conflicts:
	includes/class-wc-product-variation.php
2014-06-27 11:15:42 +01:00
Mike Jolley 6390e387e2 Additional check for product coupons and sale product exclusion. Fixes #5697 2014-06-25 13:46:47 +01:00
Mike Jolley 0f6f04e017 Added wc_stock_amount() core function and replaced intval
#4612
2014-06-25 11:25:28 +01:00
claudiosmweb 770d81091d fixed a error when get the thumbnail by API
Fixed the error:

PHP Notice: Trying to get property of non-object in wp-includes/post-template.php on line 29
2014-06-24 14:56:33 -03:00
Mike Jolley 3ca70b30f5 Add sanity check to stock status change 2014-06-24 13:01:34 +01:00
darkrain 8f530a156c bugfix in get_related() - return trash posts 2014-06-24 13:11:10 +07:00
darkrain ea476af2ca add filter to method get_sku() 2014-06-19 22:28:49 +07:00
Mike Jolley 375a0e2652 static WC_Tax class - no need for a constructor in this 2014-06-12 16:47:43 +01:00
Coen Jacobs 6aa9bcadab Added product id parameter to related posts filters 2014-05-21 11:35:54 +02:00
Tamara Zuk 651f1ac96f Introduce woocommerce_product_backorders_allowed filter 2014-05-04 17:29:43 -04:00
Mike Jolley ca9955fa9a Update stock amounts with DB queries Closes #5367
@claudiosmweb and @coenjacobs please review
2014-04-25 15:28:02 +01:00
Mike Jolley 3d8f7963df Update abstract docblock 2014-04-25 12:33:14 +01:00
Mike Jolley 0e1fcbda64 Abstract product constructor
Check for numeric $product, and expand the checking to see if its
passed a post object. Fixes #5341
2014-04-25 10:19:00 +01:00
Mike Jolley 9c37d83f11 Let get_file get the first file if no ID is defined
#5296
2014-04-24 16:00:35 +01:00
Mike Jolley 2a27663f1f get_image_id method + use in email template
Closes #5288
2014-04-08 15:02:11 +01:00
Patrick Rauland e4296cc5f7 fixing cool typo. see #5189 2014-03-21 16:37:26 -05:00