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

Menu filter does not show when running on Octane #48

Open
webard opened this issue Feb 8, 2024 · 2 comments
Open

Menu filter does not show when running on Octane #48

webard opened this issue Feb 8, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@webard
Copy link
Contributor

webard commented Feb 8, 2024

Hi,

when app is running on Octane with Swoole (I did not tested RR or Franken), MenuFilter::activate needs to be run on every request, not only in Service Provider, which are ran only once at first request.

Solution is class:

namespace App\Octane;

use NormanHuth\NovaMenu\Services\MenuFilter;

class ActivateMenuFilter
{

    public function handle()
    {
        MenuFilter::activate('top');
    }
}

and modification in octane.php:

use App\Octane\ActivateMenuFilter;
...
'listeners' => [
 ...
        RequestReceived::class => [
            ...
            ActivateMenuFilter::class,
        ],
]
@webard webard added the enhancement New feature or request label Feb 8, 2024
@Muetze42
Copy link
Owner

Muetze42 commented Feb 9, 2024

I'll have to have a look first. I don't have any contact with Octane and didn't intend to until now.

@maria42-bot
Copy link
Collaborator

@Muetze42 created a reference to a task for the project „nova-menu“:
https://todos.huth.it/9b5bc3f5-e7d1-4e28-96e0-1abf8701912d

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

No branches or pull requests

3 participants