Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use custom routers to generate URLs from models #831

Draft
wants to merge 1 commit into
base: master
from

Conversation

@leofeyer
Copy link
Member

commented Oct 8, 2019

This PR allows us to do the following:

$pageModel = PageModel::findById(2);
echo $router->generate($pageModel); // will output en/foo.html

TODO

  • Agree on the implementation
  • Check the priority
  • Add a NewsModelRouter and CalendarEventsModelRouter
  • Unit tests
@leofeyer leofeyer self-assigned this Oct 8, 2019
@leofeyer leofeyer added the feature label Oct 8, 2019
@leofeyer leofeyer added this to the 4.9 milestone Oct 8, 2019
@leofeyer leofeyer force-pushed the feature/model-router branch 2 times, most recently from 63d1ffe to 0ee5be3 Oct 8, 2019
@leofeyer leofeyer force-pushed the feature/model-router branch from 0ee5be3 to 8f2677f Oct 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.