Thursday 12 February 2015

[vTiger 6] Change comments order

If you want see the comments of your modules ordered by creation date, open  "\modules\ModComments" file, search "getAllParentComments($parentId)" function and edit the line

//Condition are directly added as query_generator transforms the
//reference field and searches their entity names
$query = $query ." AND related_to = ? AND parent_comments = '' ORDER BY vtiger_crmentity.createdtime DESC";

Change to:

$query = $query ." AND related_to = ? AND parent_comments = '' ORDER BY vtiger_crmentity.createdtime ASC";

1 comment:

  1. Hi

    I have a question. Please help me, thanks/

    Q: In module User (index.php?module=Users&parent=Settings&view=List)

    I want to add a filter and search by all fields, please help me.
    i have make a filter form and registerEvents in js, but it not woking. I think when module extend the function fillter will work.

    Please help me, thanks

    ReplyDelete