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

Add base model linking functionality #2

Merged
merged 38 commits into from Oct 24, 2023
Merged

Add base model linking functionality #2

merged 38 commits into from Oct 24, 2023

Conversation

m-triassi
Copy link
Contributor

Description

Closes #1

Adds the ability to link arbitrary models with hyperlinks that can then be aggregated underneath menus. These Menus can in turn be attached to arbitraty models that can expose menus

register migration within service provider
navigation needs to be nestable, and orderable, and needs a final destination. Add fk references and nullable for morphs
…enu building

leverage polymorphic relations where appropriate
@m-triassi m-triassi added the enhancement New feature or request label Oct 23, 2023
@m-triassi m-triassi self-assigned this Oct 23, 2023
Copy link
Contributor

@kfriars kfriars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be shipped as is, but I have left several comments.

src/Concerns/HasMenus.php Outdated Show resolved Hide resolved
src/Concerns/IsLinkable.php Show resolved Hide resolved
src/Contracts/HyperlinkInterface.php Outdated Show resolved Hide resolved
src/Contracts/HyperlinkInterface.php Outdated Show resolved Hide resolved
src/Contracts/HyperlinkInterface.php Outdated Show resolved Hide resolved
src/Contracts/MenuableInterface.php Outdated Show resolved Hide resolved
src/Contracts/MenuInterface.php Outdated Show resolved Hide resolved
src/Contracts/MenuableInterface.php Outdated Show resolved Hide resolved
Comment on lines +16 to +18
'create_menus_table',
'create_menuables_table',
'create_hyperlinks_table',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In newer packages, I don't think you need to .stub these any longer. Which is nice for reading them in the IDE.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh really? honestly, i hardly noticed since i added *.php.stub as a PHP file extension, so it gets read as a PHP file for me

src/Models/Hyperlink.php Show resolved Hide resolved
Co-authored-by: Kurt <kfriars@gmail.com>
m-triassi and others added 4 commits October 24, 2023 09:32
Co-authored-by: Kurt <kfriars@gmail.com>
Co-authored-by: Kurt <kfriars@gmail.com>
Co-authored-by: Kurt <kfriars@gmail.com>
Co-authored-by: Kurt <kfriars@gmail.com>
@m-triassi
Copy link
Contributor Author

seeing as we're resolved & approved here, i'm going merge!

@m-triassi m-triassi merged commit 1c472c6 into main Oct 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Navigation model must be implemented
2 participants