/** * Creates the backend * * @param \PDO $pdo * @param string $calendarTableName * @param string $calendarObjectTableName */ public function __construct(\PDO $pdo, $calendarTableName = 'calendars', $principalsTableName = 'principals', $calendarObjectTableName = 'calendarobjects', $calendarSharesTableName = 'calendarShares', $notificationsTableName = 'notifications') { parent::__construct($pdo, $calendarTableName, $calendarObjectTableName); $this->calendarSharesTableName = $calendarSharesTableName; $this->principalsTableName = $principalsTableName; $this->notificationsTableName = $notificationsTableName; }
/** * Creates the backend */ public function __construct() { $oPdo = \CApi::GetPDO(); $sDbPrefix = \CApi::GetSettings()->GetConf('Common/DBPrefix'); $this->dBPrefix = $sDbPrefix; parent::__construct($oPdo, $sDbPrefix . Constants::T_CALENDARS, $sDbPrefix . Constants::T_CALENDAROBJECTS); $this->calendarSharesTableName = $sDbPrefix . Constants::T_CALENDARSHARES; $this->principalsTableName = $sDbPrefix . Constants::T_PRINCIPALS; $this->notificationsTableName = $sDbPrefix . Constants::T_NOTIFICATIONS; }
/** * Creates the backend */ public function __construct() { parent::__construct(\CApi::GetPDO()); $this->dBPrefix = \CApi::GetSettings()->GetConf('Common/DBPrefix'); $this->calendarTableName = $this->dBPrefix . Constants::T_CALENDARS; $this->calendarChangesTableName = $this->dBPrefix . Constants::T_CALENDARCHANGES; $this->calendarObjectTableName = $this->dBPrefix . Constants::T_CALENDAROBJECTS; $this->calendarSharesTableName = $this->dBPrefix . Constants::T_CALENDARSHARES; $this->schedulingObjectTableName = $this->dBPrefix . Constants::T_SCHEDULINGOBJECTS; $this->calendarSubscriptionsTableName = $this->dBPrefix . Constants::T_CALENDARSUBSCRIPTIONS; }