Commit Graph

54 Commits

Author SHA1 Message Date
Brent Shepherd 6eddeaec50 PHPCS fixes 2018-09-24 11:43:46 +10:00
Brent Shepherd 0c27837b2b Add cancel_all() to WC_Queue_Interface
And the WC_Action_Queue implementation of WC_Queue_Interface.

This avoids ambiguity between the behaviour of cancel(), which can
be confusing given it technically unschedules all actions for cron
or recurring actions, but only the next instance of a single action.
2018-09-20 15:42:24 +10:00
Brent Shepherd ab78e65af9 Update WC_Queue_Interface::get_next()
To more closely align return value with other date APIs in WC, namely
WC_Data. Includes changing return value to:

1. a WC_DateTime instead of a timestamp when a scheduled occurrence is found
2. null instead of false, similar to the default of WC_Data::set_date_prop()
2018-07-31 12:29:15 +10:00
Brent Shepherd 8e4466c9c8 Add WC_Queue_Interface
To provide an agreed set of public methods that need to be defined
for any class wanting to act as WooCommerce's queue handler.

The require APIs support both delay jobs, by providing APIs to
schedule an action/job/event for some time in the future, and a
non-delayed job API, to add an event to the queue to run as soon
as possible.
2018-07-31 12:20:30 +10:00
Gerhard Potgieter 87c30fd228 PHPCS passing for class-wc-webhook-data-store-interface.php 2018-03-06 12:00:33 +02:00
Gerhard Potgieter 754df69994 PHPCS passing for class-wc-shipping-zone-data-store-interface.php 2018-03-06 11:59:23 +02:00
Gerhard Potgieter 4c6e954c8e PHPCS passing for class-wc-product-variable-data-store-interface.php 2018-03-06 11:56:07 +02:00
Gerhard Potgieter 936df3e1bb PHPCS passing for class-wc-product-data-store-interface.php 2018-03-06 11:53:40 +02:00
Gerhard Potgieter e933b8cfd0 PHPCS passing for class-wc-payment-token-data-store-interface.php 2018-03-06 11:49:02 +02:00
Gerhard Potgieter 00193f5ee4 PHPCS passing for class-wc-order-refund-data-store-interface.php 2018-03-06 11:46:27 +02:00
Gerhard Potgieter 7cd7b18bb3 PHPCS passing for class-wc-order-item-type-data-store-interface.php 2018-03-06 11:45:29 +02:00
Gerhard Potgieter 1a2b44f2d3 PHPCS passing for class-wc-order-item-product-data-store-interface.php 2018-03-06 11:43:37 +02:00
Gerhard Potgieter c354b93091 PHPCS passing for class-wc-order-item-data-store-interface.php 2018-03-06 11:42:03 +02:00
Gerhard Potgieter e504022c72 PHPCS passing for class-wc-order-data-store-interface.php 2018-03-06 11:38:03 +02:00
Gerhard Potgieter 42c5e183cd PHPCS passing for class-wc-object-data-store-interface.php 2018-03-06 11:34:16 +02:00
Gerhard Potgieter 96cbebb06b PHPCS passing for class-wc-logger-interface.php 2018-03-06 10:23:28 +02:00
Gerhard Potgieter 1ba9f86001 PHPCS passing for class-wc-log-handler-interface.php 2018-03-06 10:21:27 +02:00
Gerhard Potgieter 8d2cb4850b PHPCS passing for class-wc-importer-interface.php 2018-03-06 10:19:31 +02:00
Gerhard Potgieter 37eacc2585 PHPCS passing for class-wc-customer-download-log-data-store-interface.php 2018-03-06 10:18:33 +02:00
Gerhard Potgieter 2ed9993599 PHPCS passing for class-wc-customer-download-data-store-interface.php 2018-03-06 10:17:25 +02:00
Gerhard Potgieter 993d9cd232 PHPCS passing for class-wc-customer-data-store-interface.php 2018-03-06 10:14:45 +02:00
Gerhard Potgieter 17b6c78d00 PHPCS passing for class-wc-coupon-data-store-interface.php 2018-03-06 10:13:06 +02:00
Gerhard Potgieter 10d1c7f623 PHPCS passing for class-wc-abstract-order-data-store-interface.php 2018-03-06 10:08:42 +02:00
Claudio Sanches 9fe0c7261e Merge branch 'master' into feature/webhook-crud 2017-11-16 12:20:22 -02:00
Claudio Sanches 9fac34fbcb Save webhook results on wp cache 2017-08-17 11:07:30 -03:00
Claudio Sanches 455888fae4 Included get_webhooks_ids() to interface 2017-08-17 10:52:42 -03:00
Claudio Sanches 00185c5911 Webhook data store 2017-08-17 00:08:32 -03:00
Josh Smith 399269a4f1 [#12517] Implement logging product downloads into new logging table 2017-07-30 22:38:17 +00:00
Akeda Bagus 53807185a8
Fixed typos.
These typos are catched by `misspell` program.

```
find . -type f | grep -v assets | grep -v dummy-data | grep -v i18n | grep -v node_modules | grep -v .git | grep -v apigen |  xargs misspell -w
```

Some results were excluded because of 3rd party ownership and non-english
sentences.
2017-07-10 12:56:28 +07:00
Mike Jolley 532ddfa6b0 Merge conflicts 2017-05-31 12:23:52 +01:00
Mike Jolley d3666738d8 Merge branch 'pr/15069' 2017-05-23 18:56:58 +01:00
Claudio Sanches 2ba8e27469 Included required methods to the interface 2017-05-18 21:18:56 -03:00
Boro Sitnikovski d302e18a9b Rename `informational` to `info` in the phpdoc 2017-05-18 10:32:25 +02:00
Claudio Sanches 1dc14690fb Improved interface including important methods 2017-05-16 01:43:15 -03:00
Claudio Sanches 8c73073bf5 Updated docblocks for WC_Importer_Interface::import 2017-05-15 20:11:16 -03:00
Claudio Sanches 121f8f6315 Abstract the product importer 2017-05-15 19:49:53 -03:00
Rasmus Bengtsson 185934fad9 Fix phpdoc to include params and correct types 2017-05-15 13:50:52 +02:00
Michael Pretty 6660379f19 Cleanup of PHPDoc for interfaces, fixes #13808 2017-03-28 13:52:32 -04:00
JeroenSormani a29ba23fab Miscellaneous cleanup of typos + change some return types for IDE helpers 2017-03-20 11:03:14 +01:00
Claudio Sanches 59c2849736 Changed version 2.7 to 3.0 2017-03-15 13:36:53 -03:00
Mike Jolley 31d428131e Imrpove checkout performance when updating product sales 2017-02-10 23:41:53 +00:00
Justin Shreve 65b99bf240 moved order item type check to order item data store 2017-02-08 11:42:36 -08:00
Justin Shreve ae5293aeb9 Move the get type logic out of the product factories and into the data stores. 2017-02-08 11:18:39 -08:00
Jon Surrell 2bd8b6efbc Validate handlers implement WC_Log_handler_Interface
Add tests for interface validation.
2017-01-24 23:07:58 +01:00
Jon Surrell 8e0f40d3d1 Add WC_Log_Handler_Interface
Abstract class `WC_Log_Handler` implements interface
2017-01-24 14:10:05 +01:00
Mike Jolley f44b4f6e9f Merge pull request #12907 from thenbrent/get_order_count_param
[2.7] Fix name of get_order_count() param
2017-01-20 10:43:06 +00:00
Brent Shepherd f9569df1ee Fix naming of get_order_count() param
The parameter is actually an order status, not type.
2017-01-19 15:40:20 -08:00
Justin Shreve 98343ffe26 Fix docblocks and cast the order ID as int after our query. 2017-01-19 09:38:23 -08:00
Justin Shreve a1446c9591 Add method for getting order id from order item id. 2017-01-19 09:30:19 -08:00
Claudio Sanches fbfb195f2f Fixed interfaces file names and location 2017-01-16 19:33:21 -02:00