1. public function deleteInfo(){
    2. $info_id = (int) $this->request->param('infoId');
    3. $InfoModel = new InfoModel();
    4. $infoData = $InfoModel::where([
    5. 'info_id'=>$info_id
    6. ])->delete();
    7. if(!$infoData){
    8. $send = ['code'=>400,'msg'=>'删除失败'];
    9. }else{
    10. $send = ['code'=>200,'msg'=>'删除成功'];
    11. }
    12. return json($send);
    13. }