diff --git a/timesheet/inc/class.botimesheet.inc.php b/timesheet/inc/class.botimesheet.inc.php index 2d9217446f..2b85c25bd0 100644 --- a/timesheet/inc/class.botimesheet.inc.php +++ b/timesheet/inc/class.botimesheet.inc.php @@ -112,10 +112,6 @@ class botimesheet extends so_sql $this->customfields = $this->config_data['customfields']; } - if (!is_object($GLOBALS['egw']->datetime)) - { - $GLOBALS['egw']->datetime =& CreateObject('phpgwapi.datetime'); - } $this->tz_offset_s = $GLOBALS['egw']->datetime->tz_offset; $this->now = time() + $this->tz_offset_s; // time() is server-time and we need a user-time $this->today = mktime(0,0,0,date('m',$this->now),date('d',$this->now),date('Y',$this->now)); diff --git a/timesheet/inc/class.uitimesheet.inc.php b/timesheet/inc/class.uitimesheet.inc.php index 34a1905ff0..3081b784df 100644 --- a/timesheet/inc/class.uitimesheet.inc.php +++ b/timesheet/inc/class.uitimesheet.inc.php @@ -428,10 +428,6 @@ class uitimesheet extends botimesheet // category filter: cat_id or ''=All cats or 0=No cat if ($query['cat_id']) { - if (!is_object($GLOBALS['egw']->categories)) - { - $GLOBALS['egw']->categories =& CreateObject('phpgwapi.categories'); - } $cats = $GLOBALS['egw']->categories->return_all_children((int)$query['cat_id']); $query['col_filter']['cat_id'] = count($cats) > 1 ? $cats : $query['cat_id']; } @@ -491,10 +487,6 @@ class uitimesheet extends botimesheet } if ($query['filter'] == 'custom') // show the custome dates { - if (!is_object($GLOBALS['egw']->js)) - { - $GLOBALS['egw']->js =& CreateObject('phpgwapi.javascript'); - } $GLOBALS['egw']->js->set_onload("set_style_by_class('*','custom_hide','visibility','visible');"); } }