app/controllers/backend/UserController.php: in statusAction() display "Activated" in flash message when status is changed to "Active"
This commit is contained in:
parent
652b814e13
commit
b2249735c3
1 changed files with 7 additions and 1 deletions
|
|
@ -57,7 +57,13 @@ class UserController extends \Phalcon\Mvc\Controller
|
|||
$user->setStatus(ucfirst($type));
|
||||
$user->save();
|
||||
|
||||
$this->flash->success('The account was: ' . $user->getStatus());
|
||||
$status = $user->getStatus();
|
||||
// Bit of a hack to convert "active" to verb.
|
||||
if ($status === User::STATUS_ACTIVE) {
|
||||
$status = 'Activated';
|
||||
}
|
||||
|
||||
$this->flash->success('The account was: ' . $status);
|
||||
$this->response->redirect('/admin');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue