Commit Graph

236 Commits

Author SHA1 Message Date
Mike Jolley d4d6f3181c Best practice tweaks 2016-06-06 17:24:31 +01:00
Manos Psychogyiopoulos 410c09d6b0 add 'woocommerce_admin_stock_html' filter 2016-06-01 15:06:10 +03:00
Mike Jolley c82e177fd3 Fix coupon total replacement
Fixes #10618
2016-03-30 12:56:53 +01:00
Justin Silver ef3a5b97ef Merge remote-tracking branch 'upstream/master' 2016-03-15 13:51:49 -07:00
Justin Silver 4dec4832e1 Fix highlight series ID for coupons line from legend 2016-03-15 13:50:01 -07:00
Mike Jolley c10b861f80 Merge pull request #10558 from doublesharp/master
Add 'woocommerce_admin_report_data' and 'woocommerce_admin_report_chart_data' to filter chart data by 3rd parties
2016-03-15 12:22:18 +00:00
Justin Silver ffdfe816ec Add ‘woocommerce_admin_report_data’ to filter chart data by 3rd parties
Refactor get_main_chart() to use an array of data so that it to can be
filtered
Add ‘woocommerce_admin_report_chart_data’ to filter chart data by
period (for display)
2016-03-14 19:30:49 -07:00
Mike Jolley c1e8dd1fe8 Use wc_get_orders iternally 2016-03-09 16:11:05 +00:00
Mike Jolley d3f98dce03 More advanced customer filter
#10500
2016-03-09 14:50:34 +00:00
Mike Jolley a1cce4a1b2 Issues from Justin 2016-03-04 10:53:48 +00:00
Mike Jolley 6880a71ea9 Merge pull request #10141 from woothemes/fix-10135
Fix 10135
2016-02-12 13:37:53 +00:00
Mike Jolley 5cae61cb69 Show net sales on dashboard
Closes #9948
2016-02-08 11:28:40 +00:00
Mike Jolley f5140af918 [2.5] Report on partial refunds/refunds items rather than full refunds to ensure they are reported when refunded
@claudiosmweb your testing + approval welcome.

Closes #10138
2016-01-22 17:53:12 +00:00
Mike Jolley 77e1aa8263 Make qty for refunds negative
Fixes order counts reported in #10135

May however require an upgrade routine and needs more testing. Not for
2.5.

Fixes #10135
2016-01-22 16:28:29 +00:00
Mike Jolley 6cc700a497 [2.5] Report on partial refunds/refunds items rather than full refunds to ensure they are reported when refunded
@claudiosmweb your testing + approval welcome.

Closes #10138
2016-01-22 15:50:23 +00:00
Fredrik Forsmo c7ab50ec7e Add missing param tags to various wc admin docblocks 2016-01-05 16:49:41 +01:00
Mike Jolley ade2b04ab3 Merge pull request #9960 from frozzare/docs/class-wc-report-stock
Improve docblock comments in WC_Report_Stock class
2016-01-05 12:15:34 +00:00
Mike Jolley 12bf6c5355 Merge pull request #9959 from frozzare/docs/class-wc-report-sales-by-category
Improve docblock comments in WC_Report_Sales_By_Category class
2016-01-05 12:15:21 +00:00
Mike Jolley a8f8802631 Merge pull request #9958 from frozzare/docs/class-wc-report-sales-by-date
Improve docblock comments in WC_Report_Sales_By_Date class
2016-01-05 12:14:01 +00:00
Mike Jolley 6ee8727ff6 Merge pull request #9957 from frozzare/docs/class-wc-report-sales-by-product
Improve docblock comments in WC_Report_Sales_By_Product class
2016-01-05 12:13:13 +00:00
Mike Jolley cc1232e126 Merge pull request #9956 from frozzare/docs/class-wc-report-out-of-stock
Improve docblock comments in WC_Report_Out_Of_Stock class
2016-01-05 12:12:38 +00:00
Mike Jolley c564a05ac3 Merge pull request #9954 from frozzare/docs/class-wc-report-customers
Improve docblock comments in WC_Report_Customers class
2016-01-05 12:12:18 +00:00
Mike Jolley 80eb99526d Merge pull request #9955 from frozzare/docs/class-wc-report-most-stocked
Improve docblock comments in WC_Report_Most_Stocked class
2016-01-05 12:11:46 +00:00
Fredrik Forsmo 67308a3131 Add missing `exit if accessed directly` to WC_Report_Taxes_* classes 2016-01-05 12:47:44 +01:00
Fredrik Forsmo a9b4cc2caf Improve docblock comments in WC_Report_Stock class
* Added comments to properties that don’t have any.
* Added comment to `__construct`, `column_default`, `get_columns` and
`prepare_items` since it
was `method function`
* Added missing param tags to `display_tablenav`
2016-01-05 12:46:15 +01:00
Fredrik Forsmo 53d5684c92 Improve docblock comments in WC_Report_Sales_By_Product class
* Added comments to properties that don’t have any.
* Added comment to `get_chart_widgets` since it
was `method function`
* Added missing `exit if accessed directly`
* Updated `current_filters` and `products_widget`
2016-01-05 12:41:12 +01:00
Fredrik Forsmo 0b62c624fa Improve docblock comments in WC_Report_Sales_By_Date class
* Added comments to properties that don’t have any.
* Fixed return tag value for `get_report_data`
2016-01-05 12:28:49 +01:00
Fredrik Forsmo 03a3e4f06d Improve docblock comments in WC_Report_Sales_By_Category class
* Added comments to properties that don’t have any.
* Added comment to `get_chart_widgets` since it
was `method function`
* Added missing `exit if accessed directly`
* Updated `category_widget` comment to a better one.
2016-01-05 12:18:58 +01:00
Fredrik Forsmo a59e110895 Improve docblock comments in WC_Report_Out_Of_Stock class
* Added missing param tags to `get_items`
2016-01-05 11:52:38 +01:00
Fredrik Forsmo c88119814c Improve docblock comments in WC_Report_Most_Stocked class
* Added missing param tags to `get_items`
2016-01-05 11:37:33 +01:00
Mike Jolley e07185ec1f Merge pull request #9952 from frozzare/docs/class-wc-report-low-in-stock
Add missing docblock param tags to get_items in WC_Report_Low_In_Stock class
2016-01-05 10:17:13 +00:00
Mike Jolley a24df3aa61 Merge pull request #9949 from frozzare/docs/class-wc-report-coupon-usage
Improve docblock comments in WC_Report_Coupon_Usage class
2016-01-05 10:17:03 +00:00
Mike Jolley 8231853f70 Merge pull request #9950 from frozzare/docs/class-wc-admin-report
Improve docblock comments in WC_Admin_Report class
2016-01-05 10:16:49 +00:00
Fredrik Forsmo b589d22a84 Improve docblock comments in WC_Report_Customers class
* Added comments to properties that don’t have any.
* Added comment to `get_chart_widgets`, `customers_vs_guests` since it
was `method function`
* Added missing `exit if accessed directly`
* Updated `get_main_chart` comment since it is wrong.
2016-01-05 11:11:20 +01:00
Fredrik Forsmo c0be061de6 Add missing docblock param tags to WC_Report_Low_In_Stock class 2016-01-05 11:08:12 +01:00
Fredrik Forsmo 130ff76ffc Improve docblock comments in WC_Report_Customer_List class
* Added missing `public` before `column_default` function
* Added comment to `__construct `, `column_default`, `get_columns` and
`prepare_items` since it was `method function`
2016-01-05 10:00:52 +01:00
Fredrik Forsmo e0f5117efe Improve docblock comments in WC_Report_Coupon_Usage class
* Added comments to properties that don’t have any.
* Added comment to `get_chart_widgets` since it was `method function`
* Updated `coupons_widget` comment since it is wrong.
* Added missing `exit if accessed directly`
2016-01-05 09:54:43 +01:00
Fredrik Forsmo 004ab615c5 Improve phpdoc comments in WC_Admin_Report class
* Added comments to properties that don’t have any.
* Fixed return value for `prepare_chart_data`.
* Added comment to `get_chart_widgets` since it was `method function`
2016-01-05 09:48:39 +01:00
Mike Jolley 4f0cc137cc Enable SQL_BIG_SELECTS in reports
@claudiosmweb
2015-11-05 15:45:19 +00:00
Claudio Sanches 5893875b0c Removed period for file headers 2015-11-03 11:53:50 -02:00
Claudio Sanches ee30b5b308 Fixed php docs standards 2015-11-03 11:31:20 -02:00
Claudio Sanches efa19f799d Fixed some coding standards for docblocks 2015-11-03 10:28:01 -02:00
Claudio Sanches b85ae9056c Rename wc_add_help_tip() function to wc_help_tip() 2015-10-23 13:09:08 -02:00
Claudio Sanches 2e95a68357 Use new "question" mark icon font
Created wc_add_help_tip() function to generate the icons
Replaced all .help_tip elements and [?]

We'll keep the old image and styles in order to maintain backwards
compatibility

Closes #9381
2015-10-23 01:40:52 -02:00
Mike Jolley 4fd987c165 Merge pull request #9266 from woothemes/issues/9125-report-does-not-match-with-chart
[2.4] Fixed wrong gross sales calculation on sales by date report.
2015-10-05 09:17:59 +01:00
Akeda Bagus dc0d5362cd Fixed wrong gross sales calculation on sales by date report.
The order amounts should exclude refunds.

Fixes #9125.
2015-10-02 11:08:41 +02:00
Mike Jolley 96103724dc Display 2 averages on report
Closes #9144
2015-10-02 10:42:48 +02:00
Florian Ludwig 7d2d102dc4 Fixed wrong highlighting of reports chart
The highlight data attributes were totally messed up - Fixed them
according to the current sorting of the graph series
2015-09-20 18:12:31 +02:00
Nicola Mustone 6f7b534493 missing comma 2015-08-24 17:27:23 +02:00
Nicola Mustone beb97b279e _x for refund reports 2015-08-24 17:13:04 +02:00
George Stephanis 95e6b84fbb Make sure we esc_attr translation results
Part 2 of … 2, I think.
2015-08-05 14:15:00 -04:00
Mike Jolley 622dc777f0 Correct number format in coupon total 2015-07-30 12:52:52 +01:00
Mike Jolley 7d1a016502 Adjust sales report to deal with partial shipping refunds and full refunds 2015-07-01 12:11:21 +01:00
Mike Jolley 5cac639cff Merge branch 'improve-refund-reporting' Closes #8028
Conflicts:
	includes/admin/reports/class-wc-report-sales-by-date.php
	includes/updates/woocommerce-update-2.4.php
2015-05-28 14:41:20 +01:00
Mike Jolley d1d5a489fc [2.3] Fix round_chart_totals to deal with arrays
Closes #8077
2015-05-05 13:55:56 +01:00
Nicola Mustone 3288997f72 fix coupons amount 2015-05-04 17:19:34 +02:00
Mike Jolley 6c8cc42876 Revise reports #8028 2015-04-24 15:58:13 +01:00
Mike Jolley 4ab4865ac6 [2.3] Fix stock report pagination. Closes #8023 2015-04-24 12:01:49 +01:00
Mike Jolley a2a0e6f10d [2.3] Refund reporting Fixes #8010
- Prevents the refund amount being SUMed and multiplied by the number
of items
- Does LEFT join on qty, so refunds are reported if not done directly
on the line
2015-04-23 10:19:43 +01:00
Mike Jolley 38f8c5fd0b Round values in category report
Closes #7949
2015-04-14 10:51:20 +01:00
Mike Jolley 204c65ca6a Merge pull request #7836 from aelia-co/master
Added support for JOIN types in WC_Admin_Report
2015-04-08 12:11:04 +01:00
Nicola Mustone 85fd634861 fix scrutinizer issues 2015-04-01 15:33:56 +02:00
Mike Jolley 20850bc742 Fix last_month logic which breaks in feb 2015-03-31 13:13:16 +01:00
Diego Zanella 76a0ef1e9f Improved handling of JOIN clauses
* Refactored report logic to allow developers to specify the type of JOIN to use when fetching report data. Ref https://github.com/woothemes/woocommerce/issues/7818.
2015-03-27 17:02:14 +00:00
Mike Jolley ba582c307b Dashboard - use same query as reports Closes #7529 2015-02-24 12:18:56 +00:00
Mike Jolley 321d38be0a Round report values.
Closes #7505
2015-02-20 12:27:55 +00:00
Magnus Jepson ded1cf76e0 Fix sales report description
Net Sales report tooltip description was misleading by “excluding
refunds”
2015-02-18 18:19:10 +01:00
Mike Jolley f5e73d792d Fix error when no product is chosen for report.
Fixes #7427
2015-02-16 11:53:37 +00:00
Mike Jolley 8409d67602 Share data between sales by date report and API.
Also ensures data is consistent. #7416
2015-02-13 21:25:59 +00:00
Mike Jolley 50322801e5 Sales by date handling for refunds
- Exclude refunds from gross/net
- Correct order counts
- Display refunded order and item count, plot after refunds
- Combine query functions for legend and main chart
2015-02-13 13:42:09 +00:00
Mike Jolley 55969390f0 Taxes by date handling for partial and full refunds 2015-02-13 13:42:09 +00:00
Mike Jolley 8f5ac9417c Taxes by code handling for partial and full refunds 2015-02-13 13:42:09 +00:00
Mike Jolley 857a78c2fc Include posts without parent in join so combinations of orders + refunds can be queried at the same time 2015-02-13 13:42:09 +00:00
Mike Jolley 323faed337 Taxes by code - include refunds Closes #7397 2015-02-12 22:58:19 +00:00
Mike Jolley 3a4e9c0d7f Report should include refunded status orders
Fixes #7343
2015-02-10 18:24:46 +00:00
Mike Jolley 7795f69f51 Update wording to include refunds
Closes #7290
2015-02-04 15:14:02 +00:00
Mike Jolley 4c3a58c957 Undefined product_ids_titles 2015-02-03 14:12:48 +00:00
Mike Jolley fc826de960 Dead vars in category report 2015-02-03 14:12:04 +00:00
Mike Jolley ff2b0db69b Undefined var customers 2015-02-03 14:10:03 +00:00
Mike Jolley 7acfc0b7f2 Dead var 2015-02-03 14:09:54 +00:00
Claudio Sanches afb19715d4 Prevented XSS in urls 2015-01-29 12:33:06 -02:00
Claudio Sanches 177bcbe7d5 Removed unused code 2015-01-23 16:34:43 -02:00
Mike Jolley 22f68af061 These should be arrays 2015-01-20 13:50:25 +00:00
Mike Jolley 8e9539b0c2 scrutinizer issues in sales-by-category report 2015-01-20 09:53:33 +00:00
Mike Jolley a9301323b5 Merge pull request #7113 from grey-rsi/master
add filters in admin reports
2015-01-19 14:05:58 +00:00
Mike Jolley d70912c891 Define: $net_order_amounts 2015-01-14 11:28:00 +00:00
Sergey b3e9b1e6d8 add do_action in wc_price function and filters in admin reports 2015-01-13 15:34:48 +02:00
Claudio Sanches 8e28c17c66 Merge pull request #7091 from woothemes/chosen-to-select2
Chosen to select2
2015-01-12 15:47:31 -02:00
Mike Jolley 2c32f6cdd0 Add functions to get money spent/order count for customers and fix in API Closes #7083 2015-01-12 17:09:46 +00:00
Mike Jolley 1fa26f1f6e Product searches select2 2015-01-12 11:56:44 +00:00
Mike Jolley 5f5d8076d4 sales by cat select2 2015-01-09 16:43:35 +00:00
Mike Jolley f18b2c6c93 Added and enqueued select2 to admin 2015-01-09 16:39:10 +00:00
Mike Jolley 06ab96f39e Added net sales to sales by date report
Closes #7039
2015-01-06 13:27:44 +00:00
Mike Jolley 317808a219 [2.2] If order_item_type is not set, don't query it in reports class 2014-12-09 12:59:01 +00:00
Barry Kooij e1b81b3a23 Introduced 'woocommerce_reports_taxes_tax_rate' and 'woocommerce_reports_taxes_rate' filters. 2014-12-01 13:36:50 +01:00
Tamara Zuk af442599b1 Code Standards: Finish up admin includes
* 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`

@see http://make.wordpress.org/core/handbook/coding-standards/php/

@see part 1: #6157
2014-11-30 01:52:32 -05:00
Mike Jolley 251160d512 Added 'top freebies' to product report.
Closes #5596
2014-11-27 10:36:21 +00:00
Mike Jolley 3a927d62dd Add tip to reports
Closes #5729
2014-11-24 15:18:41 +00:00
claudiosmweb 8eeb6fc204 Removed more some unused code 2014-11-19 22:43:09 -02:00
Mike Jolley 003094c9c3 Ensure remaining hashes are translated Closes #6518 2014-11-18 16:29:21 +00:00