I search for a solution to hide menu items if a user is logged on within the navigation provider. A property for the obversely way is available: requiresAuthentication
Can anyone help me?
To inject the AbpSession
within the navigation provider and check if AbpSession.UserId.HasValue
doesn't work. I think the problem is that the navigation provider object is cached because the provider will not called on every request.
yeah you are right. it's already cached. Why don't you do it in client side. You can create menu items in client-side. Use this namespace in javascript: