Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Order Counter on Admin Orders List

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 10-29-2012, 07:37 AM
 
dpcompany dpcompany is offline
 

eXpert
  
Join Date: Oct 2008
Posts: 315
 

Default Order Counter on Admin Orders List

I am looking for some coding help from my fellow X-Carters. I am trying to incorporate a feature that on the surface doesn't seem very advanced, however my PHP skills are lacking. Basically I was wanting to be able to add a column to the "main/orders_list.tpl" that is a visual indication as to whether or not that particular customer has ordered before. I am trying to reference the {{COUNT_ORDERS}} function that counts orders to determine this, but I cannot find its values in any database.

Any help would be extremely appreciated.

Thank you all for your contributions to this forum, you have no idea how much threads in these forums have helped me the past few years in customizing the product we all love and love to hate, X-Cart.

Michael
__________________
Michael

Development
X-Cart Gold Plus v4.7.12
- php 7.3
- reBOOT reDUX
- other goodies

X-Cart Gold v4.7.7
- reBOOT Template
- XPayments 3.0.2
- Abandoned Cart Reminder
- BCSE Reward Points
- BCSE Stock Notify
- XPDF Invoices
Reply With Quote
  #2  
Old 10-29-2012, 08:05 AM
 
Pyro Pyro is offline
 

X-Adept
  
Join Date: Nov 2009
Posts: 506
 

Default Re: Order Counter on Admin Orders List

In 4.5.2+ there is a column that already counts the number of orders per user on admin/users.php?mode=search .

I do not know which version this feature was added (it may be in your version).


If it is not in your version, you may want to download the most recent version and use that as a guide.
__________________
Best Wishes,
James

4.5.2 Gold (work in progress)
Reply With Quote
  #3  
Old 10-30-2012, 02:39 PM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,192
 

Default Re: Order Counter on Admin Orders List

You will have to modify the corresponding php file and query the db for orders for each order/customer then add that to each order in the array so you can call it in the template
__________________
Steve Stoyanov
CFLSystems.com
Web Development
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 04:33 AM.

   

 
X-Cart forums © 2001-2020