-
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Location Dynamic Web Routes #85
Comments
This
and this
seem to indicate locations will now have a direct dependency on the blog package. This was supposed to be a lightweight package with no external dependencies (by inverting relations with the location_id in the external package and using a |
This already needs a dependency on the drewroberts/media package for images, so I am fine with adding that other dependency and those subdependencies of drewroberts/blog I'm not as concerned about this being a lightweight package. We're beginning to add more to tipoff/authorization and will be expanding tipoff/support with more theme template stuff. The packages in the tipoff ecosystem will take on a lot more opinionated implementations over time that will be assumed when using one of the packages and I am good with that as long as we continue to weigh the cost and benefit of those decisions like you do. Thank you, Patrick. |
Shouldn't the blog package be responsible for registering an I think all this package needs is a config setting that lists known bad market slug names (with |
Add web routes for market, location pages. Add Route::getLocation macro #85
Proposed Page Extension for Market & Location #85
@pdbreen I think this needs to be updated. I have not been able to get it to work in the tipoff/demo application. |
Can you add details of what you're doing? What types of data are being added? How is that data being added? What routes are you trying to access after the setup? AFAIK, there are no location aware routes defined in any packages, so the only thing that could work would be accessing the Page associated with a market or location. |
I want web routes (TIPOFF/support#113) created for this package that all other packages requiring tipoff/locations should be able to extend. The routes will be based on the number of Locations (#42) that exist in the Markets (#41) and should be dynamic.
If an application only has 1 Market and 1 Location, then any visits to the Market slug or the Location slug under that market should be redirected to the homepage.
If an application has more than 1 Market but there is only 1 Location in a Market, then the Location slug will redirect to the Market slug to which the Location belongs.
If an application has multiple Locations in a Market, then those Locations will have their own pages under the Market path, even if there is only 1 Market in the application. They will exist in the following format:
Location slugs are unique so a website visitor that ends up on a Location slug under the wrong Market slug should be redirected to the correct path for the Location nested under the correct Market slug.
This package should also contain a Controller and base Views for the following:
This package will also contain an "About Us" style page and generate a Page (drewroberts/blog#15) with that as the slug.
All packages that extend this tipoff/locations package should be able to implement their own web routes with location-based pages. These Pages will be persisted with their slug in the database and have a true boolean value for
location_based
(drewroberts/blog#54) in that model. The structure for the URL path of those location-based pages will be dynamic as follows:If the application has more than 1 location, then the path in Example C should not return the view for the Page but should return the "Choose a Location under Company" view from this package.
The path in Example B should display the "Choose a Location in Market" view from this package if the Market has more than 1 Location.
As a result of all of this, an exception needs to be thrown when creating a Location if a Page already has a slug that matches the proposed Location slug. There can't be a conflict between them.
The text was updated successfully, but these errors were encountered: