mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 16:48:49 +01:00
set ts_project for export/merge from ts_project_blur, where it get moved, if it is no custom value
This commit is contained in:
parent
674fd0736a
commit
a6767139a0
@ -42,7 +42,10 @@ class timesheet_egw_record implements importexport_iface_egw_record
|
||||
public function __construct( $_identifier='' ){
|
||||
$this->identifier = $_identifier;
|
||||
$this->botimesheet = new timesheet_bo();
|
||||
$this->set_record($this->botimesheet->read($this->identifier));
|
||||
$data = $this->botimesheet->read($this->identifier);
|
||||
// set ts_project from ts_project_blur, where it get moved, if it is no custom value
|
||||
if (empty($data['ts_project'])) $data['ts_project'] = $data['ts_project_blur'];
|
||||
$this->set_record($data);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -83,12 +83,6 @@ class timesheet_export_csv implements importexport_iface_export_plugin {
|
||||
// support other selectors atm.
|
||||
foreach ($selection as $identifier) {
|
||||
$record = new timesheet_egw_record($identifier);
|
||||
|
||||
// If Project is not set, set it to current project title
|
||||
if(!$record->ts_project && $record->pm_id)
|
||||
{
|
||||
$record->ts_project = egw_link::title ('projectmanager', $record->pm_id);
|
||||
}
|
||||
if($options['convert']) {
|
||||
importexport_export_csv::convert($record, timesheet_egw_record::$types, 'timesheet', $this->selects);
|
||||
} else {
|
||||
|
@ -120,9 +120,9 @@ class timesheet_merge extends bo_merge
|
||||
$selects['ts_'.$name] = $value;
|
||||
}
|
||||
if($content && strpos($content, '#') !== 0)
|
||||
{
|
||||
$this->cf_link_to_expand($record->get_record_array(), $content, $info);
|
||||
}
|
||||
{
|
||||
$this->cf_link_to_expand($record->get_record_array(), $content, $info);
|
||||
}
|
||||
|
||||
importexport_export_csv::convert($record, $types, 'timesheet', $selects);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user