[Vtigercrm-developers] vtlib read only UI Type for list view?

Alan Lord alanslists at gmail.com
Fri Jul 6 04:53:34 PDT 2012


Just FYI and if it helps anyone else, in my vtlib modify HelpDesk script 
I have rebuilt the default filter and that seems to work:

// Rebuild default filter for HelpDesk
// Get the default fields:
$field_ticketno = Vtiger_Field::getInstance('ticket_no', $module);
$field_title = Vtiger_Field::getInstance('ticket_title', $module);
$field_parent = Vtiger_Field::getInstance('parent_id', $module);
$field_status = Vtiger_Field::getInstance('ticketstatus', $module);
$field_priority = Vtiger_Field::getInstance('ticketpriorities', $module);
$field_assigned = Vtiger_Field::getInstance('assigned_user_id', $module);

$filter = Vtiger_Filter::getInstance('All', $module);
if ($filter != false) {
	$filter->delete();
}
$filter = new Vtiger_Filter();
$filter->name = 'All';
$filter->isdefault = true;
$module->addFilter($filter);
// Add fields to the filter created
$filter->addField($field_ticketid)->addField($field_ticketno, 
1)->addField($field_title, 2)->addField($field_parent, 
3)->addField($field_status,4)->addField($field_priority,5)->addField($field_assigned,6);

Cheers

Al


On 06/07/12 11:38, Alan Lord wrote:
> On 05/07/12 15:23, Adam Heinz wrote:
>> Have you tried adding the field information to the $list_fields member
>> variable of the HelpDesk class?
>
> Nice idea but no cigar :-(
>
> Thanks
>
> Al
>
>
>
>
> _______________________________________________
> http://www.vtiger.com/
>





More information about the vtigercrm-developers mailing list