| | |
| | | /// <returns></returns> |
| | | [Route("Web/GetUser")] |
| | | [HttpGet] |
| | | [AllowAnonymous] |
| | | public object GetUser(string UserName, string PassWord, string HOrgName) |
| | | { |
| | | try |
| | |
| | | } |
| | | } |
| | | |
| | | if (!oSystemParameter.ShowBill(ref DBUtility.ClsPub.sErrInfo)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "登录异常!Token 生成异常,无法获取公司信息!"; |
| | | } |
| | | |
| | | string tokenStr = Utility.JWTHelper.GenerateToken(UserName.Trim(), DBUtility.ClsPub.StrToPsd(PassWord.Trim())); |
| | | |
| | | |
| | | objjson.code = "0"; |
| | | objjson.count = 1; |
| | | objjson.Message = "[0000-1-073]登录成功!"; |
| | | objjson.data = ds.Tables[0]; |
| | | return objjson; |
| | | JObject jobjJsonResult = JObject.FromObject(objjson); |
| | | jobjJsonResult["token"] = tokenStr; |
| | | return jobjJsonResult; |
| | | |
| | | } |
| | | catch (Exception e) |
| | |
| | | /// <returns></returns> |
| | | [Route("Web/GetDataBases")] |
| | | [HttpGet] |
| | | [AllowAnonymous] |
| | | public object GetDataBases() |
| | | { |
| | | try |
| | |
| | | /// <returns></returns> |
| | | [Route("Web/GetOrganizations")] |
| | | [HttpGet] |
| | | [AllowAnonymous] |
| | | public object GetOrganizations() |
| | | { |
| | | try |
| | |
| | | /// <returns></returns> |
| | | [Route("Web/BaseInfo")] |
| | | [HttpGet] |
| | | [AllowAnonymous] |
| | | public object GetBaseInfo() |
| | | { |
| | | try |
| | |
| | | { |
| | | if (param.TechParamName.StartsWith(category)) |
| | | { |
| | | param.TechParamName = param.TechParamName.Substring(category.Length - 1); |
| | | if(param.TechParamName.Length != category.Length) |
| | | { |
| | | param.TechParamName = param.TechParamName.Substring(category.Length); |
| | | } |
| | | groupedParams[category].Add(param); |
| | | isMatched = true; |
| | | break; // 匹配到第一个分类后停止(避免重复匹配) |