mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-27 17:19:06 +01:00
Set date fields for spreadsheet date formatting, add date with nothing after it to list of potential formats for parsing into spreadsheet date
This commit is contained in:
parent
0fa472164e
commit
35bb3b6a87
@ -1041,6 +1041,7 @@ abstract class bo_merge
|
||||
'!'.egw_time::$user_dateformat . ' ' .egw_time::$user_timeformat.':s',
|
||||
'!'.egw_time::$user_dateformat . '* ' .egw_time::$user_timeformat,
|
||||
'!'.egw_time::$user_dateformat . '*',
|
||||
'!'.egw_time::$user_dateformat,
|
||||
);
|
||||
|
||||
// Properly format values for spreadsheet
|
||||
|
@ -31,6 +31,13 @@ class filemanager_merge extends bo_merge
|
||||
protected $numeric_fields = array(
|
||||
);
|
||||
|
||||
/**
|
||||
* Fields that are dates or timestamps
|
||||
*/
|
||||
public $date_fields = array(
|
||||
'mtime', 'ctime'
|
||||
);
|
||||
|
||||
/**
|
||||
* Business object to pull records from
|
||||
*/
|
||||
@ -123,7 +130,8 @@ class filemanager_merge extends bo_merge
|
||||
// Format date cfs per user preferences
|
||||
if($field['type'] == 'date' || $field['type'] == 'date-time')
|
||||
{
|
||||
$file['#'.$name] = egw_time::to($file['#'.$name]);
|
||||
$this->date_fields[] = '#'.$name;
|
||||
$file['#'.$name] = egw_time::to($file['#'.$name], $field['type'] == 'date' ? true : '');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user