* Change coupons sum to distinct coupon count in REST API
* Hook up unique coupon count to orders summary numbers
* Add coupons count to order segmenting
* Add coupons count to expected stats in order test and revenue tests
* Translation call text domain change from “wc-admin” to “woocommerce-admin”.
* Fix .pot file generation.
* Fix errantly closed array item in /revenue/stats controller.
* Rename plugin zip, main file, and repo name to "woocommerce-admin".
* Add get_oldest_orders function to customer data store
* Check if is first order in is_returning_customer()
* Check if the customers first order has changed and update all orders respectively
* Fix check for empty oldest_orders array
* Change avg_items_per_order to number instead of integer
* Fix failing tests for new/returning customers
Only the first orders with product 1 and without coupons should be new per each customer
* Remove sleep functions from tests
* Assign second order to a variable for legibility
* Fix second order assignment and check if set
* Update all wc-admin endpoints to v4
* Add namespace for products and customers controllers
* Include product quantity in orders data store
* Add coupons to extended data in the orders data store
* Format order statuses response from database
* Hook up orders table to orders endpoint
* Add namespace to data endpoint controller
* Add namespaces to remaining extended controllers
* Use NAMESPACE var in place of wc/v4
* Update product links in orders table to products reports
* Add coupons rest controller override
* Format coupon code in response
Co-Authored-By: joshuatf <joshuatf@gmail.com>
* Store all orders regardless of status in wc_order_stats
* Only query select statuses if status_is or status_is_not is not set
* Fix order stats example query
* Filter category store by default order statuses
* Add table_name to interval functions to avoid ambiguity
* Filter coupon store by default order statuses
* Fix interval stats by adding table_name to interval function
* Filter products store by default order statuses
* Remove unused order_status in coupons data store
* Store products with any order status
* Fix ambiguous order by call in products data store
* Apply status filter after other filters to avoid logical OR matching
* Store all coupon data regardless of order status
* Filter taxes by default order statuses
* Filter customer stats by default order status
* Filter default order statuses in variations data store
* Use excluded statuses to filter reports by default
* DRY up default excluded statuses query
* Fix up new orders data store after rebase
* Rename orders controllers and data store to order stats
* Add orders data store and controller
* Add coupon, product, and status filters
* Add customer type query filter
* Add extended info for products and categories
* Bump API namespace to v4
* Add missing schema properties
* Set default customer_type and extended_info params
* Add orders endpoint tests
* Only use one JOIN if both excluded and included queries are used
* Optimize query calls to get product and category data
* Split product and category fetch and limit to product_cat taxonomy