Ejemplo n.º 1
0
        public override void OnResultExecuted(ResultExecutedContext filterContext)
        {
            MonitorLog MonLog = filterContext.Controller.ViewData[Key] as MonitorLog;

            MonLog.ExecuteEndTime = DateTime.Now;
            LoggerHelper.Monitor(MonLog.GetLoginfo(MonitorLog.MonitorType.View));
            filterContext.Controller.ViewData.Remove(Key);
        }
Ejemplo n.º 2
0
        public override void OnActionExecuted(ActionExecutedContext filterContext)
        {
            MonitorLog MonLog = filterContext.Controller.ViewData[Key] as MonitorLog;

            MonLog.ExecuteEndTime   = DateTime.Now;
            MonLog.FormCollections  = filterContext.HttpContext.Request.Form;        //form表单提交的数据
            MonLog.QueryCollections = filterContext.HttpContext.Request.QueryString; //Url 参数
            LoggerHelper.Monitor(MonLog.GetLoginfo());
        }