Commits

Inside Zhou committed 8763c9f

精简代码,移除身份验证控制。

  • Participants
  • Parent commits b80b535

Comments (0)

Files changed (3)

File Inside.Util.csproj

     <Compile Include="Sql\SQLHelper.cs" />
     <Compile Include="Sql\SQLPlanException.cs" />
     <Compile Include="StringExtension.cs" />
-    <Compile Include="Web\AuthorizeExAttribute.cs" />
     <Compile Include="Web\HttpRequestBaseExtension.cs" />
     <Compile Include="Web\MIME.cs" />
     <Compile Include="Web\MvcControllerBase.cs" />

File Web/AuthorizeExAttribute.cs

-using System;
-using System.Collections.Generic;
-using System.Dynamic;
-using System.Linq;
-using System.Web;
-using System.Web.Mvc;
-
-namespace Inside.Util.Web {
-	public class AuthorizeExAttribute : AuthorizeAttribute {
-		protected override void HandleUnauthorizedRequest(AuthorizationContext filterContext) {
-			var request = filterContext.HttpContext.Request;
-			if(request.IsAjaxRequest()) {
-				filterContext.Result = new HttpStatusCodeResult(403, "还未登录");
-			}
-			else {
-				base.HandleUnauthorizedRequest(filterContext);
-			}
-		}
-	}
-}

File Web/PriviledgeDescriptionAttribute.cs

 	public class PriviledgeDescriptionAttribute : Attribute {
 		public string ID { get; private set; }
 		public string Name { get; private set; }
-		public string Description { get; set; }
-
-		int _state = 0;
-		public int State {
-			get {
-				return this._state;
-			}
-			set {
-				this._state = value;
-			}
-		}
+		public string Remark { get; set; }
 
 		public PriviledgeDescriptionAttribute(string id, string name) {
 			if(string.IsNullOrEmpty(id) || string.IsNullOrEmpty(name)) {