Profile edit now redirects back to profile, unless user is an admin
这个提交包含在:
父节点
74116240dd
当前提交
7016f46884
共有 1 个文件被更改,包括 7 次插入 和 2 次删除
|
|
@ -159,8 +159,13 @@ class User extends CI_Controller {
|
||||||
break;
|
break;
|
||||||
// All okay, return to user screen
|
// All okay, return to user screen
|
||||||
case OK:
|
case OK:
|
||||||
$this->session->set_flashdata('notice', 'User '.$this->input->post('user_name').' edited');
|
if($this->session->userdata('user_id') == $this->input->post('id')) {
|
||||||
redirect('user');
|
$this->session->set_flashdata('notice', 'User '.$this->input->post('user_name').' edited');
|
||||||
|
redirect('user/profile');
|
||||||
|
} else {
|
||||||
|
$this->session->set_flashdata('notice', 'User '.$this->input->post('user_name').' edited');
|
||||||
|
redirect('user');
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$this->load->view('layout/header');
|
$this->load->view('layout/header');
|
||||||
|
|
|
||||||
正在加载…
在新工单中引用