/**
  * 删除用户
  * @param $id
  */
 public function delete($id)
 {
     try {
         $model = new UserModel();
         if ($model->delete($id) === false) {
             throw new Exception('删除失败');
         }
         $this->redirect('index');
     } catch (Exception $e) {
         $this->error($e->getMessage());
     }
 }