Commit Graph

18254 Commits

Author SHA1 Message Date
Mike Jolley af32b3ea91 Product crud admin save routine (#12174)
* Initial props

* Work on admin saving

* Set/get attributes

* Atom was moaning about this before but no longer.

* Update get_shipping_class

* WC_Product_Attribute

* Use getter in admin panel

* Fix attribute saving

* Spacing

* Fix comment

* wc_implode_text_attributes helper function
2016-11-09 15:43:20 +00:00
Mike Jolley 611ac8b651 [Product CRUD] Product crud terms (#12149)
* Category and tag id handling

* Replace template functions

* Remove todo

* Handle default name in save function
2016-11-09 15:41:48 +00:00
Mike Jolley 7dd64662f0 [Product CRUD] Grouped Handling (#12151)
* Handle grouped product saving

* Update routine
2016-11-09 15:41:48 +00:00
Justin Shreve 5b09c9f063 [Product CRUD] Variable (#12146)
* [Product CRUD] Variable Products

* Handle PR feedback.
2016-11-09 15:41:25 +00:00
Mike Jolley f57601d755 Price handling 2016-11-09 15:41:08 +00:00
Mike Jolley 67c01ff101 wc_get_price_to_display 2016-11-09 15:41:08 +00:00
Mike Jolley 38ab3d63f6 get_price_including_tax/excluding_tax functions 2016-11-09 15:40:52 +00:00
Mike Jolley 9e23b0d2cc missing $this 2016-11-09 15:40:52 +00:00
Mike Jolley cf8fba5900 Put back review functions (still todo) 2016-11-09 15:40:51 +00:00
Mike Jolley a85ad09e7e Rename method 2016-11-09 15:40:51 +00:00
Mike Jolley e5cbb91472 Tidy/add todos 2016-11-09 15:40:51 +00:00
Mike Jolley 731df74bad Availability html 2016-11-09 15:40:38 +00:00
Mike Jolley bc220c3b73 Moving and refactoring methods 2016-11-09 15:39:39 +00:00
Mike Jolley 06fb79ec03 Spacing in query 2016-11-09 15:39:18 +00:00
Mike Jolley bf78e8bcd4 Use get_upsell_ids 2016-11-09 15:39:18 +00:00
Mike Jolley 3e6bee0712 Move children to meta and update test 2016-11-09 15:39:18 +00:00
Mike Jolley 5fc0142ba0 Tests 2016-11-09 15:39:18 +00:00
Mike Jolley f58829a316 Grouped product class 2016-11-09 15:38:44 +00:00
Justin Shreve 92e016f68e _virtual meta should be 'no', not taxable, in product unit test helper 2016-11-09 15:38:44 +00:00
Justin Shreve 19949d369d External Product CRUD 2016-11-09 15:38:44 +00:00
Mike Jolley 745c31176d Made abstract function useful 2016-11-09 15:38:44 +00:00
Justin Shreve 79f2d0eb8c Handle PR feedback: Remove duplicate regular_price update, allow changing of post status for products, remove deprecation for get_title since we might still offer it as a function 2016-11-09 15:38:44 +00:00
Mike Jolley f733f1fcba Bump template version 2016-11-09 15:38:44 +00:00
Justin Shreve 432d736520 Clean up the abstract product class a bit, deprecate two functions we have renamed, make update & create work properly, and add some tests for it. 2016-11-09 15:38:44 +00:00
Mike Jolley ac9574e25e wc_get_product_term_ids instead of related wording and use in other places.
get_the_terms is used here and also handles caching, something
wp_get_post_terms does not.
2016-11-09 15:38:44 +00:00
Mike Jolley 68282e9661 Remove unneeded comments 2016-11-09 15:38:44 +00:00
Mike Jolley 34f579cfc4 Sanitize ids later 2016-11-09 15:38:27 +00:00
Claudio Sanches a5cf2922ee Use count() instead of sizeof() 2016-11-09 15:38:27 +00:00
Claudio Sanches 1c73ffb3f6 Fixed wrong variable in wc_get_related_terms 2016-11-09 15:38:27 +00:00
Claudio Sanches ee82a198da Get cached terms from wc_get_related_terms() 2016-11-09 15:38:27 +00:00
Claudio Sanches f5c42c60c8 Fixed coding standards and improved the docblocks 2016-11-09 15:38:27 +00:00
Mike Jolley fb8c54dcce No need to exclude ID 2016-11-09 15:38:27 +00:00
Mike Jolley 3b3a83df8e Add related product functions and deprecate those in class. 2016-11-09 15:38:27 +00:00
Mike Jolley b254ecf16d Missing var 2016-11-09 15:37:51 +00:00
Mike Jolley eb61503210 Initial look through getters and setters and abstract data 2016-11-09 15:37:51 +00:00
Mike Jolley 4c0cc54f79 Hardcode the get_type per product class 2016-11-09 15:37:51 +00:00
Claudio Sanches 70e13702ae Fixed several erros while setting data 2016-11-09 15:37:20 +00:00
Claudio Sanches 7491085bcf Product set methods 2016-11-09 15:37:20 +00:00
Claudio Sanches 474b343746 First methods for WP_Product crud 2016-11-09 15:37:20 +00:00
Claudio Sanches 6b5786e35f Updated messages 2016-11-09 11:54:28 -02:00
Claudio Sanches 81f3fe2e7e Merge pull request #12288 from leewillis77/product-crud
Use get_the_terms() instead of wp_get_post_terms()
2016-11-09 10:57:23 -02:00
Claudio Sanches 1360f6fc3e Docblock for #12287 2016-11-09 10:54:08 -02:00
Claudio Sanches 3b147be755 Merge pull request #12287 from woocommerce/add-get-formatted-order-total-filter-paramas-and-docblock
Add more arguments to filter woocommerce_get_formatted_order_total
2016-11-09 10:50:43 -02:00
Mike Jolley ed46abf3a3 [Product CRUD] Variable, variation, notices, and stock handling (#12277)
* No longer needed

* Remove old todos

* Use getters in admin list

* Related and upsells update for CRUD

* Fix notice in gallery

* Variable fixes and todos

* Context

* Price sync

* Revert variation attributes change

* Return parent data in view context

* Defer term counting

* wc_find_matching_product_variation

* Stock manage tweaks

* Stock fixes

* Correct id

* correct id

* Better sync

* Data logic setter fix

* feedback
2016-11-09 12:26:46 +00:00
Justin Shreve b41626c555 Implement Coupon Data Store (#12280)
* Implement a Coupon Data Store using CPTs..

* Handle PR feedback.
2016-11-09 12:21:18 +00:00
Justin Stern a3e371e0d7 Make WooCommerce core play nice with Codeception (#11845)
If is_blog_installed() is false then skip some installation steps that
are performed on the 'init' action and which require the database to be
available
2016-11-09 11:53:39 +00:00
Lee Willis 90d8291ace Allow WP_Query to preload post data, and meta in wc_get_products()
Allow WP_Query to bulk query for post data and meta if more than
just IDs are requested from wc_get_products(). Reduces query count
significantly.
2016-11-09 11:44:11 +00:00
Claudio Sanches 49a574e704 Move all JavaScript from system status page to a new file (#12283) 2016-11-09 11:36:14 +00:00
Lee Willis 2c2239a3b0 Use get_the_terms() instead of wp_get_post_terms()
wp_get_post_terms() is a wrapper around wp_get_object_terms() which does not
use the object cache, and generates a database query every time it is used.

get_the_terms() however can use data from the object cache if present.
2016-11-09 11:27:24 +00:00
Dwain Maralack 5f87161c06 add function arguments to the filter to give more context when filter is applied 2016-11-09 12:49:38 +02:00