Commit Graph

33 Commits

Author SHA1 Message Date
Ryan Nowak 0ad9c7d4eb Making Pages Binding Consistent
This changeset reckonciles the binding work we did for pages with
controllers.

A quick summary:
- Moves [BindProperty] to the MVC namespace (#6401)
- Makes [FromRoute] and friends behave consistently (#6402)
- Makes [BindProperty] work with controllers (untracked)
2017-06-26 18:11:44 -07:00
Pranav K c89f0a1e43 Allow AddPageRoute to route to pages root. (#6412)
* Allow AddPageRoute to route to pages root.
Fixes #6338
2017-06-20 12:33:33 -07:00
Pranav K 597a0c9a11 Add support for friendly routes in pages
FIxes #6325
2017-05-26 14:29:00 -07:00
Ryan Nowak c1dd95be2a Add a test for #6294
This case was fixed by 2992f8e - this commit just adds a test to verify
the fix.
2017-05-24 16:53:30 -07:00
Ryan Brandenburg 42b988ad88 ./ paths relative on page. 2017-04-25 11:57:58 -07:00
N. Taylor Mullen 5c8a161ace Change `FormTagHelper` to apply to all form tags.
- Added functional test to validate that non-attributed form tags have an antiforgery input generated. Re-generated baseline to reflect changes.
- Added a unit test to validate that parameterless `FormTagHelper`s behave as expected.

#6006
2017-04-24 18:39:01 -07:00
Ryan Nowak 04fd762943 Rename form-action -> handler 2017-04-24 14:15:35 -07:00
Pranav K ca017eced2 Add page to AnchorTagHelper and FormTagHelper
Fixes #6088
2017-04-21 18:12:54 -07:00
Pranav K f568d3c2bc Support finding "sibling" pages when using RedirecToPage
Fixes #6083
2017-04-21 18:12:52 -07:00
Ryan Nowak 297196baa0 Design updates to handler methods and binding
Implements #6091, #6072, #6090, #5927
2017-04-21 17:29:25 -07:00
Ryan Brandenburg 908b4c8d62 FormAction from QueryString 2017-04-21 15:04:37 -07:00
Ryan Nowak 4bf518b09b Fix #6140 - Allow linking between controller and page
The issue here is that route values used for action selection are
'global'. That means that pages need to have a 'null' route value for
'action' and controllers need to have a 'null' route value for pages. This
is the same way that areas work.

The fix is to move the 'merge' of route values up to a level where pages
and controllers can work together. Since ADPs use the russian-doll
pattern, the fix is to run this 'merge' in the controller ADP, but after
all of the ADs have been created.
2017-04-19 16:48:38 -07:00
Pranav K 3474bdf776 RedirectToPage from a form-action handler includes the formaction
Fixes #6104
2017-04-12 09:27:08 -07:00
Ryan Brandenburg 59a3aade9b Fix [TempData] for PageModel's 2017-04-11 16:45:44 -07:00
Pranav K 1e7972bd8f Add convenience methods for redirecting from a Razor Page back to itself
Fuxes #5953
2017-04-07 10:03:42 -07:00
Ryan Nowak 4032de064e Removing _PageStart.cshtml
Pages now also use _ViewStart.cshtml

Also contains some naming/text cleanup that was missed in the previous
commit.
2017-04-06 08:14:37 -07:00
Pranav K 925ad75cdf Add convenience methods for redirecting to another Razor Page
Fixes #5956
2017-04-04 14:36:22 -07:00
Ryan Brandenburg e5ccac8bf6 Add functional tests for RazorPage routes 2017-04-04 11:14:52 -07:00
Hisham Bin Ateya fe3d45fad1 Adding AllowAnonymousToPage & AllowAnonymousToFolder
Fixes #5884
2017-03-31 20:17:31 -07:00
Pranav K b22326323a Add properties to Page and PageModel
Fixes #6008
2017-03-28 13:26:38 -07:00
Pranav K e7101f248a Support model binding to Razor Pages properties on page and PageModel classes
Fixes #5952
2017-03-24 07:45:19 -07:00
Ryan Brandenburg e6cb639cc0 Add handler functional test 2017-03-20 10:05:29 -07:00
Pranav K bee1a55cff Use RazorPagesOptions.RootDirectory when looking for page hierarchies.
Fixes #5915
2017-03-14 18:56:50 -07:00
Ryan Brandenburg 82d87df166 Fix warning as error 2017-03-14 12:44:57 -07:00
Ryan Brandenburg 365ae19c8b Add InvalidTagHelperIndexerAssignment to RazorPageBase 2017-03-14 10:04:15 -07:00
Ryan Brandenburg 1c74e31715 Add tests for PageActionInvokerProvider (#5882) 2017-03-09 16:19:20 -08:00
Ryan Brandenburg 7f3f6957be Set path in DefaultPageFactory (#5911) 2017-03-09 16:15:43 -08:00
Ryan Brandenburg 4a20c849cb Add functional test for Page.View() (#5896) 2017-03-06 16:19:41 -08:00
Pranav K 145d27f9b3 Add a PagesOption type that allows configuring the root for Page file discovery
Fixes #5785
2017-03-03 17:20:07 -08:00
Ryan Brandenburg 85e28ae478 Trim quotes from template (#5838) 2017-03-03 09:52:36 -08:00
Pranav K 7cadb58e12 Add convenience extension methods for IPageApplicationModelConvention 2017-03-02 17:38:04 -08:00
Ryan Nowak e11e6b3be7 Add TempData property and some functional tests 2017-02-22 08:14:02 -08:00
Ryan Nowak 19331f9532 Adding some basic functional tests
I ran into a blocking issue where page handlers aren't picked up, so I
fixed it. Logging another issue to follow up with better tests for this.
2017-02-21 16:41:25 -08:00