正在显示
3 个修改的文件
包含
2 行增加
和
4 行删除
| @@ -56,7 +56,7 @@ class BaseController extends Controller | @@ -56,7 +56,7 @@ class BaseController extends Controller | ||
| 56 | if(is_array($v)){ | 56 | if(is_array($v)){ |
| 57 | continue; | 57 | continue; |
| 58 | }else{ | 58 | }else{ |
| 59 | - if(empty($v) && ($v != 0)){ | 59 | + if(empty($v) && ($v == null)){ |
| 60 | unset($this->param[$k]); | 60 | unset($this->param[$k]); |
| 61 | } | 61 | } |
| 62 | $this->getMap($k,$v); | 62 | $this->getMap($k,$v); |
| @@ -29,8 +29,6 @@ class DeptLogic extends BaseLogic | @@ -29,8 +29,6 @@ class DeptLogic extends BaseLogic | ||
| 29 | * @time :2023/8/28 15:10 | 29 | * @time :2023/8/28 15:10 |
| 30 | */ | 30 | */ |
| 31 | public function deptSave(){ | 31 | public function deptSave(){ |
| 32 | - var_dump($this->param); | ||
| 33 | - die(); | ||
| 34 | if(isset($this->param['id']) && !empty($this->param['id'])){ | 32 | if(isset($this->param['id']) && !empty($this->param['id'])){ |
| 35 | if($this->param['pid'] == $this->param['id']){ | 33 | if($this->param['pid'] == $this->param['id']){ |
| 36 | $this->fail('当前上级分类不能为自己'); | 34 | $this->fail('当前上级分类不能为自己'); |
| @@ -50,7 +50,7 @@ class BaseLogic extends Logic | @@ -50,7 +50,7 @@ class BaseLogic extends Logic | ||
| 50 | if(is_array($v)){ | 50 | if(is_array($v)){ |
| 51 | continue; | 51 | continue; |
| 52 | }else{ | 52 | }else{ |
| 53 | - if(empty($v) && ($v != 0)){ | 53 | + if(empty($v) && ($v == null)){ |
| 54 | unset($requestAll[$k]); | 54 | unset($requestAll[$k]); |
| 55 | } | 55 | } |
| 56 | } | 56 | } |
-
请 注册 或 登录 后发表评论