This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class AutoFilterActionInvoker: ControllerActionInvoker | |
{ | |
protected override FilterInfo GetFilters(ControllerContext controllerContext, ActionDescriptor actionDescriptor) | |
{ | |
var filters = base.GetFilters(controllerContext, actionDescriptor); | |
filters.ResultFilters.Add(new CustomBehaviorAttribute()); | |
return filters; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"issue":[{"@priority":"1","@type":"Task","@state":"Fixed","@subsystem":"No subsystem","@id":"DCVR-1","@fixedVersion":"","@projectShortName":"DCVR","@reporterName":"ruslan.isakiev","@fixedInBuild":"Next build","@commentsCount":"0","@numberInProject":"1","@summary":"Show coverage results in unit test runner's window","@created":"1256724558540","@updated":"1257780483529","@historyUpdated":"1257780483532","@resolved":"1257769772458","@votes":"0","links":null,"attachments":null},{"@priority":"1","@type":"Exception","@state":"Fixed","@subsystem":"Submitted exceptions","@id":"DCVR-2","@fixedVersion":"","@projectShortName":"DCVR","@reporterName":"ruslan.isakiev","@fixedInBuild":"Next build","@commentsCount":"0","@numberInProject":"2","@summary":"Exception : An exception has occurred during action 'OpenSnapshot' execution. Sample exception","@description":"dotCover 1.0 Version=1.0.0.0, Built=2009-11-02T12:21:25, Configuration=“Full PublicMode VS0900”\nAn exception has occurred during action 'OpenSnapshot' execution. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"{\"issue\":[{\"@priority\":\"1\",\"@type\":\"Task\",\"@state\":\"Fixed\",\"@subsystem\":\"No subsystem\",\"@id\":\"DCVR-1\",\"@fixedVersion\":\"\",\"@projectShortName\":\"DCVR\",\"@reporterName\":\"ruslan.isakiev\",\"@fixedInBuild\":\"Next build\",\"@commentsCount\":\"0\",\"@numberInProject\":\"1\",\"@summary\":\"Show coverage results in unit test runner's window\",\"@created\":\"1256724558540\",\"@updated\":\"1257780483529\",\"@historyUpdated\":\"1257780483532\",\"@resolved\":\"1257769772458\",\"@votes\":\"0\",\"links\":null,\"attachments\":null},{\"@priority\":\"1\",\"@type\":\"Exception\",\"@state\":\"Fixed\",\"@subsystem\":\"Submitted exceptions\",\"@id\":\"DCVR-2\",\"@fixedVersion\":\"\",\"@projectShortName\":\"DCVR\",\"@reporterName\":\"ruslan.isakiev\",\"@fixedInBuild\":\"Next build\",\"@commentsCount\":\"0\",\"@numberInProject\":\"2\",\"@summary\":\"Exception : An exception has occurred during action 'OpenSnapshot' execution. Sample exception\",\"@description\":\"dotCover 1.0 Version=1.0.0.0, Built=2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
map.connect '/somethin/:email', requirements => { :email => / <insert your favorite email regex here> / } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class HandleRecordNotFoundAttribute : ActionFilterAttribute | |
{ | |
public override void OnResultExecuting(ResultExecutingContext filterContext) | |
{ | |
var viewResult = filterContext.Result as ViewResult; | |
if (viewResult != null && viewResult.ViewData.Model == null) | |
{ | |
filterContext.Result = new ResourceNotFoundResult(); | |
filterContext.Result.ExecuteResult(filterContext.Controller.ControllerContext); |
NewerOlder