mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-08 00:54:15 +01:00
Add Project ID to list of exportable fields
This commit is contained in:
parent
babc62d9f1
commit
16cd36c017
@ -41,7 +41,7 @@ class infolog_egw_record implements importexport_iface_egw_record
|
||||
$this->identifier = $_identifier;
|
||||
$this->bo = new infolog_bo();
|
||||
if($_identifier) {
|
||||
$this->record = $this->bo->read($this->identifier);
|
||||
$this->set_record($this->bo->read($this->identifier));
|
||||
}
|
||||
}
|
||||
|
||||
@ -96,6 +96,13 @@ class infolog_egw_record implements importexport_iface_egw_record
|
||||
*/
|
||||
public function set_record(array $_record){
|
||||
$this->record = $_record;
|
||||
// Check for linked project ID
|
||||
$links = egw_link::get_links('infolog', $_record['info_id'], 'projectmanager');
|
||||
foreach($links as $link_id => $app_id) {
|
||||
$this->record['pm_id'] = $app_id;
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -17,7 +17,7 @@ class infolog_wizard_export_csv extends importexport_wizard_basic_export_csv
|
||||
|
||||
// Field mapping
|
||||
$bo = new infolog_tracking();
|
||||
$this->export_fields = array('info_id' => 'Infolog ID') + $bo->field2label;
|
||||
$this->export_fields = array('info_id' => 'Infolog ID', 'pm_id' => 'Project ID') + $bo->field2label;
|
||||
|
||||
// Custom fields
|
||||
unset($this->export_fields['custom']); // Heading, not a real field
|
||||
|
Loading…
Reference in New Issue
Block a user