oc-shopaholic / oc-orders-shopaholic-plugin

🛒 Orders (cart) extension for Shopaholic plugin
https://octobercms.com/plugin/lovata-ordersshopaholic
GNU General Public License v3.0
27 stars 18 forks source link

Create Analytics Scoreboard #193

Open Kation-a opened 2 months ago

Kation-a commented 2 months ago

Scoreboard should have the opportunity to view statics for:

  1. Today
  2. Yesterday
  3. Last 7 days (started from today)
  4. Last month (30 days started from today)
  5. Last year (365 days started from today)
  6. All (all the data stored in database)
Widgets on the Scoreboard Name Graph type Comments
Total orders title-value-1 Sum of all order prices for the period of time + comparison with the previous period. There's a description for this widget. It should count values for the previous chosen period, eg: previous day, week, month, year. It should not appear when the period set to "all"
Sales by Status chart-bar Sum of all order prices for the period of time grouped by order status
Sales by Payment Method chart-pie Sum of all order prices for the period of time grouped by payment method
Sales by Shipping Type chart-pie Sum of all order prices for the period of time grouped by shipping type
Salea by Site chart-bar Sum of all order prices for the period of time grouped by site language
Order Count by Status chart-bar Number of sales occured for the period of time grouped by order status
Completion Time title-value-2 Average time taken for orders to move from 'new' to 'complete' status. Count only completed orders. The widget should look like: Completion Time - {number of days} - days
Order by Site chart-pie Number of sales occured for the period of time grouped by site languge
Graph type Examples Type Code Example
title-value-1 \<div class="scoreboard-item title-value">
\<h4>Comments\</h4>
\<p class="positive">44\</p>
\<p class="description">previous month: 32\</p>
\</div>
image
chart-bar
\<div class="scoreboard-item control-chart" data-control="chart-bar">
\<ul>
\<li data-color="#95b753">Published \<span>84\</span>\</li>
\<li data-color="#e5a91a">Drafts \<span>12\</span>\</li>
\<li data-color="#cc3300">Deleted \<span>18\</span>\</li>
\</ul>
\</div>
image
chart-pie \<div class="scoreboard">
\<div data-control="toolbar">
\<div class="scoreboard-item control-chart" data-control="chart-pie">
\<ul>
\<li data-color="#95b753">Published \<span>84\</span>\</li>
\<li data-color="#e5a91a">Drafts \<span>12\</span>\</li>
\<li data-color="#cc3300">Deleted \<span>18\</span>\</li>
\</ul>
\</div>
image
title-value-2 \<div class="scoreboard-item title-value">
\<h4>Weight\</h4>
\<p>100\</p>
\<p class="description">unit: kg\</p>
\</div>
image
Kation-a commented 2 months ago

https://octobercms.com/docs/ui/scoreboard - Documentation