public function save($data = null, $whiteList = null) { if (!$this->expires_at) { $this->expires_at = date('Y-m-d H:i:s', strtotime('+3 days')); } if (!$this->confirm_key) { $this->confirm_key = Random::generateKey(64); } return parent::save($data, $whiteList); }
public function crud_edit(Closure $success = null) { Assert::found($this->_crud_model); $this->view->setVar('userData', $this->_crud_model->toArray()); return $this->crud_create($this->_crud_model, $success); }