Hi, i have the following issue of which i hope someone can help me with;
I want to use the functions orderBy for the ListView of my module "ProjectTask".
Now i want the field 'Project Task Id' to be ordered Ascending.
I have created a file view.list.php in this folder custom\modules\ProjectTask\views but this doesn't seems to work...
This file containts the following code;
PHP Code:
<?php
// Order by function
require_once('include/MVC/View/views/view.list.php');
class ProjectTaskViewList extends ViewList {
function ProjectTaskViewList()
{
parent::ViewList();
}
function listViewPrepare()
{
if(empty($_REQUEST['orderBy']))
{
$_REQUEST['orderBy'] = 'project_task_id';
$_REQUEST['sortOrder'] = 'asc';
}
parent::listViewPrepare();
}
// Remove the Advanced Search tab from form
function processSearchForm()
{
$args = func_get_args();
unset($this->searchForm->tabs[1]);
$this->searchForm->nbTabs = sizeof($this->searchForm->tabs);
call_user_func_array
(
array
('parent', __FUNCTION__), $args);
}
}
?>
See screenshot for more info.
Hope someone can help me with this one. Thanks in advance!
Bookmarks