thinkcmf/thinkcmfapi

控制器的请求参数(字符串类型)无法填充默认数值

slsnpro opened this issue · 2 comments

版本: 2018.5.31下载的源码
环境: win10+xampp(7.0.30)
请求: /api/v1/public/register?user_id=&share_code=&invite_code=

user_id: $this->request->get('user_id', 10, 'int'); // 可以填充
share_code: $this->request->get('share_code', 'sa'); // 不能填充

不带share_code 这个参数呢

不带参数反而会填充默认值