/** * @return bim_soitem */ public static function singleton() { if (!isset(self::$instance)) { $c = __CLASS__; self::$instance = new $c(); } return self::$instance; }
public function __construct() { $this->bocommon = CreateObject('property.bocommon'); $GLOBALS['phpgw_info']['flags']['xslt_app'] = true; $GLOBALS['phpgw_info']['flags']['menu_selection'] = 'bim::item::index'; $this->db =& $GLOBALS['phpgw']->db; $this->so = bim_soitem::singleton(); $this->sogroup = bim_soitem_group::singleton(); }