vtiger Forum Index vtiger
The Honest Open Source CRM
 

sort order for column
Click here to go to the original topic

 
       vtiger Forum Index -> Feature Requests - 5.0.2
Previous topic :: Next topic  
Author Message
sharok



Joined: 23 Jun 2007
Posts: 17

Posted: Mon Nov 05, 2007 11:43 am    Post subject: sort order for column  

Hi All,

can any one help me please about how to have "sort order" capability for a newly added column? at the moment this feature is available just for some of the columns.

many thanks,

Sharok
Back to top  
joebordes



Joined: 18 Aug 2006
Posts: 1100
Location: Alicante/Valencia, Spain

Posted: Mon Nov 05, 2007 4:13 pm    Post subject: Re: sort order for column  

http://wiki.vtiger.com/index.php/Developers_How_To%27s#How_do_you_create_another_sort_column_in_the_Contact_Tab.3F
Back to top  
sharok



Joined: 23 Jun 2007
Posts: 17

Posted: Mon Nov 05, 2007 5:18 pm    Post subject: Re: sort order for column  

Hi there,
thanks for the reply. my added column is in Sales Order under Sales menu. we don't have the same situation as contacts for the sales order. any ideas please?
Back to top  
joebordes



Joined: 18 Aug 2006
Posts: 1100
Location: Alicante/Valencia, Spain

Posted: Mon Nov 05, 2007 5:58 pm    Post subject: Re: sort order for column  

Hi,

It is exactly the same, you have to modify the same array $sortby_fields but in another module

Joe
TSolucio
Back to top  
sharok



Joined: 23 Jun 2007
Posts: 17

Posted: Tue Nov 06, 2007 10:53 am    Post subject: Re: sort order for column  

Hi Joe & thanks again,
I've gone to SalesOrder.php and edited the following line:
var $sortby_fields = Array('subject','crmid','smownerid','accountname','lastname','Test');
Test is my new column, but to no avail! do I need anything else to do?
thanks,
Sharok
Back to top  
joebordes



Joined: 18 Aug 2006
Posts: 1100
Location: Alicante/Valencia, Spain

Posted: Tue Nov 06, 2007 11:59 am    Post subject: Re: sort order for column  

Hi,

The array has a list of table column names, NOT column labels.
So your filed is NOT named Test. You will have to look for the name vtigerCRM has assigned to your custom field column and put that name there. It will be in the table vtiger_salesordercf with a name of the type cf_###, for example cf_456

Joe
TSolucio
Back to top  
sharok



Joined: 23 Jun 2007
Posts: 17

Posted: Wed Nov 07, 2007 3:47 pm    Post subject: Re: sort order for column  

Thank you very much indeed, Joe
I put cf_547 and it worked perfectly. May I ask how can I do this for existing columns like 'Due Date' in 'Sales Orders'? Would I be able to get it to have sort order feature on it?

thank you very much again,

Sharok
Back to top  
sharok



Joined: 23 Jun 2007
Posts: 17

Posted: Wed Nov 07, 2007 3:57 pm    Post subject: Re: sort order for column  

Sorry I bothered you again Joe,

I think I found it. I need to look at vtiger_salesorder table.

many thanks for your all kindly help.

Cheers!

Sharok
Back to top  
 
       vtiger Forum Index -> Feature Requests - 5.0.2
Page 1 of 1


Powered by phpBB Search Engine Indexer
Powered by phpBB 2.0.15 © 2001, 2002 phpBB Group