Commit Graph

919 Commits

Author SHA1 Message Date
Paul Sealock b29b232a46 pass in filters 2019-03-25 13:03:53 +13:00
ronakganatra9 31791c9873 Enhancement/top customers (https://github.com/woocommerce/woocommerce-admin/pull/1858)
* Added a New widget on dashboard of Top Customers.

* Remove unused props and clean up.

* Format display value for orders count.
2019-03-22 17:15:32 +08:00
Albert Juhé Lluveras a7af5e4603 Create DEFAULT_ACTIONABLE_STATUSES constant (https://github.com/woocommerce/woocommerce-admin/pull/1867) 2019-03-22 09:48:20 +01:00
David Levin 3b7f630b11 Update order of dashboard components 2019-03-21 15:23:20 -07:00
Jeff Stieler 2d8f8f9137 Merge pull request woocommerce/woocommerce-admin#1848 from woocommerce/add/1756-snooze-admin-notes
Add "remind me later" functionality to StoreAlert component.
2019-03-21 08:41:44 -06:00
Albert Juhé Lluveras 41e5d00708 Activity Panel: set reviews unread indicator based on real data (https://github.com/woocommerce/woocommerce-admin/pull/1860)
* Activity Panel: set reviews unread indicator based on real data

* Unify date comparisons to GMT

* Add numberOfReviews propType

* Verify date_created_gmt exists before using it
2019-03-21 12:35:46 +01:00
Albert Juhé Lluveras 9038bdfdae Table: update columns visibility on headers change (https://github.com/woocommerce/woocommerce-admin/pull/1846)
* Typos

* Table: update columns visibility on headers change

* Make sure initial user pref columns are loaded in all reports

* Return early filterShownHeaders when hiddenKeys is an empty array

* Undo 'headers', 'prevHeaders' order switch
2019-03-21 11:35:00 +01:00
Joshua T Flowers 3f2dd07a53 Hide stock panel and menu if stock management is disabled (https://github.com/woocommerce/woocommerce-admin/pull/1841)
* Add manage stock setting to global wcSettings

* Hide Stock tab from activity panel if stock management is disabled

* Hide Stock report if stock management is disabled

* Prevent stock page from loading if disabled and visited directly

* Hide stock status and quantity columns when disabled
2019-03-21 13:42:07 +08:00
Joshua T Flowers 3bc0582920 Activity Panel: Persist read status for inbox notes (https://github.com/woocommerce/woocommerce-admin/pull/1823)
* Add last read user data for inbox

* Check last read time against inbox note to determine read status

* Set last read in unmount to make component stateless

* Compare latest note time against last read time in activity panel

* Fix error checking and per_page limit

* Use component mount time for last read time in inbox

* Compare unread against note GMT time

* Add missing trailing comma
2019-03-21 10:54:36 +08:00
Jeff Stieler 6ab3f0b9f9 Style admin note action button and snooze dropdown. 2019-03-20 08:52:27 -06:00
Jeff Stieler 276a6e6744 Hook up “remind me later” button.
Update the admin note status and date_reminder fields.
2019-03-20 08:52:27 -06:00
Jeff Stieler 738ce59e4d Add “remind me later” dropdown button to snoozable admin notes. 2019-03-20 08:52:27 -06:00
Albert Juhé Lluveras 2f20720927 Activity Panel: Hide Reviews Panel when Reviews are Disabled (https://github.com/woocommerce/woocommerce-admin/pull/1852) 2019-03-20 11:24:12 +01:00
Joshua T Flowers 6c1f4d105f Check if resources are still loading before skipping dispatch (https://github.com/woocommerce/woocommerce-admin/pull/1821)
* Check if resources are still loading before skipping dispatch

* Use some instead of filter to check if newResource requests exist
2019-03-20 10:55:26 +08:00
Albert Juhé Lluveras 641d0b766f CSSLint: Remove whitespace at the end of line (https://github.com/woocommerce/woocommerce-admin/pull/1845) 2019-03-20 00:34:22 +01:00
ronakganatra9 7e8f5fa53b Fixwoocommerce/woocommerce-admin#1768 Added a Margin of 40 pixel for better user interface, on mobile devices. (https://github.com/woocommerce/woocommerce-admin/pull/1842)
* Added a Margin of 40 pixel for better user interface, on mobile devices.

* applied suggestion and commited changes for all devices.

* applied suggestion and removed extra tab.
2019-03-19 14:22:40 +01:00
Albert Juhé Lluveras 58154d1d39 Activity Panel: set orders unread indicator based on real data (https://github.com/woocommerce/woocommerce-admin/pull/1824) 2019-03-19 11:57:11 +01:00
Paul Sealock 6d5484aa87 Fix table links to internal reports 2019-03-19 14:27:31 +13:00
Joshua T Flowers d416f78e9f Update/variations search method (https://github.com/woocommerce/woocommerce-admin/pull/1792)
* Add product search option REST API

* Remove product_name search in favor of sku and name searching

* Search by product search term instead of generic search in autocompleter

* Add product search option REST API

* Override existing search param instead of new param

* Remove product_name search in favor of sku and name searching

* Add product search param to variations controller

* Add group by to prevent duplicate variations in response

* Use product_search in variation autocompleter

* Trim whitespace in product_search query

* Change variation search placeholder

* Override search param instead of using new product_search param

* Add baseSearchQuery to prevent losing single_product filter in variations report

* Unset s param instead of setting to false
2019-03-18 12:23:08 +08:00
Joshua T Flowers b1dd517eb6 Add single customer filter and hook up customer link (https://github.com/woocommerce/woocommerce-admin/pull/1798)
* Add a single customer filter to the customers report

* Hook up activity panel orders customer link to customer report

* Use customer name for label instead of username
2019-03-18 10:39:54 +08:00
Albert Juhé Lluveras e6cf40e3f0 Allow sorting by tax_code in Taxes report (https://github.com/woocommerce/woocommerce-admin/pull/1812) 2019-03-15 21:44:03 +01:00
Joshua T Flowers 26de74dc30 Show error in activity panel if no actionable order statuses exist (https://github.com/woocommerce/woocommerce-admin/pull/1799)
* Show error in activity panel if no actionable order statuses exist

* Localize empty actionable statuses string

* Add padding around empty content component in activity panels
2019-03-15 09:26:16 +08:00
Joshua T Flowers df5f001140 Update compare button help text (https://github.com/woocommerce/woocommerce-admin/pull/1796) 2019-03-15 09:00:48 +08:00
Paul Sealock c8537970b7 Merge pull request woocommerce/woocommerce-admin#1793 from woocommerce/fix/store-alerts-css-lint
Fix CSS Lint issues in store-alerts CSS
2019-03-14 13:13:07 +13:00
Jeff Stieler bfe5a75e98 Update text domain. (https://github.com/woocommerce/woocommerce-admin/pull/1795)
* 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".
2019-03-13 11:14:02 -06:00
Albert Juhé Lluveras 1bbf79c105 Avoid useless Chart re-renders and clean-up component state (https://github.com/woocommerce/woocommerce-admin/pull/1780)
* Improve Chart rendering performance

* Avoid reassigning yFormat prop in Chart

* Update focused keys on legend toggle

* Use selectionLimit constant instead of a hardcoded value

* Minor improvements
2019-03-13 11:38:43 +01:00
Albert Juhé Lluveras 8dd179d551 Fix CSS Lint issues in store-alerts CSS 2019-03-13 11:36:03 +01:00
Justin Shreve 1348245406 Add store notice around processing historical data. (https://github.com/woocommerce/woocommerce-admin/pull/1763)
* Add store notice around processing historical data.

* Cleanup

* Handle PR feedback.

* Clean up `add` logic and add empty content_data. Also add logic to get_notes_count so that we can hide unactioned statuses.

* Add the ability to update a note, and to also mark a status when an alert is clicked.

* Remove mark_actioned call on sync

* add missing todo
2019-03-12 09:13:20 -04:00
Albert Juhé Lluveras 6c9b96f49a Make variations and coupons endpoints return zero-value items (https://github.com/woocommerce/woocommerce-admin/pull/1765)
* Make categories endpoint return zero-value items

* Rename PHP variable to make it more specific

* Remove uneeded lines

* Make variations and coupons endpoints return zero-value items

* Remove second parameter from get_ids_table
2019-03-12 11:11:28 +01:00
Paul Sealock fd019c4c35 Chart: don't switch to comparison mode directly 2019-03-12 12:03:58 +13:00
Tiago Noronha 965a4a6cb5 Merge pull request woocommerce/woocommerce-admin#1758 from woocommerce/fix/1736
Add StoreAlerts placeholder
2019-03-08 19:52:57 +00:00
Tiago Noronha 762b7d0b0c Revert "Stop API requests when we know no alerts exist"
This reverts commit 0cdaf1bee2.
2019-03-08 16:18:02 +00:00
Tiago Noronha c3ff6fca49 Simplify StoreAlerts component logic 2019-03-08 16:17:48 +00:00
Tiago Noronha 0cdaf1bee2 Stop API requests when we know no alerts exist 2019-03-06 23:04:13 +00:00
Tiago Noronha dd8d1fbb8b Display StoreAlertsPlaceholder while alerts are being loaded 2019-03-06 22:50:47 +00:00
Tiago Noronha 0af40e8214 Add default props and prop types to StoreAlertsPlaceholder component 2019-03-06 22:16:38 +00:00
Tiago Noronha 3493481f01 Add placeholder for StoreAlerts 2019-03-06 21:36:54 +00:00
Paul Sealock b401a4845b Update configs to simplify Show > Advanced Filters 2019-03-07 10:29:54 +13:00
Albert Juhé Lluveras a7e3cf78a0 Show compared keys in chart legends even if their values are 0 (https://github.com/woocommerce/woocommerce-admin/pull/1754)
* Show compared keys in chart legends

* Fix JS error if filters is missing

* Add docs
2019-03-06 21:12:28 +01:00
Jeff Stieler 4ebf4feb70 Merge pull request woocommerce/woocommerce-admin#1742 from woocommerce/fix/1675-ie-dash-block-overlap
Fix IE11 leaderboard display issue.
2019-03-06 07:56:46 -07:00
Joshua T Flowers 4d80cad52e Add rebuild tool to settings page (https://github.com/woocommerce/woocommerce-admin/pull/1737)
* Add button input type to analytics settings

* Add callback prop and disabled state to setting

* Add rebuild tool to settings page

* Re-enable setting if error is caught

* Remove rebuild tool from system tools page

* Move report build success message to API response

* Add back key for settings map

* Fix misspelled option group classname

* Conditionally add rebuild tool to non-wc-status page instead of removal hook
2019-03-06 13:32:05 +08:00
Joshua T Flowers e45d311581 Add actionable order statuses settings (https://github.com/woocommerce/woocommerce-admin/pull/1727)
* Add actionable status setting

* Add actionable statuses to settings page

* Hook up actionable order statuses to activity panel

* Hook up actionable order statuses to activity panel
2019-03-06 13:14:38 +08:00
Jeff Stieler 27a5d65645 Set dashboard (leaderboard/chart) grid item position manually for IE11. 2019-03-05 15:59:23 -07:00
Albert Juhé Lluveras 5d3aa58a5d Use IDs instead of labels to identify chart legend items (https://github.com/woocommerce/woocommerce-admin/pull/1730)
* Use instanceId to generate unique ids for chart legend items

* Decouple item key and label in Chart components

* Remove more duplicate IDs in the chart legend

* Use double underscores in element IDs following BEM rules

* Move 'withInstanceId' inside D3Legend component

* Simplify screen reader labels logic

* Add CHANGELOG message

* Use 'primary' and 'secondary' as items keys in time-comparison charts
2019-03-05 19:27:20 +01:00
Tiago Noronha 9164e85fad Merge pull request woocommerce/woocommerce-admin#1723 from woocommerce/add/1708-notes-endpoint
Hook up StoreAlerts component to notes endpoint
2019-03-05 13:03:50 +00:00
Joshua T Flowers 27acab72b8 Define extended_info in case query is filtered (https://github.com/woocommerce/woocommerce-admin/pull/1728) 2019-03-05 10:56:47 +08:00
Jeff Stieler b23ae97eff Skip dispatching fresh data requests when the window/tab is hidden. 2019-03-04 12:47:48 -07:00
Tiago Noronha f8e97b8152 Return immediately if no alerts found 2019-03-04 13:52:20 +00:00
Joshua T Flowers 4e9f787b13 Update tracking to use wcTracks method (https://github.com/woocommerce/woocommerce-admin/pull/1718)
* Remove tracking script from client assets

* Check for wcTracks function and record event if it exists

* Rely on tracking enabled check in core
2019-03-04 12:08:13 +08:00
Tiago Noronha 416d41279f Update CSS with new alert types 2019-03-01 17:37:51 +00:00
Tiago Noronha 7248d14595 Hook up StoreAlerts component to notes endpoint 2019-03-01 17:20:28 +00:00
Justin Shreve fce16ade7a Display order number on reports (https://github.com/woocommerce/woocommerce-admin/pull/1706)
* Display order number on reports, and add to API response.

* Add method for getting order number, avoiding loading the data store if no filter is attached.
2019-02-28 09:14:21 -05:00
Timmy Crawford 00965ba5b3 Remove Swaggerhub method. (https://github.com/woocommerce/woocommerce-admin/pull/1707) 2019-02-27 19:14:54 -08:00
Albert Juhé Lluveras a8ee12e1f9 Fix empty chart and summary numbers when searching in the Categories report (https://github.com/woocommerce/woocommerce-admin/pull/1698) 2019-02-27 17:28:18 +01:00
Albert Juhé Lluveras 4e4f04b8d8 Display chart and summary numbers placeholder when loading search terms (https://github.com/woocommerce/woocommerce-admin/pull/1694) 2019-02-27 15:43:34 +01:00
Joshua T Flowers 6a18202f61 Add tax include param to tax REST API (https://github.com/woocommerce/woocommerce-admin/pull/1672)
* Add code to collection params to allow searching

* Add include param to tax rest api

* Remove duplicate get_collection_params

* Revert to previous taxes getLabel config
2019-02-27 10:37:24 +08:00
Tiago Noronha c5a3a5dea8 Merge pull request woocommerce/woocommerce-admin#1627 from woocommerce/add/115-store-alerts
Adds StoreAlerts component
2019-02-26 23:18:00 +00:00
Tiago Noronha 6fe2b070bc Alert pagination label alignment 2019-02-26 23:10:00 +00:00
Albert Juhé Lluveras 53bac8700e Screen readers: read date instead of data keys in 'time-comparison' bar charts (https://github.com/woocommerce/woocommerce-admin/pull/1586)
* Screen readers: read date instead of data keys in 'time-comparison' bar charts

* Make previous period labels more verbose

* Revert "Make previous period labels more verbose"

This reverts commit 34d13deaa982425ca2cba76dacfd2c89c96f06c0.

* Improve isSameDay check

* Add date to hour tooltip and improve screen reader label

* Add CHANGELOG message
2019-02-26 11:56:49 +01:00
Albert Juhé Lluveras b18819489b Don't store searchWords in the query prop (https://github.com/woocommerce/woocommerce-admin/pull/1689) 2019-02-26 11:06:37 +01:00
Albert Juhé Lluveras b85eef53fd Display table placeholder instead of empty table when loading search terms (https://github.com/woocommerce/woocommerce-admin/pull/1682) 2019-02-26 10:28:50 +01:00
Joshua T Flowers 37e1ddfbd1 Don't update state on user preferences props change (https://github.com/woocommerce/woocommerce-admin/pull/1688) 2019-02-26 11:34:43 +08:00
Albert Juhé Lluveras 4a19d27ec1 Add 'isCheckbox' prop to 'MenuItem' (https://github.com/woocommerce/woocommerce-admin/pull/1620)
* Make column filter menu items not focusable

* Check if onInvoke exists before calling it

* Revert "Check if onInvoke exists before calling it"

This reverts commit e3b63edd51395c0f967991e2d20fccf867e37b91.

* Revert "Make column filter menu items not focusable"

This reverts commit 3e0ac949fa057a0c235876731768b6f312ced998.

* Add isCheckbox prop to MenuItem component

* Fix arrow keys navigation in checkbox menu items

* Table: don't update showCols state when the headers prop changes
2019-02-25 20:25:19 +01:00
Albert Juhé Lluveras 55336a9874 Make 'Rows Per Table' <select> accessible (https://github.com/woocommerce/woocommerce-admin/pull/1674) 2019-02-25 11:17:56 +01:00
Paul Sealock a3e4955f74 Merge pull request woocommerce/woocommerce-admin#1571 from woocommerce/fix/taxes-segmentation
Taxes Report: fix comparison mode and segmentation labels
2019-02-25 11:31:37 +13:00
Joshua T Flowers 9c95a62f3b Hide woo notices button when side menu is open (https://github.com/woocommerce/woocommerce-admin/pull/1658) 2019-02-22 09:42:42 +08:00
Tiago Noronha f1e6c2f3c8 Reduce alert margin on mobile 2019-02-21 23:39:30 +00:00
Tiago Noronha 952ad025a5 Change button from isPrimary to isDefault and adjust color 2019-02-21 23:34:43 +00:00
Tiago Noronha 1910d76425 Small screens styling tweaks 2019-02-21 23:24:01 +00:00
Paul Sealock 62a6b619d9 Taxes Report: allow segmentation by tax 2019-02-22 11:37:15 +13:00
Tiago Noronha e6b0f3476c Merge pull request woocommerce/woocommerce-admin#1560 from woocommerce/fix/1429-hello-dolly
Stop Hello Dolly lyrics from displaying in the notices tab
2019-02-21 18:58:51 +00:00
Tiago Noronha 039ca2a1a9 Remove Hello Dolly exception from JS 2019-02-21 18:34:50 +00:00
Justin Shreve 2af0aedd95 Add comparison support to the coupons report (https://github.com/woocommerce/woocommerce-admin/pull/1647) 2019-02-21 10:16:44 -05:00
Tiago Noronha d54d9aa05e Fix store alters margin on mobile 2019-02-21 14:26:43 +00:00
Tiago Noronha f22770ce7e Use global Sass variables and add mixin for alert box-shadow 2019-02-21 01:13:54 +00:00
Tiago Noronha c304760629 Add `store-alerts` feature flag 2019-02-21 00:41:00 +00:00
Kelly Dwan b98c05c331 Components: Add SearchListControl (https://github.com/woocommerce/woocommerce-admin/pull/1628)
* Add SearchListControl as exported component

* Add entry to changelog (and fix versioning)

* Fix repeating character mixin

* Update textdomain
2019-02-20 15:18:27 -05:00
Tiago Noronha 1d864c222c Fix line break 2019-02-20 19:03:08 +00:00
Tiago Noronha 91b09bfe4b Add propTypes 2019-02-20 16:37:03 +00:00
Tiago Noronha f492dae5a2 Simplify name of consts 2019-02-20 16:18:10 +00:00
Tiago Noronha 4f8336ce3d Add alerts array via props 2019-02-20 15:25:56 +00:00
Justin Shreve c3b0934ad3 Close the WP menu after navigating between reports (https://github.com/woocommerce/woocommerce-admin/pull/1634) 2019-02-20 10:18:27 -05:00
Tiago Noronha d9f9532939 Use interpolateComponents for pagination label 2019-02-20 11:50:55 +00:00
Albert Juhé Lluveras 0a10291969 Don't show variations table when there is an active search (https://github.com/woocommerce/woocommerce-admin/pull/1601) 2019-02-20 10:21:19 +01:00
Albert Juhé Lluveras 1660484d4c Escape commas in search terms (https://github.com/woocommerce/woocommerce-admin/pull/1605) 2019-02-20 10:21:05 +01:00
Albert Juhé Lluveras 5e4f14a81d Fix style of dashboard summary number placeholder (https://github.com/woocommerce/woocommerce-admin/pull/1623)
* Fix style of dashboard summary number placeholder

* Make store performance block to be a normal <div> instead of a Card

* Fix dashboard summary numbers style

* Simplify code
2019-02-20 10:20:50 +01:00
Joshua T Flowers 73ff2d37e8 Update activity panels order endpoint (https://github.com/woocommerce/woocommerce-admin/pull/1578)
* Only show customer name if available

* Map customer data to extended_info in orders API response

* Add gross total and refund total to orders API response

* Hook up report orders endpoint to activity panel orders

* Add on-hold orders to activity panel orders

* Destructure extended_info in case of filtering

* Add customer link to orders panel
2019-02-20 09:51:43 +08:00
Tiago Noronha 8bc2a84b39 Add basic StoreAlert component 2019-02-19 21:07:19 +00:00
Justin Shreve 4f64358c8e Fix customer filters and download user filtering (https://github.com/woocommerce/woocommerce-admin/pull/1618)
* Add the ability to search name, username, and email fields on the customer endpoint, update autocompletors, add in include parameter.

* Update the username to be returned in the download response, update download filtering based on customer id, and only rename include parameter on main customers endpoint.
2019-02-19 14:35:29 -05:00
Justin Shreve 732a8a4986 Fix variation name format to match core (https://github.com/woocommerce/woocommerce-admin/pull/1583) 2019-02-18 13:24:48 -05:00
Justin Shreve 79dc87b9bb Fix product category report views (https://github.com/woocommerce/woocommerce-admin/pull/1587) 2019-02-18 13:18:21 -05:00
Tiago Noronha 6d58ed97c4 Add array of notice ids and/or classes and iterate to collapse 2019-02-15 18:01:18 +00:00
Ron Rennick 00b640e2f0 Merge pull request woocommerce/woocommerce-admin#1567 from woocommerce/fix/1450
update chart type query string key to chartType
2019-02-15 12:58:22 -04:00
Ron Rennick 9f911df053 update changelog, coding style per review 2019-02-15 10:37:56 -04:00
Albert Juhé Lluveras b61dff32f9 Sort tabular data when selecting a Summary Number (https://github.com/woocommerce/woocommerce-admin/pull/1564)
* Sort tabular data when selecting a Summary Number

* Fix 'orderby' param in orders endpoint
2019-02-15 11:54:41 +01:00
Tiago Noronha 75ee8d600b Merge pull request woocommerce/woocommerce-admin#1533 from woocommerce/fix/1511-advanced-filters-ie11
Advanced filters alignment in IE11
2019-02-14 21:23:29 +00:00
Tiago Noronha 92de076a45 Hide Hello Dolly lyrics 2019-02-14 21:05:36 +00:00
Tiago Noronha db2ed027c4 Add strings back to config.js files with title placeholders 2019-02-14 20:53:08 +00:00
Paul Sealock 2e82211616 Add products/stats endpoint to categories 2019-02-15 09:44:46 +13:00
Paul Sealock 87151fa1e3 Merge pull request woocommerce/woocommerce-admin#1548 from woocommerce/fix/stock-status-link
Stock Report: fix stock link
2019-02-15 09:42:37 +13:00
Ron Rennick f5efd10638 fix merge conflicts 2019-02-14 14:11:15 -04:00
Ron Rennick 7f4bb8df63 update chart type query string key to chartType 2019-02-14 13:35:08 -04:00
Timmy Crawford ffe45e0658 Up freshness interval default. (https://github.com/woocommerce/woocommerce-admin/pull/1549) 2019-02-14 09:23:36 -08:00
Tiago Noronha 34ece8b72d Stop Hello Dolly lyrics from displaying in the notices tab 2019-02-14 15:33:03 +00:00
Justin Shreve 24301e0090 Add stock stats endpoint and hook up to the stock report. (https://github.com/woocommerce/woocommerce-admin/pull/1535)
* Add stock stats endpoint and hook up to the stock report.

* Handle PR feedback
2019-02-13 22:31:27 -05:00
Joshua T Flowers 7d7e1f61b3 Prevent hash creation from breadcrumbs (https://github.com/woocommerce/woocommerce-admin/pull/1540) 2019-02-14 11:15:30 +08:00
Tiago Noronha 9d8ed29ea3 IE11: Move placeholders from config files to components and add span around title 2019-02-14 01:35:47 +00:00
Paul Sealock f9eec81e71 Stock Report: fix stock link 2019-02-14 13:19:21 +13:00
Jeff Stieler c862de29d3 Merge pull request woocommerce/woocommerce-admin#1534 from woocommerce/fix/1455-customers-report-name-search
Hook up customers report table search box
2019-02-13 13:55:47 -08:00
Albert Juhé Lluveras c10d849d85 Add defaults to Revenue table data (https://github.com/woocommerce/woocommerce-admin/pull/1546) 2019-02-13 20:37:25 +01:00
Jeff Stieler d830a4a257 Fix customer name display in advanced filter search box. 2019-02-13 09:48:14 -07:00
Joshua T Flowers 847b59246d Add transient notices (https://github.com/woocommerce/woocommerce-admin/pull/1423)
* Add initial transient notices component

* Animate notices to slide in and out

* Add notices to wc-api

* Map notices from wc-api to transient notices

* Add success message on settings save

* Add save notices to Settings page

* Remove all margin and padding from notice box when empty

* Add role alert to transient notices

* Add prefers reduced motion media query for transient animation

* Remove initial test notice

* Remove notices from wc-api

* Add wc-admin store for transient notices

* Pull transient notices from newly implemented store

* Use speak instead of role alert for accessibility

* Only show success message after request is complete

* Destructure state in componentDidUpdate

* Add store notice tests and fixtures

* Add box shadow to transient notice

* Move transient notices to bottom left

* Fix indentation
2019-02-13 19:44:58 +08:00
Albert Juhé Lluveras 4962ee5e4e Empty chart message (https://github.com/woocommerce/woocommerce-admin/pull/1499)
* Show empty chart and summary numbers when search returns no results

* Preserve chart mode in empty searches

* Show message in empty charts

* Improve code order

* Add CHANGELOG message

* Rename emptySearch to emptySearchResults

* Improve emptyMessage propTypes comment

* Remove duplicated code

* Improve CHANGELOG message

* Create util function to check if chart is empty

* Update CHANGELOG message

* Add baseValue prop to Chart
2019-02-12 22:42:02 +01:00
Justin Shreve 0fe061b97d Add Feature Flags (https://github.com/woocommerce/woocommerce-admin/pull/1500)
* First pass at adding feature flags. Accessible over PHP and JS.

* Hook up dev config to test enviornments, hook up features to their flags.

* Cleanup some code and add documentation. Remove beta config.

* Handle PR Feedback: Add devdocs flag, remove categories flag, fix auto-generated PHP warning.

* Add todo for beta phase.

* Handle PR feedback: Simplify is_array check, update build command, simplify test mock, remove empty webpack line.
2019-02-12 15:02:02 -05:00
Tiago Noronha 20aacb4fd8 Remove on hover color from disabled button 2019-02-11 12:54:40 +00:00
Albert Juhé Lluveras b3e028bc81 Show empty chart and summary numbers when search returns no results (https://github.com/woocommerce/woocommerce-admin/pull/1491)
* Show empty chart and summary numbers when search returns no results

* Add changelog message

* Preserve chart mode in empty searches

* Add tests

* Fix CSS Lint error

* Make sure the legend updates when there is no data and it's not requesting

* Rename 'emptySearch' to 'emptySearchResults'

* Fix tests
2019-02-07 10:57:47 +01:00
Joshua T Flowers 8c3973a445 Add manage_stock to stock controller response (https://github.com/woocommerce/woocommerce-admin/pull/1475)
* Add manage_stock to stock controller response

* Add manage_stock property to stock report tests

* Add changelog entry

* Make stock quantity float instead of int

* Add manage_stock to the products API response

* Check for manage_stock in products table

* Add manage_stock property to product API tests
2019-02-07 16:29:01 +08:00
Albert Juhé Lluveras 79738b2022 Add 'variations' attribute in products 'extended_info' (https://github.com/woocommerce/woocommerce-admin/pull/1478)
* Add 'variations' attribute in products 'extended_info'

* Add tests
2019-02-07 09:27:02 +01:00
Kevin Killingsworth 8b7e309e6f navigation: Lazy-create history (https://github.com/woocommerce/woocommerce-admin/pull/1472)
history.createHashHistory() is being called whenever this package is
imported, which causes the URL to redirect to a hash. This is
unnecessary in cases where elements of wc-admin are used outside of a
completely controlled/routed page.

This lazy-creates the history object only when it's needed and therefore
avoids the URL redirection unless history features are in use.
2019-02-06 13:28:29 -06:00
Justin Shreve a1bbd22ca2 Update product details report to use getItems (https://github.com/woocommerce/woocommerce-admin/pull/1488) 2019-02-06 11:24:40 -05:00
Justin Shreve 81fcab5709 Fix product comparison + color scale on charts with lots of options (https://github.com/woocommerce/woocommerce-admin/pull/1481)
* Fix color scale on charts with lots of options

* Fix product comparison
2019-02-06 10:46:37 -05:00
Joshua T Flowers b7379def1b Format todo comments to match WC Core format (https://github.com/woocommerce/woocommerce-admin/pull/1474)
* Format todo comments to match WC Core format

* Remove variations todo comment
2019-02-06 14:41:53 +08:00
Justin Shreve 949afce248 Add Product Detail Report & Finish Comparison Chart Mode Functionality (https://github.com/woocommerce/woocommerce-admin/pull/1391)
Product detail report and comparison

Code cleanup

Fix 404 on product variations endpoint after rebase

Fix up tests

Fix loading indicators and add some checks around malformed variation response

Add date filtering SQL bits to the variations query

Handle PR feedback: Fix viewport, fix duplicate product issue, fix legend display reset, fix bargraph overflow, fix some coding standards/whitespace, add extra variation santiziation.

Fix scroll on wide charts, and fix undefined prop getting passed into report chart render
2019-02-05 13:12:58 -05:00
Albert Juhé Lluveras 84ef5ffb89 Show empty table when search returns no results (https://github.com/woocommerce/woocommerce-admin/pull/1452)
* Show empty table when search returns no results

* Fix singular wrong string for 'orders'

Co-Authored-By: Aljullu <aljullu@gmail.com>

* Check if search returned 0 results inside table components instead of passing a prop
2019-02-05 13:00:37 +01:00
Albert Juhé Lluveras 9dd4c10d7d Fix autocompleters in customers and taxes report (https://github.com/woocommerce/woocommerce-admin/pull/1458) 2019-02-04 09:51:29 +01:00
Joshua T Flowers fb0d71f117 Update page query to 1 when base query is changed (https://github.com/woocommerce/woocommerce-admin/pull/1444)
* Update page query to 1 when base query is changed

* Use history replace instead of updating query
2019-02-04 10:55:06 +08:00
Joshua T Flowers 2c1f8c17c7 Fix incorrect label async request paths (https://github.com/woocommerce/woocommerce-admin/pull/1447) 2019-02-04 10:50:22 +08:00
Albert Juhé Lluveras 666d8e4a3b Merge getOrders and getItems (https://github.com/woocommerce/woocommerce-admin/pull/1438)
* Move labels loading logic into a lib

* Move lib/labels into lib/async-requests

* Implement tabular data filtering

* Allow searching for string in report tables

* Add table filtering to customers table

* Get ids from searched string to populate the table

* Fix autocompleter keyboard interactions

* Improve props naming

* Cleanup report customers data store

* Prevent an edge case issue that might not update the selectedOptions when directily modifying the URL

* Fix wrong selected autocompleter option

* Add missing translation domain

* Move searchItemsByString to wc-api/items/utils.js

* Avoid autocompleter results appearing when there was no search string

* Alphabetically order 'allowFreeTextSearch' prop

* Reset selected table rows when directly modifying the URL

* Simplify props destructuring

* Undo customers data store change

* Simplify isProductDetailsView expression

* Improve order

* Merge getOrders and getItems
2019-02-01 11:01:42 +01:00
Albert Juhé Lluveras d8ed3b6614 Implement tabular data filtering (https://github.com/woocommerce/woocommerce-admin/pull/1381)
* Move labels loading logic into a lib

* Move lib/labels into lib/async-requests

* Implement tabular data filtering

* Allow searching for string in report tables

* Add table filtering to customers table

* Get ids from searched string to populate the table

* Fix autocompleter keyboard interactions

* Improve props naming

* Cleanup report customers data store

* Prevent an edge case issue that might not update the selectedOptions when directily modifying the URL

* Fix wrong selected autocompleter option

* Add missing translation domain

* Move searchItemsByString to wc-api/items/utils.js

* Avoid autocompleter results appearing when there was no search string

* Alphabetically order 'allowFreeTextSearch' prop

* Reset selected table rows when directly modifying the URL

* Simplify props destructuring

* Undo customers data store change

* Simplify isProductDetailsView expression

* Improve order

* Filter tax code parts before modifying them
2019-02-01 10:55:19 +01:00
Joshua T Flowers e65247c54e Add SKU to product variations table (https://github.com/woocommerce/woocommerce-admin/pull/1422)
* Add SKU to product variations data store extended info

* Show SKU in product variations table

* Add sku tests for product variation reports
2019-01-31 09:27:15 +08:00
Joshua T Flowers 49e78b90cf Add settings page with excluded order statuses (https://github.com/woocommerce/woocommerce-admin/pull/1364)
* Add settings page routes

* Add control options for excluded statuses

* Add control options for excluded statuses

* Add excluded order statuses to rest api

* Add wc settings to wc-api

* Add wc settings to wc-api

* Split and validate multiselect values in settings controller

* Add wcAdminSettings to wcSettings global

* Set initial excluded statuses from serverside wcSettings data

* Add extensible filter for wcSettings global

* Split arrays into comma separated strings in wc-api

* Extract setting as separate component

* Extra settings to config file

* Add checkboxGroup option as input type

* Separate status types into default and custom groups

* Add setting option styling

* Add responsive styling for settings

* Fix wpClosedMenu and wpOpenMenu for settings page

* Add support for resetting to default values

* Only show checkbox group if options are available

* Add proptypes to Setting component

* Add extensible filter to analytics settings

* Add readme for settings config and extensibility

* Hook up excluded status settings to reports

* Pass object to settings API instead of comma delimited string

* Fix inpuType -> inputType typo

* Remove hasError from constructor

* Bump settings API to v4

* Use interpolateComponents instead of dangerously setting html

* Use empty array in initial excldued statuses setting value if none is retrieved

* Remove double check for refunded status in default order statuses

* Update settings wc-api to use namespace

* Add aria=labelledby to checkbox group
2019-01-31 09:04:11 +08:00
Justin Shreve 53a6e49874 Finish cleaning up client/store. (https://github.com/woocommerce/woocommerce-admin/pull/1403) 2019-01-30 02:22:10 -05:00
Paul Sealock f71bfa95f4 Merge pull request woocommerce/woocommerce-admin#1406 from woocommerce/fix/customers-order-count-filter
Customers Report: fix order count filter
2019-01-30 10:32:29 +13:00
Timmy Crawford 10c6016d4c Update usage of lib/number to @woocommerce/number (https://github.com/woocommerce/woocommerce-admin/pull/1400)
* Remove usage of lib/number

* Remove formatNumber usage when currency is used.

* Add wc-number as a dependency of wc-currency.

* Add locutus as a dev dependency.

* Add number to test helper.
2019-01-29 08:48:46 -08:00
Paul Sealock 3379491c91 Customers Report: fix order count filter 2019-01-29 13:35:27 +13:00
Kevin Killingsworth 833345dfee Remove 'wc-admin' client/store implementation (https://github.com/woocommerce/woocommerce-admin/pull/1344)
This has been replaced by the `wc-api` store, under client/wc-api
2019-01-28 14:18:21 -05:00
Jeff Stieler 7592dae4bb Merge pull request woocommerce/woocommerce-admin#1385 from woocommerce/add/customers-report-table-summary
Add table summary to Customers Report
2019-01-28 09:59:52 -07:00
Albert Juhé Lluveras 066daa4b6a Add Top Coupons Block (https://github.com/woocommerce/woocommerce-admin/pull/1397)
* Add Top Coupons Block

* Order coupons by orders_count by default

* Fix wrong variable name
2019-01-25 18:59:53 +01:00
Joshua T Flowers 9c9ff13c2b Allow customer date_last_active to be null (https://github.com/woocommerce/woocommerce-admin/pull/1377)
* Allow customer date_last_active to be null

* Only show last active in customers report table if set
2019-01-25 09:37:50 -08:00
Paul Sealock 050438a11c Add emoji flags 2019-01-25 13:17:08 +13:00
David Levin 74fcff642c Merge pull request woocommerce/woocommerce-admin#1382 from woocommerce/update/total-spend-label
Customer report: Update lifetime spend label and re-order columns + default sorting
2019-01-24 09:04:40 -08:00
Albert Juhé Lluveras 95c21e0cc3 Move 'getLabels' functions into lib/async-requests (https://github.com/woocommerce/woocommerce-admin/pull/1379)
* Move labels loading logic into a lib

* Avoid making API calls when displaying Order labels

* Move lib/labels into lib/async-requests

* Rename 'getCustomerLabel' to 'getCustomerLabels'
2019-01-24 10:35:27 +01:00
Joshua T Flowers 81b6f0f61b Use tableQuery sorting when url query is not present (https://github.com/woocommerce/woocommerce-admin/pull/1378) 2019-01-24 09:36:11 +08:00
David Levin 4c18267408 update orderby in index 2019-01-23 10:08:27 -08:00
David Levin e7a20b4216 update column lifetime spend column label, and re-order columns 2019-01-23 09:51:12 -08:00
Paul Sealock 3521e8d485 Merge pull request woocommerce/woocommerce-admin#1329 from woocommerce/fix/reduce-margin-small-views
Reports: Reduce Margins on Small Viewports
2019-01-23 14:38:48 +13:00
Jeff Stieler 0ef976f964 Increase default wc-api timeout to 1 minute.
Large datasets may cause responses to take longer than 5 seconds.
2019-01-22 11:22:28 -07:00
David Levin e9bb73f23d Update order of summary numbers on taxes report (https://github.com/woocommerce/woocommerce-admin/pull/1356) 2019-01-22 07:49:17 -08:00
Paul Sealock 0e01c98851 Reports: Reduce Margins on Small Viewports 2019-01-22 12:29:32 +13:00
Paul Sealock a52fab85de Merge pull request woocommerce/woocommerce-admin#1332 from woocommerce/fix/summary-number-close-on-mobile
SummaryNumbers: close on click for mobile
2019-01-22 12:09:07 +13:00