Forums / All Other Contributions/Addons / Modern admin dashboard

Modern admin dashboard

Results 1 to 20 of 58
11 Jan 2026, 17:03
#1
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Modern admin dashboard

I've created a pull request for this and it will hopefully be part of Zen Cart 2.2.0, but this commit will not work with any version prior to 2.2.0 because of the currencies class which needs to be included manually on versions 2.1.0 and older.

For anyone using Zen Cart 2.1.0 (and probably any other version down to 1.5.8), you can use this "plugin" to achieve the same look:
https://zenexpert.com/zen-cart-modern-admin-dashboard

Will submit to plugins if no bugs are reported.

Attachment 21125
11 Jan 2026, 22:07
#2
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

Error displayed on screen bottom RH corner. Image is attached.
1055 'zc220_exp.pd.products_name' isn't in GROUP BY
in:
[SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold FROM orders_products op JOIN orders o ON op.orders_id = o.orders_id JOIN products p ON op.products_id = p.products_id JOIN products_description pd ON (p.products_id = pd.products_id AND pd.language_id = 1) WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY) GROUP BY p.products_id ORDER BY total_sold DESC LIMIT 5]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you entered valid data.

error-log
[12-Jan-2026 07:55:34 Australia/Brisbane] Request URI: /zc220_exp/public/admin/, IP address: 192.168.1.63, Language id 1#0 [internal function]: zen_debug_error_handler()
#1 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(757): trigger_error()
#2 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(701): queryFactory->show_error()
#3 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(314): queryFactory->set_error()
#4 E:\Web\zc220_exp\public\admin\includes\modules\dashboard_widgets\MostPopularProductsDashboardWidget.php(21): queryFactory->Execute()
#5 E:\Web\zc220_exp\public\admin\index_dashboard.php(141): include('E:\\Web\\zc220_ex...')
#6 E:\Web\zc220_exp\public\admin\home.php(27): require('E:\\Web\\zc220_ex...')
#7 E:\Web\zc220_exp\public\admin\index.php(16): require('E:\\Web\\zc220_ex...')
--> PHP Fatal error: FATAL MySQL error 1055: 'zc220_exp.pd.products_name' isn't in GROUP BY :: SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold
        FROM orders_products op
        JOIN orders o ON op.orders_id = o.orders_id
        JOIN products p ON op.products_id = p.products_id
        JOIN products_description pd ON (p.products_id = pd.products_id AND pd.language_id = 1)
        WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY)
        GROUP BY p.products_id
        ORDER BY total_sold DESC
        LIMIT 5 ==> (as called by) E:\Web\zc220_exp\public\admin\includes\modules\dashboard_widgets\MostPopularProductsDashboardWidget.php on line 21 <== in E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php on line 757.




Environment: Zen Cart 2.2.0; Apache 2.4.63; PHP 8.4.16; MySQL 11.8.5-MariaDB-log; Windows 11
11 Jan 2026, 22:13
#3
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Posts:
9,707
Plugin Contributions:
6

Re: Modern admin dashboard

Sorry, saw the 2.2.0 finally

Are you using github or the zip?
11 Jan 2026, 22:23
#4
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

OldNGrey:

Error displayed on screen bottom RH corner. Image is attached.
1055 'zc220_exp.pd.products_name' isn't in GROUP BY
in:
[SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold FROM orders_products op JOIN orders o ON op.orders_id = o.orders_id JOIN products p ON op.products_id = p.products_id JOIN products_description pd ON (p.products_id = pd.products_id AND pd.language_id = 1) WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY) GROUP BY p.products_id ORDER BY total_sold DESC LIMIT 5]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you entered valid data.

error-log
[12-Jan-2026 07:55:34 Australia/Brisbane] Request URI: /zc220_exp/public/admin/, IP address: 192.168.1.63, Language id 1#0 [internal function]: zen_debug_error_handler()
#1 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(757): trigger_error()
#2 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(701): queryFactory->show_error()
#3 E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php(314): queryFactory->set_error()
#4 E:\Web\zc220_exp\public\admin\includes\modules\dashboard_widgets\MostPopularProductsDashboardWidget.php(21): queryFactory->Execute()
#5 E:\Web\zc220_exp\public\admin\index_dashboard.php(141): include('E:\\Web\\zc220_ex...')
#6 E:\Web\zc220_exp\public\admin\home.php(27): require('E:\\Web\\zc220_ex...')
#7 E:\Web\zc220_exp\public\admin\index.php(16): require('E:\\Web\\zc220_ex...')
--> PHP Fatal error: FATAL MySQL error 1055: 'zc220_exp.pd.products_name' isn't in GROUP BY :: SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold
        FROM orders_products op
        JOIN orders o ON op.orders_id = o.orders_id
        JOIN products p ON op.products_id = p.products_id
        JOIN products_description pd ON (p.products_id = pd.products_id AND pd.language_id = 1)
        WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY)
        GROUP BY p.products_id
        ORDER BY total_sold DESC
        LIMIT 5 ==> (as called by) E:\Web\zc220_exp\public\admin\includes\modules\dashboard_widgets\MostPopularProductsDashboardWidget.php on line 21 <== in E:\Web\zc220_exp\public\includes\classes\db\mysql\query_factory.php on line 757.




Environment: Zen Cart 2.2.0; Apache 2.4.63; PHP 8.4.16; MySQL 11.8.5-MariaDB-log; Windows 11


MySQL is in strict mode...
Can you please try updating admin\includes\modules\dashboard_widgets\MostPopularProductsDashboardWidget.php
Replace
$sql = "SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold
        FROM " . TABLE_ORDERS_PRODUCTS . " op
        JOIN " . TABLE_ORDERS . " o ON op.orders_id = o.orders_id
        JOIN " . TABLE_PRODUCTS . " p ON op.products_id = p.products_id
        JOIN " . TABLE_PRODUCTS_DESCRIPTION . " pd ON (p.products_id = pd.products_id AND pd.language_id = " . (int)$_SESSION['languages_id'] . ")
        WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY)
        GROUP BY p.products_id
        ORDER BY total_sold DESC
        LIMIT 5";

with
$sql = "SELECT p.products_id, pd.products_name, p.products_image, p.products_model, SUM(op.products_quantity) as total_sold
        FROM " . TABLE_ORDERS_PRODUCTS . " op
        JOIN " . TABLE_ORDERS . " o ON op.orders_id = o.orders_id
        JOIN " . TABLE_PRODUCTS . " p ON op.products_id = p.products_id
        JOIN " . TABLE_PRODUCTS_DESCRIPTION . " pd ON (p.products_id = pd.products_id AND pd.language_id = " . (int)$_SESSION['languages_id'] . ")
        WHERE o.date_purchased >= DATE_SUB(NOW(), INTERVAL 30 DAY)
        GROUP BY p.products_id, pd.products_name, p.products_image, p.products_model
        ORDER BY total_sold DESC
        LIMIT 5";

Notice the text in red - that's the only addition.
Please report back - this will probably need to be updated in the PR as well.
11 Jan 2026, 22:25
#5
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

The error is due to the DB_MYSQL_MODE setting ONLY_FULL_GROUP_BY which is on by default in MYSQL.
Without this setting the page displays fully.
12 Jan 2026, 05:40
#6
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

Yes updating the GROUP BY statement works.
12 Jan 2026, 06:00
#7
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

Thanks for the update.

If there are any other bugs, or even better - suggestions, I'm happy to hear it! I've also redesigned the header, but I have a feeling it won't be welcomed because we're all used to the styling that's been with us for decades... Although new users might like it? If anyone is interested in taking it for a spin, please PM me.

Attachment 21131
12 Jan 2026, 06:27
#8
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

Post a link to the header and I'll give it a try.
12 Jan 2026, 06:36
#9
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

OldNGrey:

Post a link to the header and I'll give it a try.


Yeah, probably easier. :lamo:

Same link as above - the zip file now contains two separate folders, one for dashboard and one for header.
12 Jan 2026, 08:11
#10
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

Just updated the zip file - I uploaded with wrong structure and missing language file... Same download link as in post #1
13 Jan 2026, 01:29
#11
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

Thats better. With some minor tweaking I'm getting used to the headings. I think it is a good effort and I'll continue to use it.

Testing on ZC 2.2.0
Some suggestions.
  • change leaf icon to home icon [ fa fa-leaf -> fa fa-home] Old-fashioned but I instantly know what it represents.
  • place inline styles in css file . This allows for local customisation. In Admin a lot of whitespace can be reduced
  • files-header-only\YOUR_ADMIN\includes\languages\lang.english.php needs updating eg missing ln140 BUTTON_SAVE_ALL' => 'Save All Changes', etc
    OR
    maybe save just your additions in lang.header.php to avoid overwrites. I have done this and placed your additions in lang.header.php in admin/includes/languages/english/extra_definitions and it is working well. I have my site overides here eg date formats, metric values, set locale etc


  • your have menu.css in both "\files-header-only\YOUR_ADMIN\css" and "\files-header-only\YOUR_ADMIN\includes\css"
13 Jan 2026, 04:57
#12
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

Thanks for the feedback!

menu.css - I think you downloaded the zip file just moments before I had updated it. :smile:

BUTTON_SAVE_ALL - that's from v2.2.0 (from the configuration menu) and this set of files is meant for 2.1.0 (or earlier). lang.header.php is specific to the frontend, but extra_definitions might be a good idea, especially if it's going as a plugin - will do.

Will make the changes as suggested (leaf icon and inline styles).
13 Jan 2026, 17:48
#13
pilou2 avatar

pilou2

Zen Follower

Join Date:
Jun 2008
Posts:
332
Plugin Contributions:
0

Re: Modern admin dashboard

I tested the GitHub version and there was no problem. I really like it, it looks great!
On this page the Widget I use the most is the order one to check for new orders or follow orders' flow in general. It is now at a better place in the screen, really easier to check.
If you want some idea that might improve things (a little bit), why not use the space between the title 'New orders' and the button on the right 'View All' to add all the status possible colors with a count of orders beside (for each category). Like this:
Attachment 21133
13 Jan 2026, 20:18
#14
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

pilou2:

I tested the GitHub version and there was no problem. I really like it, it looks great!
On this page the Widget I use the most is the order one to check for new orders or follow orders' flow in general. It is now at a better place in the screen, really easier to check.

Glad to hear you like it!
Feel free to try the new header as well :wink:

pilou2:


If you want some idea that might improve things (a little bit), why not use the space between the title 'New orders' and the button on the right 'View All' to add all the status possible colors with a count of orders beside (for each category). Like this:
Attachment 21133


Not sure I quite understand this - what's the purpose of that when there's a sidebar box "Orders by Status". If you just move the Top Sellers to the top, it would be side by side with orders list...
Also, are you suggesting to show ALL statuses in that space with the same counters that's currently in the sidebar? This would work with probably 3-4 statuses, but I have a client with 10 statuses - imagine the clutter this would cause... I can't decide which IDs are more important (someone might have ID 75 as Processing), and if you want to have admin control over which orders show and which don't, ugh...

But as you mentioned all possible status colors - one thing I would LOVE to add is user-selected color code for each order status. It would require a new field in orders_status table and an input field on orders_status page, but it would allow the user to color-code each of their status as they wish - at the moment it's hard-coded (which I really hate) and only covers IDs 1-4, but you might want to see a red label for cancelled orders or purple label for delivered...
And then the same color-coding can be used on the orders listing page (sample below). Not sure how the Team feels about it, but I'm more than happy to PR this.

Attachment 21134
13 Jan 2026, 21:36
#15
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Posts:
9,707
Plugin Contributions:
6

Re: Modern admin dashboard

I've tried both and really like both. The new header seems to be a little more lenient when reaching the end of a dropdown.

Customer feedback is mixed. As pilou2 pointed out, different parts of the page are important to some folks. One customer had us relocate the old orders (now Orders by Status) to its current position in the upper-right corner, as that was their primary focus. They often have to obtain supplies to fill orders, and they are seldom sent out in sequential order.

Another customer wants the emphasis on New orders: as their orders always go out within 1 business day. Their New orders rarely have a "Processing" hidden on page 2 of the orders. <nitpickAlert> Mixed case often leads to missing important items. "New orders" does seem to be the only one.</nitpickAlert>

In looking at the layout, I was wondering if each section could be moved to a preferred spot on the page. I was looking for something like the method lat9 uses for the Login-Page Layout (L;P,G,C;B) or the "slider" for the Layout Boxes Controller. With a method like either of those, you'd really make owners happy.

I personally have my browser set to auto-zoom to 150% and use the largest font. Old age and trifocals will do that to you. Even when I go back to 100% and the recommended font, so much of the information is still "below the fold". To me, the top row and the dashboard SalesChart keep me from seeing items that I might want to see first. 385px high is a lot of real estate even on today's larger monitors. On mobile, even though the first item on the page is Orders Today, you're at the bottom of the second page before seeing New orders. If I'm looking for a specific customer to make an order, I'd have to do some scrolling to find it. Again, owner adjustment of the locations would be nice.

I also wondered if, with the now available YOUR_ADMIN/includes/css/dist-site-specific-styles.php, it might be helpful to take the CSS out of the files and provide a quote-surrounded block to be added to the renamed site-specific-styles.php. Sort of keeping all the eggs in one basket. One slip editing the CSS in the mod's core has far worse implications than in the site-specific-styles.php.

Also, Maximum Display of Orders on Orders Page is set to 20 yet the page only shows 10 orders.

I'm fully aware of the saying about opinions and I really don't want to come across as denigrating your work. I fully support what you're doing here and will assist in whatever way I can. Coding, not so much.:P Nitpicky? I'm your man. Just ask haredo.
13 Jan 2026, 22:05
#16
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Posts:
2,841
Plugin Contributions:
0

Re: Modern admin dashboard

balihr:

Glad to hear you like it!
Feel free to try the new header as well :wink:



Not sure I quite understand this - what's the purpose of that when there's a sidebar box "Orders by Status". If you just move the Top Sellers to the top, it would be side by side with orders list...
Also, are you suggesting to show ALL statuses in that space with the same counters that's currently in the sidebar? This would work with probably 3-4 statuses, but I have a client with 10 statuses - imagine the clutter this would cause... I can't decide which IDs are more important (someone might have ID 75 as Processing), and if you want to have admin control over which orders show and which don't, ugh...

But as you mentioned all possible status colors - one thing I would LOVE to add is user-selected color code for each order status. It would require a new field in orders_status table and an input field on orders_status page, but it would allow the user to color-code each of their status as they wish - at the moment it's hard-coded (which I really hate) and only covers IDs 1-4, but you might want to see a red label for cancelled orders or purple label for delivered...
And then the same color-coding can be used on the orders listing page (sample below). Not sure how the Team feels about it, but I'm more than happy to PR this.

Attachment 21134


custom coloring the label sound like a brilliant idea to me.
additionally, while adding a field you could also add a "visible in widget" field for those people that set up a lot of order statuses but are not important for display in the homepage widget. it could also be extended, because I am a glutton for punishment, to be stored as custom settings per admin user. As different admin users may have different needs as to what order statuses are important to their job.
13 Jan 2026, 22:11
#17
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

dbltoe:

I've tried both and really like both. The new header seems to be a little more lenient when reaching the end of a dropdown.

Could you dumb this down for me, please? Keep in mind English is not my native language, I really don't know what you're saying here. :smile:

dbltoe:

Customer feedback is mixed. As pilou2 pointed out, different parts of the page are important to some folks. One customer had us relocate the old orders (now Orders by Status) to its current position in the upper-right corner, as that was their primary focus. They often have to obtain supplies to fill orders, and they are seldom sent out in sequential order.

Another customer wants the emphasis on New orders: as their orders always go out within 1 business day. Their New orders rarely have a "Processing" hidden on page 2 of the orders. <nitpickAlert> Mixed case often leads to missing important items. "New orders" does seem to be the only one.</nitpickAlert>

In looking at the layout, I was wondering if each section could be moved to a preferred spot on the page. I was looking for something like the method lat9 uses for the Login-Page Layout (L;P,G,C;B) or the "slider" for the Layout Boxes Controller. With a method like either of those, you'd really make owners happy.

Brilliant idea and something I was actually considering to do, but I'd prefer to get this pushed into core code instead of making it a plugin (thus the PR for 2.2.0). The more complex we make it, the less chance of it becoming core so this was the bare minimum I could do.
What I really wanted to do was to have a drag-and-drop grid (similar to layout boxes controller) where user would re-arrange dashboard widgets as they wish, but I'm afraid that would be too much to get adopted into core. So yeah, just a visually modernized dashboard and you still have to edit code to rearrange location (just like it currently is).

dbltoe:

I personally have my browser set to auto-zoom to 150% and use the largest font. Old age and trifocals will do that to you. Even when I go back to 100% and the recommended font, so much of the information is still "below the fold". To me, the top row and the dashboard SalesChart keep me from seeing items that I might want to see first. 385px high is a lot of real estate even on today's larger monitors. On mobile, even though the first item on the page is Orders Today, you're at the bottom of the second page before seeing New orders. If I'm looking for a specific customer to make an order, I'd have to do some scrolling to find it. Again, owner adjustment of the locations would be nice.

I'm with you 100%, but again, same as above - you'd just have to edit the layout and arrange the boxes in code. Comparing it with the current dashboard, I'd say there more important content above the fold (statistics are at the top which I believe are the least important).
But again, any user-friendly option to have it controlled from the admin means less chance of reaching core (somebody please correct me if I'm wrong as I'm more than happy to push this through and make it top notch).

dbltoe:

I also wondered if, with the now available YOUR_ADMIN/includes/css/dist-site-specific-styles.php, it might be helpful to take the CSS out of the files and provide a quote-surrounded block to be added to the renamed site-specific-styles.php. Sort of keeping all the eggs in one basket. One slip editing the CSS in the mod's core has far worse implications than in the site-specific-styles.php.

If it gets rejected as core code, seems like a good idea. However, if it becomes just a "plugin", it will reach far less users so it's not really modernizing the platform (which I'm so desperately rooting for).

dbltoe:

Also, Maximum Display of Orders on Orders Page is set to 20 yet the page only shows 10 orders.

Bug spotted!

dbltoe:

I'm fully aware of the saying about opinions and I really don't want to come across as denigrating your work. I fully support what you're doing here and will assist in whatever way I can. Coding, not so much.:P Nitpicky? I'm your man. Just ask haredo.

Quite the opposite - I absolutely love comments and discussion, it almost always results in new ideas or improvements. My clients loved the redesign, didn't have a single complaint. Yours already have ideas or would like something different. I love it! The more people get involved, the more comments we can get and then decide on the final result. Can't please everyone (and there's always an option to do custom work), but if 7/10 people ask for the same thing, we probably do need to listen to that...
13 Jan 2026, 22:21
#18
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Posts:
1,745
Plugin Contributions:
17

Re: Modern admin dashboard

barco57:

custom coloring the label sound like a brilliant idea to me.
additionally, while adding a field you could also add a "visible in widget" field for those people that set up a lot of order statuses but are not important for display in the homepage widget.

Ooooh, love that idea.

barco57:


it could also be extended, because I am a glutton for punishment, to be stored as custom settings per admin user. As different admin users may have different needs as to what order statuses are important to their job.

khm... dude... c'mon, don't take it out on me... :P
As much as this is a great idea, I think it would just make the admin overcrowded and overwhelming with all these settings, and we're talking just about the dashboard widget settings...

I'm more than happy to bring all of these ideas to life, but I'd really need some feedback from drbyte, lat9 or swguy to see if it's even being considered for core, and if so, how far to take it with all the good ideas that are coming up here.
13 Jan 2026, 22:44
#19
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Posts:
9,707
Plugin Contributions:
6

Re: Modern admin dashboard

Could you dumb this down for me, please? Keep in mind English is not my native language, I really don't know what you're saying here. :smile:

Give me E for effort here.

Patim od esencijalne drhtavice, a padajući izbornici u staroj administratorskoj stranici brzo nestanu kada dođete do dna izbornika. Vaša verzija izbornika čini se manje vjerojatnom da će mi nestati.
14 Jan 2026, 02:58
#20
oldngrey avatar

oldngrey

Zen Follower

Join Date:
Apr 2008
Posts:
411
Plugin Contributions:
0

Re: Modern admin dashboard

dbltoe:


Also, Maximum Display of Orders on Orders Page is set to 20 yet the page only shows 10 orders.

The Orders Page uses MAX_DISPLAY_SEARCH_RESULTS_ORDERS
The Home widget page uses $recentOrdersMaxRows in admin\includes\extra_datafiles\dist-site_specific_admin_overrides.php

I think that keeping them separate allows for tighter configuration of the home page.
I have experimented with removing a lot of white space on the home page and it is a vast improvement over the old page.