Commit Graph

106 Commits

Author SHA1 Message Date
Andrew Peters f13865dedc Updating copyright headers 2014-05-08 23:01:20 -07:00
Wei Wang dc8b5010a0 Merge branch 'sort-dependencies' into dev
Conflicts:
	src/Microsoft.AspNet.Mvc.Core/project.json
	src/Microsoft.AspNet.Mvc.Razor.Host/project.json
	src/Microsoft.AspNet.Mvc.Razor/project.json
2014-05-08 11:16:25 -07:00
David Fowler 3b31df3d29 React to renames 2014-05-08 03:24:18 -07:00
Wei Wang 7b2feab670 Sort dependencies and remove duplicates in dependencies 2014-05-07 18:24:04 -07:00
Pranav K 4566947e33 Change ModelState.IsValid back to bool 2014-05-07 17:41:47 -07:00
lajones 235707ec8a Microsoft.ComponentModel.DataAnnotations is being renamed to Microsoft.DataAnnotations 2014-05-07 13:35:36 -07:00
harshgMSFT bbafa0a29a Tests for AntiForgery System. 2014-05-07 10:27:01 -07:00
Pranav K 904c91d2b9 CompositeModelBinder should only validate the object graph at the top
level.
DataAnnotationsModelValidator should prefer the container to Metadata.Model

Fixes #247
2014-05-06 17:39:50 -07:00
Wei Wang e800fcd44f Eliminate duplicated dependencies 2014-05-06 15:27:10 -07:00
Pranav K 076dedcca5 Reacting to package and namespace changes 2014-05-06 14:06:29 -07:00
Ryan Nowak abbaa11212 Incorporate name changes: HttpAbstractions 2014-05-05 17:14:08 -07:00
Ryan Nowak 4ece9969bf HttpAbstractions 2014-05-05 16:29:14 -07:00
Sebastien Ros 6f16dabf08 Renaming Microsoft.AspNet.Security namespace 2014-05-05 16:13:54 -07:00
Ryan Nowak 7a8dc36553 Adding controller-as-filter support
If the controller implements IFilter, it will be added to the filters
collection.

It's hardcoded to be 'first' as it was in MVC, but can be overridden by
implementing IOrderedFilter.
2014-05-05 14:03:01 -07:00
Louis DeJardin bbcac43aaa Updating DataAnnotations version reference 2014-05-02 20:53:12 -07:00
Hao Kung 9bf42374b0 Fix for moving extension methods to IServiceCollection 2014-05-02 12:37:05 -07:00
N. Taylor Mullen 4494f40d67 Addressed code review comments. 2014-05-02 12:16:28 -07:00
N. Taylor Mullen c986c663e3 Add tests to ensure cshtml ending for full path view names.
#206
2014-05-02 12:16:26 -07:00
Ryan Nowak f5b3ae4a3b Renaming Exception Filter methods
These were accidentally the same names as the action filter methods.
Oopsies. Name taken from MVC and appended Async for the async version
because that's how we roll.
2014-05-01 23:14:47 -07:00
dougbu 392aa464b2 Oops wrong test 2014-05-01 19:22:16 -07:00
dougbu a2ba36498a TEMPORARILY disable ClientRulesWithCompareAttribute_ErrorMessageUsesOverride
- test failing under CoreCLR
- leave it running under .NET 4.5
2014-05-01 19:12:23 -07:00
dougbu 222c763b72 Revert "Correcting WebFx failure on CI machines"
- previous attempt didn't work

This reverts commit a626896b80.
2014-05-01 19:08:37 -07:00
dougbu a626896b80 Correcting WebFx failure on CI machines
- a single test is failing under CoreCLR only
- using the resource-related properties of a `ValidationAttribute` in
  precisely one place – the failing test.
- in .NET the DataAnnotations assembly is somehow able to get access to
  `internal` resources
- that doesn’t work under CoreCLR
- short-term fix is to add an `[InternalsVisibleTo]` in the test
  assembly, giving DataAnnotations access to the resource

Will also file a bug in the DataAnnotations repo
2014-05-01 19:01:53 -07:00
anpete 8208cd6b2f Update file headers 2014-05-01 17:42:33 -07:00
Ryan Nowak 81611f13da TEMPORARILY turning off warnings as errors to unblock the CI 2014-04-30 21:55:17 -07:00
harshgMSFT 3765abdfca Adding Support for LinkGeneration for named Routes.
- Adding HtmlHelpers for route link generation.
- Controller Helpers
- UrlHelper and UrlHelperExtensions
2014-04-30 18:34:46 -07:00
Ryan Nowak 8ae1865740 Fix for part of #339
Treat actions with a dynamic constraint or httpmethod constraint as
'better' than those with just route constraints.

This is the first criteria used to filter down the 'best' match, so it's
applied before parameter-arity.
2014-04-30 13:25:48 -07:00
Ryan Nowak 20c8dece7b Adding IFilterFactory
This is a generalized factory/provider for filters - TypeFilterAttribute
and ServiceFilterAttribute are now implemented in terms of this interface.
2014-04-30 13:18:10 -07:00
sornaks d63d998e95 Introducing DisplayText, DisplayTextFor, Id, IdFor, IdForModel.
Fixing CachedDataAnnotationsModelMetadata to support NullDisplayText.
2014-04-30 10:23:25 -07:00
Sebastien Ros b3046a0285 AllowAnonymous can override AuthorizeAttribute
#309
2014-04-28 14:04:10 -07:00
Sebastien Ros e5aeb738e3 Adding a unit test for AuthorizeAttribute
#314
2014-04-28 13:57:29 -07:00
Pranav K f740aabb79 Reviving RangeAttributeAdapter, RequiredAttributeAdapter,
StringLengthAttributeAdapter

* Adding remaining DataTypeAttribute adapter rules
2014-04-26 11:39:29 -07:00
Pranav K f5ba63ea1e Fixing missing files in kproj
Fixing typo in sample filter
2014-04-25 14:48:14 -07:00
Ryan Nowak 8eecad9d83 Bringing back UrlHelper.IsLocalUrl
This has been compied verbatim from MVC (intentional). The tests have been
modernized a bit as well, but all the cases covered in the original are
there.

This may be moved to HttpAbstractions at some point in the future.
2014-04-25 14:29:00 -07:00
Pranav K d61915149c DictionaryBasedValueProvider results null when value is not found
* Guard against Dictionary returning null values
2014-04-24 18:10:06 -07:00
Sebastien Ros 0fe028a4dd Implementing Authorize attribute
#272
2014-04-24 16:21:43 -07:00
Pranav K 2ba8780ee0 Reviving MinLength and MaxLength attribute adapters 2014-04-24 15:52:05 -07:00
Pranav K b0c7dc9220 Make IModelBinder and IValueProvider methods async 2014-04-24 15:16:27 -07:00
N. Taylor Mullen d46389888d Modify search location for views.
When areas are not provided area locations are not searched for views.  Also
added tests for search locations in RazorViewEngine failures.
2014-04-24 14:03:36 -07:00
Pranav K 3671e8c5b4 Reviving CompareAttributeAdapter and ModelClientValidationEqualToRule 2014-04-22 23:11:24 -07:00
Pranav K cc00d8cff7 Modify TypeConverterModelBinder to use ValueProviderResult.CanConvertFromString to determine if it can convert a
value

* Adding support for extra type conversions
2014-04-22 23:00:58 -07:00
David Fowler 40d9fa0019 Added missing dependency 2014-04-21 22:59:26 -07:00
Ryan Nowak 73670fb5d7 CR feedback for filters 2014-04-21 13:34:00 -07:00
Louis DeJardin f19fe0cbef Filters version 2.0
This is functionally much more similar to legacy MVC.

Rather than a pure single pipeline, filter execution takes place in more
stages.
2014-04-17 11:45:58 -07:00
Ryan Nowak ce1f813a82 More spot fixes for warnings as errors 2014-04-16 20:21:10 -07:00
Ryan Nowak 40e7fcc9ba Turning on warnings as errors 2014-04-16 20:21:07 -07:00
sornaks 646b711b11 Adding the missed project files for WebFX:156 - Introducing RedirectToAction and RedirectToRoute 2014-04-15 13:49:57 -07:00
Sornakumar ecd8ddeae4 WebFX 156: Adding support for RedirectToAction and RedirectToRoute 2014-04-15 10:45:57 -07:00
harshgMSFT 1536daa107 Adding NonAction Attribute 2014-04-14 16:18:16 -07:00
dougbu 0e7dff9ca7 Get CoreCLR test builds compiling again
- no Mock without .NET 4.5
- reverts part of "Reviving support for IValidatableObject in CoreCLR"
- that was commit 0f6df5405b.
2014-04-12 13:45:11 -07:00