mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-08 00:54:15 +01:00
- Add/fix labels for creation date, pricelist
- Fix export filtering on assigned
This commit is contained in:
parent
5564217b0c
commit
97fea10521
@ -24,7 +24,7 @@ class infolog_egw_record implements importexport_iface_egw_record
|
||||
|
||||
// Used in conversions
|
||||
static $types = array(
|
||||
'select' => array('info_type', 'info_status', 'info_priority', 'info_pricelist'),
|
||||
'select' => array('info_type', 'info_status', 'info_priority', 'pl_id'),
|
||||
'select-cat' => array('info_cat'),
|
||||
'select-account' => array('info_owner','info_responsible','modifier'),
|
||||
'date-time' => array('info_startdate', 'info_enddate','info_datecompleted', 'info_datemodified','info_created'),
|
||||
|
@ -63,6 +63,12 @@ class infolog_export_csv implements importexport_iface_export_plugin {
|
||||
$fields = importexport_helper_functions::get_filter_fields($_definition->application, $this);
|
||||
$query['col_filter'] = $_definition->filter;
|
||||
|
||||
// Backend expects a string
|
||||
if($query['col_filter']['info_responsible'])
|
||||
{
|
||||
$query['col_filter']['info_responsible'] = implode(',',$query['col_filter']['info_responsible']);
|
||||
}
|
||||
|
||||
// Handle ranges
|
||||
foreach($query['col_filter'] as $field => $value)
|
||||
{
|
||||
@ -127,7 +133,7 @@ class infolog_export_csv implements importexport_iface_export_plugin {
|
||||
if(!is_array($selection[$id])) break;
|
||||
$selection[$id]['pm_id'] = current($links);
|
||||
$selection[$id]['project'] = egw_link::title('projectmanager', $selection[$id]['pm_id']);
|
||||
$this->selects['info_pricelist'] = ExecMethod('projectmanager.projectmanager_pricelist_bo.pricelist',$selection[$id]['pm_id']);
|
||||
$this->selects['pl_id'] = ExecMethod('projectmanager.projectmanager_pricelist_bo.pricelist',$selection[$id]['pm_id']);
|
||||
}
|
||||
}
|
||||
|
||||
@ -234,7 +240,7 @@ class infolog_export_csv implements importexport_iface_export_plugin {
|
||||
{
|
||||
$this->selects['info_type'] = $this->bo->enums['type'];
|
||||
$this->selects['info_priority'] = $this->bo->enums['priority'];
|
||||
$this->selects['info_pricelist'] = ExecMethod('projectmanager.projectmanager_pricelist_bo.pricelist',false);
|
||||
$this->selects['pl_id'] = ExecMethod('projectmanager.projectmanager_pricelist_bo.pricelist',false);
|
||||
$this->selects['info_status'] = $this->bo->get_status();
|
||||
}
|
||||
|
||||
|
@ -18,6 +18,9 @@ class infolog_wizard_export_csv extends importexport_wizard_basic_export_csv
|
||||
// Field mapping
|
||||
$bo = new infolog_tracking(new infolog_bo());
|
||||
$this->export_fields = array('info_id' => 'Infolog ID', 'pm_id' => 'Project ID', 'project' => 'Project Name') + $bo->field2label;
|
||||
// Add in created date, in the appropriate place
|
||||
$first = array_splice($this->export_fields, 0, array_search('info_datemodified',array_keys($this->export_fields)));
|
||||
$this->export_fields = array_merge($first, array('info_created'=>'creation'), $this->export_fields);
|
||||
|
||||
// Custom fields
|
||||
unset($this->export_fields['custom']); // Heading, not a real field
|
||||
|
Loading…
Reference in New Issue
Block a user