Need pointers in making my menu tree creator module better

Hi, I’ve created a module for Laminas MVC which might help someone to build menus. I just need pointers in making it better.
Pointers

  1. Which test would be about which test should I write to make it more appealing.
  2. How to make it work with other navigation providers like the one @froschdesign has.
  3. Views should be configurable or static. At the moment I’m using Laminas View with its default method Head Inline Script.
  4. Form creation is pending. Suggestion for form creation is also welcome.

Thanks!

The underlying package laminas-mvc-bootstrap-menu requires LmcRbacMvc but this package is not listed in the Composer configuration. Unfortunately, the laminas-mvc-bootstrap-menu cannot be used without the LmcRbacMvc, even if I am already using a different check like ACL. An optional listener would be a solution here, like the AclListener of laminas-view.

1 Like

Thanks @froschdesign for pointing out the inclusion of LmcRbacMvc as a mandatory component. I’ll remove it and make it appear in the suggestion.

Possibly delegate this:

->setAuthorizationService($this->LmcRbacAuthorizationServiceHelper())

Does it support translation?

Hi @Tyrsson, I’ve no idea about translation in Authorization. But, If you’re asking about translation of navigation then it should work. As I’ve overridden the methods with the help of @froschdesign therefore it should work. But that is a good point. I’ll check that. Thanks!

2 Likes

That’s what I was asking about. I only had time for a quick glance earlier.

Thanks @froschdesign for that answer. If you had not pointed me in the right direction I would not have done so. Thanks for helping me put something out there as a contributor. If someone is wondering what that answer was, here is the link.

Hi @froschdesign, As you’ve pointed out I have a dependency which forces a person to use LmcRbacMVC if the latest version or no version is given during composer install. Therefore, I’ve removed the dependency and given the developer the choice to download which version he/she wants. Thanks!