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

Refactor RootURLController to be generic #2954

Open
GuySartorelli opened this issue May 30, 2024 · 0 comments
Open

Refactor RootURLController to be generic #2954

GuySartorelli opened this issue May 30, 2024 · 0 comments

Comments

@GuySartorelli
Copy link
Member

RootURLController is currently hardcoded to work with SiteTree. It's not inconceivable that someone might want to route to a DataObject that isn't managed in the site tree as the "home" route.

Making this class more generic removes some friction from that use case.

Acceptance Criteria

  • Make this controller work with other DataObject subclasses

TO DECIDE

Arguably this doesn't open much opportunity if we don't move some stuff around as well - but what should we move, and to where?

  • Do we want to move this to silverstripe/framework?
  • Do we want to move this to a new module (along with ModelAsController and ContentController)?
  • Do we want to keep these here, and move SiteTree and CMSMain to a new silverstripe/pages module?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants