/** * @see parent::save() */ public function saveNew() { if (!$this->PostedAt) { $this->PostedAt = time(); } return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { if (!$this->Position) { $this->Position = self::getLast($this, 'Position', array('ProductId = ' . $this->ProductId)) + 1; } return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { if (!$this->Type) { $this->Type = self::CERTIFICATE; } $this->Position = self::getLast($this, 'Position', array('Type = ' . $this->Type)) + 1; return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { $this->PostedAt = time(); $Article = new Article(); $arr = array(); foreach ($Article->findResult('Id', array('InSubscription = 1'), 'PostedAt desc') as $Article) { $arr[] = $Article->Id; } $this->Articles = implode(',', $arr); return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { $this->Position = intval(self::getLast($this, 'Position', array('CategoryId = ' . $this->CategoryId))) + 1; return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { $this->Position = self::getLast($this, 'Position') + 1; return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { $this->InSubscription = 1; return parent::saveNew(); }
/** * @see parent::saveNew() */ public function saveNew() { $this->SentAt = time(); return parent::saveNew(); }