public function store($updateNulls = false) { if (!isset($this->id)) { $this->downloaded = 0; } if (isset($this->alias) && isset($this->name) && $this->alias == "") { $this->alias = preg_replace("/ /", "-", strtolower($this->name)); } return parent::store($updateNulls); }
public function __construct(&$db) { parent::__construct('#__osdownloads_emails', 'id', $db); }
public function getTable($type) { $db = Factory::getDbo(); if ($this->isPro()) { $class = "Alledia\\{$this->namespace}\\Pro\\Joomla\\Table\\{$type}"; if (class_exists($class)) { return new $class($db); } } else { $class = "Alledia\\{{$this->namespace}}\\Free\\Joomla\\Table\\{{$type}}"; if (class_exists($class)) { return new $class($db); } } return BaseTable::getInstance($type, $this->namespace . 'Table'); }