UserRoles.php 394 B

12345678910111213141516171819
  1. <?php
  2. namespace app\api\controller\v1;
  3. use app\api\controller\Base;
  4. use app\hander\HelpHander;
  5. use think\Db;
  6. class UserRoles extends Base
  7. {
  8. // 保存角色
  9. public function addRoles(){
  10. $roles = input('rolesId','','trim');
  11. $uid = input('uid/d', 0);
  12. model('UserRoles')->addRoles($uid,$roles,$this->orgId);
  13. HelpHander::success([],'操作成功');
  14. }
  15. }