Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Admin... how can I sourt by new clients by date ?


Guest

Recommended Posts

HI

 

On the Admin... under Customers.....

How can you sourt new clients by date registered ?

 

EG: latest new client on top...

 

Currently there seems no logical order on this page it seems random

 

any ideas ?

 

Kevin

Link to comment
Share on other sites

Edit catalog/admin/customers.php and find the line:

 

 

 

$customers_query_raw = "select c.customers_id, c.customers_lastname, c.customers_firstname, c.customers_email_address, a.entry_country_id from " . TABLE_CUSTOMERS . " c left join " . TABLE_ADDRESS_BOOK . " a on c.customers_id = a.customers_id and c.customers_default_address_id = a.address_book_id " . $search . " order by c.customers_lastname, c.customers_firstname";

 

 

 

 

Change this line to read:

 

 

 

$customers_query_raw = "select c.customers_id, c.customers_lastname, "

. "c.customers_firstname, c.customers_email_address, "

. "a.entry_country_id, "

. "ci.customers_info_date_account_created "

. "from " . TABLE_CUSTOMERS . " c "

. "LEFT JOIN " . TABLE_CUSTOMERS_INFO . " ci "

. "ON c.customers_id = ci.customers_info_id "

. "LEFT JOIN " . TABLE_ADDRESS_BOOK . " a "

. "ON c.customers_id = a.customers_id "

. "AND c.customers_default_address_id = a.address_book_id "

. $search

. " ORDER BY ci.customers_info_date_account_created DESC, "

. "c.customers_lastname, c.customers_firstname";

 

Sorry for the layout, my pc doesnt like to copy & paste :(

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...