Added: option to view new customers in Admin Customer list using the KPI and the new customers option in dashboard

This commit is contained in:
vishalsingh.qlo325
2024-05-28 17:09:18 +05:30
parent 19c4e45320
commit cbf7a64e11
4 changed files with 26 additions and 2 deletions

View File

@@ -1885,7 +1885,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
public static function getTotalNewCustomers($nbDaysNewCustomers)
{
$maxDateAdd = date('Y-m-d H:i:s', strtotime('-'.$nbDaysNewCustomers.' day'));
$maxDateAdd = date('Y-m-d', strtotime('-'.$nbDaysNewCustomers.' day'));
$sql = 'SELECT COUNT(c.`id_customer`)
FROM `'._DB_PREFIX_.'customer` c
WHERE c.`date_add` >= "'.pSQL($maxDateAdd).'" AND c.`deleted` = 0';