/// <summary> /// 根据主键ID获取信息 /// </summary> /// <returns></returns> public JsonResponses GetInfo(int id) { try { RequestBase request = RequestBase.Get.Clone() as RequestBase; request.SetValue("id", id.ToString()); request.Url = GetInfoUrl; return(sdkUtil.PostForVo(request)); } catch (Exception ex) { Console.WriteLine(ex.ToString()); } return(JsonResponses.Failed); }
/// <summary> /// 平台账号注册 /// </summary> /// <param name="loginInfo"></param> /// <returns></returns> public JsonResponses RegisterPlatfrom(RegisterPlatformForm registerPlatform) { try { RequestBase request = RequestBase.PostForm.Clone() as RequestBase; request.Url = RegisterPlatfromUrl; request.SetValue("username", registerPlatform.UserName); request.SetValue("password", registerPlatform.Password); request.SetValue("userNo", registerPlatform.UserNo); request.SetValue("phone", registerPlatform.Phone); request.SetValue("email", registerPlatform.Email); request.SetValue("inputUser", registerPlatform.InputUser); request.SetValue("platformNo", registerPlatform.PlatformNo); return(sdkUtil.PostForVo(request)); } catch (Exception ex) { Console.WriteLine(ex.ToString()); return(JsonResponses.Failed); } }
/// <summary> /// 登录 /// </summary> /// <param name="loginInfo"></param> /// <returns></returns> public JsonResponses Login(LoginInfoForm loginInfo) { try { RequestBase request = RequestBase.PostForm.Clone() as RequestBase; request.Url = LoginUrl; request.SetValue("userName", loginInfo.UserName); request.SetValue("password", loginInfo.Password); request.SetValue("loginerInfo", loginInfo.LoginerInfo); request.SetValue("platform", loginInfo.Platform); return(sdkUtil.PostForVo(request)); } catch (Exception ex) { Console.WriteLine(ex.ToString()); return(JsonResponses.Failed); } }
/// <summary> /// 获取用户角色列表 /// </summary> /// <param name="userNo"></param> /// <returns></returns> public JsonResponses GetRolesAssign(long UserNo) { try { RequestBase request = RequestBase.Get.Clone() as RequestBase; request.Url = GetRolesAssignUrl; request.SetValue("userNo", UserNo); return(sdkUtil.PostForVo(request)); } catch (Exception ex) { Console.WriteLine(ex.ToString()); } return(JsonResponses.Failed); }