diff --git a/Application/Admin/Controller/TestWhiteListController.class.php b/Application/Admin/Controller/TestWhiteListController.class.php index 0b7f0e280..98566be9a 100644 --- a/Application/Admin/Controller/TestWhiteListController.class.php +++ b/Application/Admin/Controller/TestWhiteListController.class.php @@ -200,4 +200,32 @@ class TestWhiteListController extends ThinkController } } + public function deleteWhileUser() { + + $userId = $_REQUEST['id']; + +// dump($userId);die(); + + $userWhite = M('test_white_list','tab_')->where(['id'=>$userId])->find(); + + + if ($userWhite) { + + $del = M('test_white_list','tab_')->where(['id'=>$userId])->delete(); + + if ($del) { + $this->ajaxReturn(['status'=>0,'msg'=>"删除成功"]); + } else { + $this->ajaxReturn(['status'=>0,'msg'=>"删除失败"]); + } + + } else { + + $this->ajaxReturn(['status'=>0,'msg'=>"账号不存在,删除失败"]); + + } + + + } + } diff --git a/Application/Admin/View/TestWhiteList/lists.html b/Application/Admin/View/TestWhiteList/lists.html index 2d24fc52a..bd767247c 100644 --- a/Application/Admin/View/TestWhiteList/lists.html +++ b/Application/Admin/View/TestWhiteList/lists.html @@ -81,7 +81,11 @@