名称修改

master
Your Name 5 years ago
parent 9ecc587a9c
commit eb88615b9f

@ -1154,6 +1154,17 @@ class UserController extends BaseController
{
$user = json_decode(base64_decode(file_get_contents("php://input")), true);
$role_name = $user['role_name'];
$encode = mb_detect_encoding($user['role_name'], array('UTF-8','GB2312','GBK'));
if($encode == "UTF-8"){
$role_name = @iconv('UTF-8','GB18030',$user['role_name']);
}
if(strlen($role_name) > 16){
$this -> set_message(1001, "fail", "名称过长");
}
if (empty($user)) {
$this -> set_message(1001, "fail", "操作数据不能为空");

Loading…
Cancel
Save