コード例 #1
0
        public ActionResult Setting(int arid, string CMIDWeight)
        {
            var srm = new ShowResultModel();

            try
            {
                //计算/修改权值
                _adminRoleService.UpdateWeight(arid, CMIDWeight);
                srm.TipMsg    = "权限设置成功!";
                srm.IsSuccess = true;
            }
            catch (InvalidOperationException ex)
            {
                srm.TipMsg = ex.Message;
            }
            catch (Exception ex)
            {
                srm.TipMsg = ex.Message;
                LoggerHelper.Log("【设置权值】出错,系统操作管理员:" + _currentAdmin.AdminInfo.SAName + ",错误原因:" + (ex.InnerException == null ? ex.Message : ex.InnerException.ToString()));
            }
            return(Json(srm));
        }