Commit Graph

1328 Commits

Author SHA1 Message Date
Mike Jolley ce6c4a736f Merge pull request #13488 from woocommerce/downloads-consistency
Downloads data consistency
2017-03-07 12:13:03 +00:00
Claudio Sanches df1a87a749 [REST API] Removed extra product_name in v1 and added schema for product_name in v2 2017-03-06 19:48:26 -03:00
Claudio Sanches 50d62a5c4c REST API v1 should return 0 when limit_usage_to_x_items is empty 2017-03-06 18:14:32 -03:00
Claudio Sanches 8a77bb0957 Fixed undefined $id #13405 2017-03-04 12:15:52 -03:00
Claudiu Lodromanean e4db7f1d76 Update variable names to correct ones 2017-03-03 14:40:31 -08:00
Claudio Sanches 8d28e966c4 Let product CRUD handle terms IDs 2017-03-03 16:21:27 -03:00
Claudiu Lodromanean 51c5910866 Set line item prices on legacy API order create 2017-03-03 09:26:08 -08:00
Claudio Sanches f7d8ddffab Merge pull request #13452 from woocommerce/fix-13405
Legacy API tweaks
2017-03-02 22:42:46 -03:00
Claudiu Lodromanean bd4458fa90 Change create to save 2017-03-02 14:28:35 -08:00
Claudio Sanches 3aa86075d1 Prevent errors when do not have a paid date 2017-03-02 16:29:04 -03:00
Claudio Sanches 9fb2ba7783 [REST API] date_paid should be in date time format, closes #13255 2017-03-02 15:25:32 -03:00
Claudio Sanches e42e2a3335 Replace woocommerce_coupon_code filter by wc_format_coupon_code() 2017-02-22 14:40:24 -03:00
Akeda Bagus 43a63985c6
Install pages action should return array instead of string.
Fixes #13256.
2017-02-21 12:01:27 +07:00
Claudio Sanches 486a81bf12 Fixed coding standards 2017-02-17 16:10:15 -02:00
Claudio Sanches 0410518f31 Removed filter query param from products queries in REST API 2017-02-17 13:15:54 -02:00
Claudio Sanches b0e6a5ab5d Get object again after saved 2017-02-17 01:46:42 -02:00
Claudio Sanches 58d90a2ee8 Added legacy classes 2017-02-17 00:27:40 -02:00
Claudio Sanches ba7607fe00 Improved delete_item() for products and variations 2017-02-17 00:10:25 -02:00
Claudio Sanches 94b0800735 Use CRUD Controller for product variations 2017-02-16 22:51:36 -02:00
Claudio Sanches 55977d03f3 Do not allow manipulate variations on products endpoint 2017-02-16 22:51:24 -02:00
Claudio Sanches 63cb7e7c27 Use CRUD Controller for products 2017-02-16 22:26:21 -02:00
Claudio Sanches 31f68377f9 Fixed docblock 2017-02-16 22:25:20 -02:00
Claudio Sanches 197d2eb98e Use CRUD Controller for order refunds 2017-02-16 21:45:12 -02:00
Claudio Sanches 687433d5cc Use CRUD Controller for orders 2017-02-16 21:15:34 -02:00
Claudio Sanches 34cf70407e Use CRUD Controller for coupons 2017-02-16 20:31:36 -02:00
Claudio Sanches 7a52ec465b Fixed docblocks and removed dead variables 2017-02-16 18:05:06 -02:00
Claudio Sanches 9c15ca936b Merge pull request #13206 from woocommerce/rest-api-v2
REST API v2
2017-02-16 12:53:46 -02:00
Claudio Sanches f08c10d068 Fixed and improved the variations endpoint 2017-02-16 03:07:51 -02:00
Claudio Sanches e48243aa0b No private methods in REST API 2017-02-16 02:30:04 -02:00
Claudio Sanches 666d1f3c06 Prevent PHP notices while saving meta_data without an id 2017-02-16 01:44:45 -02:00
Claudio Sanches 75b2661ba3 Fixed undefined $meta[id] 2017-02-16 01:42:47 -02:00
Claudio Sanches 036a2f6c92 Allow save meta data for products in v2 2017-02-16 01:39:30 -02:00
Claudio Sanches d2818be2ba Order refunds v1 and v2 2017-02-16 01:27:44 -02:00
Claudio Sanches a19fa78cef Fixed orders get_collection_params() 2017-02-16 01:10:41 -02:00
Claudio Sanches 5ebeafac33 Removed duplicated code 2017-02-16 01:09:36 -02:00
Claudio Sanches eaf492a7f1 Fixed orders v2 schema 2017-02-16 01:08:02 -02:00
Claudio Sanches 503812971d Fixed deprecated warnings in orders v1 2017-02-16 00:45:20 -02:00
Claudio Sanches 5c0046b325 Do not allow save meta_data in orders v1 2017-02-16 00:33:17 -02:00
Claudio Sanches cc1992f1c8 Fixed item variation_id 2017-02-16 00:26:42 -02:00
Claudio Sanches 2d0a479750 Updated v1 methods 2017-02-16 00:22:15 -02:00
Claudio Sanches bad93d4c86 Improved naming for meta_data in schema 2017-02-15 12:28:45 -02:00
Claudio Sanches 0dac5e596c Included meeta data to products 2017-02-14 14:01:31 -02:00
Claudio Sanches ad3716a49e Fixed coupons schema 2017-02-14 13:59:22 -02:00
Claudio Sanches 5365fec1b3 V1 and V2 for products endpoint 2017-02-13 19:44:27 -02:00
Claudio Sanches d02d90c867 V1 and V2 for product taxonomies, reviews, reports, taxes and webhooks 2017-02-11 12:51:41 -02:00
Claudio Sanches e9f2e75d53 Fixed coding standards and file header 2017-02-11 12:51:13 -02:00
Claudio Sanches 190ebccd00 Fixed order notes 2017-02-10 21:34:01 -02:00
Claudio Sanches 7f82051dd9 Fixed returning values in write context 2017-02-10 21:32:40 -02:00
Claudio Sanches ca67d448a2 Fixed doing it wrong notices 2017-02-10 21:11:56 -02:00
Claudio Sanches e84acf3ee4 Order notes v2 2017-02-10 18:31:29 -02:00
Claudio Sanches e4b6c81f66 Customer downloads v2 2017-02-10 18:31:21 -02:00
Claudio Sanches b1b536b5d2 Give REST API authentication a lower priority
Bigger than add_filter( 'determine_current_user', 'wp_validate_auth_cookie' );
Smaller than add_filter( 'determine_current_user', 'wp_validate_logged_in_cookie', 20
);

This solve issues while trying to authenticate in a browser while logged
in.

Closes #13134
2017-02-10 15:35:52 -02:00
Claudio Sanches ec8fe6e30d [REST API] Implement CRUD to customers 2017-02-09 19:54:16 -02:00
Claudio Sanches 23fbc31dfb [REST API v1] Implement CRUD to coupons 2017-02-09 19:22:19 -02:00
Claudio Sanches 5d87a28407 Restored shipping zones base controller 2017-02-09 18:46:57 -02:00
Claudio Sanches 88d2875514 Restored REST API v1 2017-02-09 18:40:35 -02:00
Claudio Sanches 4352484ed7 REST API v2 2017-02-09 15:06:13 -02:00
Mike Jolley c49368f7fc Small id fix for #13118 2017-02-08 18:19:24 +00:00
Claudio Sanches 9b0a4e6c92 Merge pull request #13109 from woocommerce/fix-regressed-tests
Fix failing tests and array_merge error
2017-02-08 16:18:08 -02:00
Claudio Sanches 4e653139b6 Merge pull request #13117 from woocommerce/fix-12973
Moved refund logic
2017-02-08 16:15:54 -02:00
Mike Jolley 3cf772bcb5 Always use type arg 2017-02-08 18:08:13 +00:00
Mike Jolley eb150724c4 Make sure calculations are redone after setting line items
Closes #13075
2017-02-08 17:23:40 +00:00
Mike Jolley 11ef37880b Moved logic to wc_create_refund 2017-02-08 16:20:42 +00:00
Mike Jolley 52291e003c wrong method name 2017-02-08 16:20:05 +00:00
Mike Jolley af6ee6d420 Fix; wrong method calls 2017-02-08 16:19:13 +00:00
Claudiu Lodromanean 173c09dd04 Fix failing tests and array_merge error 2017-02-07 10:46:03 -08:00
Claudio Sanches 79256504a1 [REST API] Products endpoint fixes, closes #13031 2017-02-01 09:58:04 +01:00
Claudio Sanches 346e1ea1e0 Merge pull request #12996 from woocommerce/rest-api-missing-types-args
REST API Types
2017-01-27 14:49:35 -02:00
Claudio Sanches 24a5fe7592 Make WC_REST_Exception extend WC_Data_Exception 2017-01-27 13:52:21 -02:00
Toni Viemerö 2d92bdece6 Cast position as integer
Even though I'm sending `position` as integer in my REST request, it comes through as string value.

```
array (
  'id' => '186',
  'position' => '0',
)
```
2017-01-26 23:08:12 +02:00
Mike Jolley e930ccd16e object types to fix unit tests 2017-01-26 20:58:55 +00:00
Toni Viemerö 2b00615fa2 Remove tilde from i 2017-01-26 22:55:23 +02:00
Mike Jolley 82d7fe6e73 Added more missing args and types 2017-01-26 20:33:39 +00:00
Mike Jolley b727c61da7 Missing arg and setting types 2017-01-26 20:06:18 +00:00
Mike Jolley 2d23705431 ID arg definitions 2017-01-26 19:22:57 +00:00
Mike Jolley def35a5aa2 Cast request ids to int 2017-01-26 18:34:11 +00:00
Justin Shreve 474a307420 Introduce get_tax_class_slugs. 2017-01-25 13:38:13 -08:00
Claudio Sanches cdf59d6f68 E[REST API] Use WC_Data_Exception->getErrorData 2017-01-23 17:32:33 -02:00
Claudio Sanches f54e9e1e1a Fixed coding standards 2017-01-18 15:16:01 -02:00
Mike Jolley d92447713a Merge pull request #12852 from woocommerce/fix-terms-ordering
Restore attributes ordering
2017-01-17 12:28:41 +00:00
Claudio Sanches bd655af072 Restore attributes ordering, closes #12847 2017-01-16 21:11:56 -02:00
Claudio Sanches 3d352a680c [REST API] Allow search by multiples SKUs 2017-01-16 20:35:55 -02:00
matttallan c45d81e650 Make the system_status GET endpoint more customisable 2017-01-10 16:06:09 +10:00
Justin Shreve 291a662be1 The WC API returns exclude_product_ids and expiry_date. 2.7 renamed these in the API file, which we should not do until we version the endpoints. 2017-01-03 10:25:36 -08:00
Mike Jolley fc867c1a58 Return current variations after API update/create 2017-01-03 16:53:49 +00:00
Mike Jolley 859727d462 Merge pull request #12678 from franticpsyx/rest-api-set-order-item-action
[2.7] Add 'woocommerce_rest_set_order_item' REST API hook
2016-12-23 14:18:31 +00:00
Manos Psychogyiopoulos 42e09eac32 make rest api order item totals - always excl tax 2016-12-22 19:23:07 +02:00
Manos Psychogyiopoulos 0d6eae5fca add 'woocommerce_rest_set_order_item' hook 2016-12-22 17:56:14 +02:00
Mike Jolley 8f49724b17 Merge pull request #12674 from franticpsyx/rest-api-set-order-item-meta
[2.7] REST order item meta not intercepted
2016-12-22 14:38:39 +00:00
Mike Jolley 6861131d8f Fix version check 2016-12-22 14:30:47 +00:00
Manos Psychogyiopoulos dae45b8a29 fix paren position 2016-12-22 14:10:36 +02:00
Manos Psychogyiopoulos 6fc59cf2dc set REST order item meta 2016-12-22 12:29:57 +02:00
Mike Jolley 020a7b518f Fix API set of reviews_allowed
#12618
2016-12-16 11:24:11 +00:00
Claudio Sanches af52cf4f73 [2.6] [REST API] Throw exception when product image ID is not a valid attachment 2016-12-14 21:11:50 -02:00
Justin Shreve da1e14c087 Add WC CLI commands powered by the REST API. 2016-12-08 10:59:07 -08:00
Mike Jolley 4bacbaf90c Fix completed and paid date meta keys. 2016-12-08 11:19:32 +00:00
Mike Jolley 47fbae4d26 Product Visibility Taxonomies (#12527)
* Convert visibility and featured to taxonomy

* Comment

* Add missing tax_queries

* Only check SKU after read.

* Added visibility term for outofstock products to speed those queries up al

* wc_bool_to_string
2016-12-08 10:56:45 +00:00
Justin Shreve 63a29dd4db Add 'locale' to list of customer meta keys, and update expected type for 'object' for gateways, products, and shipping zones to fix some API issues. 2016-12-07 12:23:23 -08:00
Mike Jolley e8d119c42c Feedback 2016-12-07 18:13:17 +00:00
Mike Jolley 1ad852443b Invalid type 2016-12-07 15:54:35 +00:00