Пример #1
0
 protected function _preSave($is_new)
 {
     parent::_preSave($is_new);
     if ($is_new) {
         $this->_created_at = NOW;
     }
 }
Пример #2
0
 protected function _preSave($is_new)
 {
     parent::_preSave($is_new);
     if ($is_new) {
         $this->_time = NOW;
     }
 }
Пример #3
0
 protected function _preSave($is_new)
 {
     parent::_preSave($is_new);
     $this->_date = NOW;
     $this->_author = TBGContext::getUser();
 }
Пример #4
0
 protected function _preSave($is_new)
 {
     parent::_preSave($is_new);
     if ($is_new) {
         if (!$this->_posted) {
             $this->_posted = NOW;
         }
         if (!$this->_comment_number) {
             $this->_comment_number = TBGCommentsTable::getTable()->getNextCommentNumber($this->_target_id, $this->_target_type);
         }
     }
 }
Пример #5
0
 protected function _preSave($is_new)
 {
     parent::_preSave($is_new);
     $this->_sortfields = $this->getSortFieldsAsString();
     $this->_columns = join(',', $this->getColumns());
 }