Browse Source

处理参数错误异常

Li 2 years ago
parent
commit
e5b89ee014
1 changed files with 3 additions and 3 deletions
  1. 3 3
      TEAMModelBI/Controllers/BITable/TableDingDingInfoController.cs

+ 3 - 3
TEAMModelBI/Controllers/BITable/TableDingDingInfoController.cs

@@ -368,12 +368,12 @@ namespace TEAMModelBI.Controllers.BITable
                 try
                 {
                     isDisable = long.Parse($"{_isDisable}");
-                    if (isDisable != 1 || isDisable != 0)
-                        return Ok(new { state = RespondCode.ParamsError, msg = "禁用参数错误" });                    
+                    if (isDisable != 1 && isDisable != 0)
+                        return Ok(new { state = RespondCode.ParamsError, msg = "账户禁用参数错误" });                    
                 }
                 catch
                 {
-                    return Ok(new { state = RespondCode.ParamsError, msg = "禁用参数错误" });
+                    return Ok(new { state = RespondCode.ParamsError, msg = "账户禁用参数错误" });
                 }
                 var table = tableClient.GetTableReference("BIDDUserInfo");
                 var (_tmdId, _tmdName, pic, did, dname, dpic) = HttpJwtAnalysis.JwtXAuthBI(HttpContext.GetXAuth("AuthToken"), _option);