Welcome, Guest ( Customer Panel | Login )




 All Forums
 VPCart Forum
 General help me questions
 Admin: default sort for Products
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

nxpage
Starting Member

49 Posts

Posted - January 05 2007 :  13:09:29  Show Profile  Reply with Quote
We'd like to have the default sort order for the Products grid in Admin sort by cname but I can't for the live of me find where change that. Any direction is appreciated :)

View/Edit Products
shopa_editdisplay.asp?table=products

rvaga
VP-CART Super User

USA
254 Posts

Posted - January 05 2007 :  13:17:47  Show Profile  Reply with Quote
I'd be interested in this as well. It would save that annoying one little step if ccode could be made the default.
Go to Top of Page

support
Administrator

4679 Posts

Posted - January 07 2007 :  22:09:03  Show Profile  Visit support's Homepage  Reply with Quote
Hi nxpage,

You will need to edit your shopa_editdisplay.asp, find a subroutine called Sub GenerateSQL,around line 249
you will find something like
If sortfield="" then sortfield=idfield

remove that line and replace it with

If lcase(dbtable) = "products" and sortfield="" then
sortfield="cname"
else
If sortfield="" then sortfield=idfield
end if

Billy
VP-ASP Support
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000
0 Item(s)
$0.00